#ifdef VIDEO_ENABLED
// If video enabled, check ZRTP encryption in videostream
- const LinphoneCallParams *params=linphone_call_get_current_params(call);
- if (params->has_video && !call->videostream_encrypted) {
- return FALSE;
+ {
+ const LinphoneCallParams *params=linphone_call_get_current_params(call);
+ if (params->has_video && !call->videostream_encrypted) {
+ return FALSE;
+ }
}
#endif
#ifdef VIDEO_ENABLED
static void linphone_call_videostream_encryption_changed(void *data, bool_t encrypted){
- ms_message("Video stream is %s", encrypted ? "encrypted" : "not encrypted");
-
LinphoneCall *call = (LinphoneCall *)data;
+
+ ms_message("Video stream is %s", encrypted ? "encrypted" : "not encrypted");
call->videostream_encrypted=encrypted;
propagate_encryption_changed(call);
}
#ifdef VIDEO_ENABLED
// Enable video encryption
- const LinphoneCallParams *params=linphone_call_get_current_params(call);
- if (params->has_video) {
- ms_message("Trying to enable encryption on video stream");
- OrtpZrtpParams params;
- params.zid_file=NULL; //unused
- video_stream_enable_zrtp(call->videostream,call->audiostream,¶ms);
+ {
+ const LinphoneCallParams *params=linphone_call_get_current_params(call);
+ if (params->has_video) {
+ OrtpZrtpParams params;
+ ms_message("Trying to enable encryption on video stream");
+ params.zid_file=NULL; //unused
+ video_stream_enable_zrtp(call->videostream,call->audiostream,¶ms);
+ }
}
#endif
}
call->op=sal_op_new(lc->sal);
sal_op_set_user_pointer(call->op,call);
call->core=lc;
- linphone_core_get_local_ip(lc,linphone_address_get_domain(to),call->localip);
+ linphone_core_get_local_ip(lc,NULL,call->localip);
linphone_call_init_common(call,from,to);
_linphone_call_params_copy(&call->params,params);
sal_op_set_custom_header(call->op,call->params.custom_headers);
}
linphone_address_clean(from);
- linphone_core_get_local_ip(lc,linphone_address_get_domain(from),call->localip);
+ linphone_core_get_local_ip(lc,NULL,call->localip);
linphone_call_init_common(call, from, to);
call->log->call_id=ms_strdup(sal_op_get_call_id(op)); /*must be known at that time*/
linphone_core_init_default_params(lc, &call->params);
const char *rtcp_addr=vstream->rtcp_addr[0]!='\0' ? vstream->rtcp_addr : call->resultdesc->addr;
call->video_profile=make_profile(call,call->resultdesc,vstream,&used_pt);
if (used_pt!=-1){
- call->current_params.video_codec = rtp_profile_get_payload(call->video_profile, used_pt);
VideoStreamDir dir=VideoStreamSendRecv;
MSWebCam *cam=lc->video_conf.device;
bool_t is_inactive=FALSE;
+ call->current_params.video_codec = rtp_profile_get_payload(call->video_profile, used_pt);
call->current_params.has_video=TRUE;
video_stream_enable_adaptive_bitrate_control(call->videostream,
void linphone_call_start_media_streams(LinphoneCall *call, bool_t all_inputs_muted, bool_t send_ringbacktone){
LinphoneCore *lc=call->core;
- call->current_params.audio_codec = NULL;
- call->current_params.video_codec = NULL;
-
LinphoneAddress *me=linphone_core_get_primary_contact_parsed(lc);
char *cname;
bool_t use_arc=linphone_core_adaptive_rate_control_enabled(lc);
SalProtoRtpAvp,SalVideo);
#endif
+ call->current_params.audio_codec = NULL;
+ call->current_params.video_codec = NULL;
+
if ((call->audiostream == NULL) && (call->videostream == NULL)) {
ms_fatal("start_media_stream() called without prior init !");
return;