Commit d2a7cfaf authored by Sylvain Berfini's avatar Sylvain Berfini 🎩

Call new mediastreamer2 stream type API to fix ringing from linphone in wrong stream on Android

parent bb5b22b9
......@@ -3697,6 +3697,7 @@ void linphone_core_notify_incoming_call(LinphoneCore *lc, LinphoneCall *call){
if (lc->ringstream && lc->dmfs_playing_start_time!=0){
linphone_core_stop_dtmf_stream(lc);
}
ms_snd_card_set_stream_type(ringcard, MS_SND_CARD_STREAM_RING);
linphone_ringtoneplayer_start(lc->factory, lc->ringtoneplayer, ringcard, lc->sound_conf.local_ring, 2000);
}else{
/* else play a tone within the context of the current call */
......
......@@ -2584,6 +2584,11 @@ void MediaSessionPrivate::startAudioStream (LinphoneCallState targetState, bool
captcard = playcard = nullptr;
}
#endif
if (playcard) {
ms_snd_card_set_stream_type(playcard, MS_SND_CARD_STREAM_VOICE);
}
bool useEc = captcard && linphone_core_echo_cancellation_enabled(core);
audio_stream_enable_echo_canceller(audioStream, useEc);
if (playcard && (stream->max_rate > 0))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment