Re: SDP wrapper? Object-oriented API?

Here's a concrete example that came up a while back.
Imagine I have a webRTC app which wants to use the opus codec 
irrespective of the preferences of the far end device for Alaw because I've been getting quality complaints. 

Currently as a javascript coder I have to :
0) intercept the offer
1) look for an m=audio line
2) look for a subsequent a=rtpmap lines
3) remove all a=rtpmap lines that don't contain OPUS or telephone-event
4) rewrite the m=audio line so that it only contains the types for opus and telephone-event
5) make sure 2->4 only apply to lines before a subsequent m= line.
6) set the re-written offer as a  local description and send it.

That requires an excessive amount of telephony knowledge IMHO.

By the way, we have written a wrapper that makes this a bit easier: 

but it still leaks SDP concepts.

Kaufman is not quite right in saying "y'all soundly rejected it" - I didn't, it was clear to me 
at the time that this would be a problem. All we can now do is try to mitigate it.


Received on Monday, 17 June 2013 10:38:57 UTC