Hi, On 30 March, hlidea...@gmail.com wrote: > initial SDP. In most examples, the local SDP is hard coded like: > static int priv_static_capabilities_base(SscMedia *sscm, char **dest) > { > if (dest) > *dest = g_strdup("v=0\nm=audio 0 RTP/AVP 0\na=rtpmap:0 PCMU/8000");
btw, telepathy-rakia (formerly telepathy-sofiasip) provides a more complicated example of how to generate the local SDP in a more dynamic fashion (depending on which codecs are available/configured): http://cgit.freedesktop.org/telepathy/telepathy-rakia/tree/rakia/media-session.c#n1759 But yup, still using the same mechanism. > I guess I can generate a local SDP using sprintf by printing the v=, > m= lines, but I want to know are there any other ways to get the local > SDP message by sofia-sip APIs?I mean using the APIs to generate the > v=, m=, a= lines. Thanks. That's a good question. In short, no, there's really not much support for generating SDP element by element. The SDP module does provide a parser and printer, but support for modifying the parsed SDP is fairly limited: http://sofia-sip.sourceforge.net/refdocs/sdp/index.html So at least I've found it much easier to just create the template SDP as text and fill in the needed dynamic elements. In theory the SDP module could be extented, but I'm not sure if it's a worthwhile effort... :P Br, Kai Vehmanen ------------------------------------------------------------------------------ Enable your software for Intel(R) Active Management Technology to meet the growing manageability and security demands of your customers. Businesses are taking advantage of Intel(R) vPro (TM) technology - will your software be a part of the solution? Download the Intel(R) Manageability Checker today! http://p.sf.net/sfu/intel-dev2devmar _______________________________________________ Sofia-sip-devel mailing list Sofia-sip-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sofia-sip-devel