[Freeswitch-users] Problem 'adding' video to an audio initiated call, fmtp

Tyler Winter tyler at phone.com
Thu Nov 3 01:03:41 MSK 2011


I was able to add video to a non-video initiated call by using the sip_renegotiate_codec_on_reinvite setting which ended up being elusive.

My understanding of this setting from reviewing the code, is:
- the default behavior of FS is that once the codec is negotiated, re-INVITEs skip the codec negotiation logic and only process changes in media IP/port/etc.
- by turning this setting on, every re-INVITE goes through the same codec negotiation logic as happens during the initial INVITE.

Hope this helps someone else too.

-Tyler

On Sep 27, 2011, at 2:58 PM, Tyler Winter wrote:

> Hi,
> 
> I'm trying to add video to a non-video initiated call. I should mention that I have no problems initiated and answering a call as video (using Bria softphone and H.264 codec). I captured several test calls to compare the SDP. I found that adding video doesn't work only when initiating the call as audio. In other words, I can initiate the call as video on the A-leg, and answer the call as audio on the B-leg and then add video on the B-leg and video starts working. I think problem is due to there being no fmtp "media attribute" on the 200 OK w/SDP response from FS to the A-leg when I initialize the call as audio, then add video to it.
> 
> I believe I narrowed down the problem to be the following:
> - Caller (a-leg) initiated the call as audio.
> - Callee (b-leg) answered the call as video
> - Caller (a-leg) "adds" video which sends an INVITE to the switch to negotiate the video codecs
> - FS responds to Caller (a-leg) with 200 OK (SDP) but the "fmtp" media attribute is missing. 
> 
> On a working video call the fmtp attribute is appended to the SDP along with the rest of the video codec details. 
> 
> Here's an example:
> 
> this is the INVITEs SDP information to FS from the caller (a-leg) on a  working video call (initiated as video):
> Media Description, name and address (m): video 55752 RTP/AVP 123 124
> Bandwidth Information (b): TIAS:1574400
> Media Attribute (a): rtpmap:123 H264/90000
> Media Attribute (a): fmtp:123 profile-level-id=42801f;packetization-mode=0;level-asymmetry-allowed=1
> Media Attribute (a): rtpmap:124 H264/90000
> Media Attribute (a): fmtp:124 profile-level-id=42801f;packetization-mode=1;level-asymmetry-allowed=1
> Media Attribute (a): sendrecv
> 
> 200 OK from FS to the Caller (a-leg):
> Media Description, name and address (m): video 16454 RTP/AVP 123
> Media Attribute (a): rtpmap:123 H264/90000
> Media Attribute (a): fmtp:123 profile-level-id=42801f;packetization-mode=0;level-asymmetry-allowed=1
> 
> Now, when I try to initiate a call as audio, then add video:
> 
> INVITE from the caller (a-leg) to FS ("adding" video during call):
> Media Description, name and address (m): video 64698 RTP/AVP 123 124
> Bandwidth Information (b): TIAS:1574400
> Media Attribute (a): rtpmap:123 H264/90000
> Media Attribute (a): fmtp:123 profile-level-id=42801f;packetization-mode=0;level-asymmetry-allowed=1
> Media Attribute (a): rtpmap:124 H264/90000
> Media Attribute (a): fmtp:124 profile-level-id=42801f;packetization-mode=1;level-asymmetry-allowed=1
> Media Attribute (a): sendrecv
> 
> 200 OK from FS to the caller (a-leg):
> Media Description, name and address (m): video 23678 RTP/AVP 123
> Media Attribute (a): rtpmap:123 H264/90000
> 
> So, it appears that the "fmtp" attribute is missing on the 200 OK response:
> Media Attribute (a): fmtp:123 profile-level-id=42801f;packetization-mode=0;level-asymmetry-allowed=1
> 
> I can upload the captures somewhere if the full details will be helpful to anyone. If anyone has had any luck with this feature, I'm interested in how you accomplished it. I also tried using the setting "sip_force_video_fmtp" to no avail.
> 
> I appreciate any help.
> 
> Regards,
> 
> Tyler
> 
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20111102/b28e3ad6/attachment.html 


Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list