[pjsip] Need help on getting rtp stream on sip server
jdodson at acm.org
Fri Apr 4 13:44:01 EDT 2008
I'm currently working on a gateway that's doing half of what you're
asking about. It sounds like your server will need to be a B2BUA to
terminate the media on either side and connect the two streams. I'm
using the invite session abstraction to perform the offer/answer
mechanism to exchange SDPs to get the endpoint to send the media to my
gateway. Invite session is a great abstraction. It's documented in
the PJSIP developers guide. For an example, look at simpleua.c.
For how to get the media out of the stream and send it to the other
stream, look at the pjmedia documentation for the pjmedia_port
interface. The stream interface is great if you'll potentially have
different codecs on either side of the call. If you'll have the same
media parameters on each side, you probably just want to forward the
If you want to get the RTP directly, look at siprtp.c. siprtp.c isn't
using the jitter buffers, it's mainly capturing the RTP and looking at
stats. There's a very simple interface to the jitter buffers though
which is also well documented, so it shouldn't be too hard to plug
that in to your code. If you're simply forwarding RTP though, you
shouldn't need the jitter buffer.
Hope the helps.
On Thu, Apr 3, 2008 at 11:52 PM, Senthil Raja <vsraja at yahoo.com> wrote:
> Hi Benny, et al,
> With your help (thanks a lot!) and from the sample stateful_proxy.c, I was
> able to create sip server which does registrar and proxy functions. This
> setup allows two soft-phones to registrar themselves and make calls between
> them. However the rtp stream for the call is established directly between
> the User Agents and not via the sip server. Hence I would like to know
> what changes should I have to perform to make the rtp go through the sip
> server. Appreciate your help.
> You rock. That's why Blockbuster's offering you one month of Blockbuster
> Total Access, No Cost.
> Visit our blog: http://blog.pjsip.org
> pjsip mailing list
> pjsip at lists.pjsip.org
More information about the pjsip