[Live-devel] How to get RTP packets
Ross Finlayson
finlayson at live555.com
Fri Apr 18 00:50:37 PDT 2008
>Thanks for the info. I know doGetNextFrame1() will give the rtp
>frames. But instead of rtp frames i need rtp packets.
>The following function will do get rtp packets.
>
>* static void networkReadHandler(MultiFramedRTPSource* source, int /*mask*/);
>* friend void networkReadHandler(MultiFramedRTPSource*, int);
>
>both are declared under private section. How can i use that friend
>function in the playCommon.cpp(openRTSP test program)
>file to get those rtp packets?
You can't. You would need to modify the existing source code in some
other way - e.g., modify "networkReadHandler()" to do whatever you
want to do with the incoming RTP packets.
Another possible approach would be to change the client to receive
raw UDP packets (which will therefore contain all the RTP header(s)),
rather than having the client knowingly receive RTP packets. The
simplest way to do this would be to change the line
if (strcmp(fProtocolName, "UDP") == 0) {
on line 656 of "MediaSession.cpp" to
if (True) {
If you do this, your output file should contain the complete UDP
packet data, including the RTP headers.
--
Ross Finlayson
Live Networks, Inc.
http://www.live555.com/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.live555.com/pipermail/live-devel/attachments/20080418/dee4ead4/attachment.html
More information about the live-devel
mailing list