< Previous by Date Date Index Next by Date >
< Previous in Thread Thread Index  

Re: [reSIProcate] Does there have an easy way to parse "fmtp" ?


You can use:

SdpContents::Session::Codec codec = sdp.session().media().front().codecs().front();   // or iterate through them

Data codecParameters = codec.parameters();

 

…To get the strings following the payload id’s. 

 

You can then use the ParseBuffer class (rutil) to parse this string further.  Search for instances of ParseBuffer in the resip code to get examples of how to use it.

 

Scott

 

From: resiprocate-devel-bounces@xxxxxxxxxxxxxxx [mailto:resiprocate-devel-bounces@xxxxxxxxxxxxxxx] On Behalf Of Karlsson
Sent: January 23, 2008 5:00 AM
To: resiprocate-devel@xxxxxxxxxxxxxxx
Subject: [reSIProcate] Does there have an easy way to parse "fmtp" ?

 

Hi, I using this code to got the fmtp values.

 

 list<Data>::const_iterator fmtpIter = sdpContent->session().media().front().getValues("rtpmap").begin();
 for (; fmtpIter!=sdpContent->session().media().front().getValues("rtpmap").end(); ++i)
 {
  /*

   if there have:

`a=fmtp:125 profile-level-id=42e015; max-br=4000; max-mbps=19800
`a=fmtp:115 QCIF=1 CIF=1 VGA=1 MAXBR=1960
`a=fmtp:34 QCIF=1 CIF=1 VGA=1 MAXBR=1960

  */ 


 }

 

 

How to got the 125, 115, 34 and QCIF, CIF, VGA, MAXBR and profile-level-id, 42e015 ?

 

Does Rutil or DUM, stack have an easy to parse these lines?

 

thanks