diff --git a/coreapi/linphonecall.c b/coreapi/linphonecall.c index 261a8d763..171b44fd8 100644 --- a/coreapi/linphonecall.c +++ b/coreapi/linphonecall.c @@ -1632,6 +1632,7 @@ void linphone_call_init_audio_stream(LinphoneCall *call){ if (call->audiostream != NULL) return; if (call->sessions[0].rtp_session==NULL){ call->audiostream=audiostream=audio_stream_new(call->media_ports[0].rtp_port,call->media_ports[0].rtcp_port,call->af==AF_INET6); + rtp_session_set_symmetric_rtp(audiostream->ms.sessions.rtp_session,linphone_core_symmetric_rtp_enabled(lc)); }else{ call->audiostream=audio_stream_new_with_sessions(&call->sessions[0]); } @@ -1692,6 +1693,7 @@ void linphone_call_init_video_stream(LinphoneCall *call){ if (call->sessions[1].rtp_session==NULL){ call->videostream=video_stream_new(call->media_ports[1].rtp_port,call->media_ports[1].rtcp_port, call->af==AF_INET6); + rtp_session_set_symmetric_rtp(call->videostream->ms.sessions.rtp_session,linphone_core_symmetric_rtp_enabled(lc)); }else{ call->videostream=video_stream_new_with_sessions(&call->sessions[1]); } diff --git a/coreapi/misc.c b/coreapi/misc.c index 0cc6a3ac9..38b0efa5d 100644 --- a/coreapi/misc.c +++ b/coreapi/misc.c @@ -1537,3 +1537,8 @@ const char ** linphone_core_get_supported_file_formats(LinphoneCore *core){ } return core->supported_formats; } + +bool_t linphone_core_symmetric_rtp_enabled(LinphoneCore*lc){ + return lp_config_get_int(lc->config,"rtp","symmetric",1); +} + diff --git a/coreapi/private.h b/coreapi/private.h index 79537e742..b03365858 100644 --- a/coreapi/private.h +++ b/coreapi/private.h @@ -382,6 +382,7 @@ void linphone_call_stop_media_streams_for_ice_gathering(LinphoneCall *call); void linphone_call_update_crypto_parameters(LinphoneCall *call, SalMediaDescription *old_md, SalMediaDescription *new_md); void linphone_call_update_remote_session_id_and_ver(LinphoneCall *call); + const char * linphone_core_get_identity(LinphoneCore *lc); void linphone_core_start_waiting(LinphoneCore *lc, const char *purpose); @@ -397,6 +398,7 @@ void linphone_core_notify_incoming_call(LinphoneCore *lc, LinphoneCall *call); bool_t linphone_core_incompatible_security(LinphoneCore *lc, SalMediaDescription *md); extern SalCallbacks linphone_sal_callbacks; bool_t linphone_core_rtcp_enabled(const LinphoneCore *lc); +bool_t linphone_core_symmetric_rtp_enabled(LinphoneCore*lc); LinphoneCall * is_a_linphone_call(void *user_pointer); LinphoneProxyConfig * is_a_linphone_proxy_config(void *user_pointer);