[FFmpeg-cvslog] r15497 - trunk/libavformat/rdt.c

rbultje subversion
Wed Oct 1 14:38:42 CEST 2008


Author: rbultje
Date: Wed Oct  1 14:38:41 2008
New Revision: 15497

Log:
Use parse_packet vfunc in RTPDynamicProtocolHandler instead of hardcoding
the use of rdt_parse_packet(). See "RDT/Realmedia patches #2" thread on ML.



Modified:
   trunk/libavformat/rdt.c

Modified: trunk/libavformat/rdt.c
==============================================================================
--- trunk/libavformat/rdt.c	(original)
+++ trunk/libavformat/rdt.c	Wed Oct  1 14:38:41 2008
@@ -211,10 +211,13 @@ ff_rdt_parse_packet(RTPDemuxContext *s, 
     uint32_t timestamp;
     int rv= 0;
 
+    if (!s->parse_packet)
+        return -1;
+
     if (!buf) {
         /* return the next packets, if any */
         timestamp= 0; ///< Should not be used if buf is NULL, but should be set to the timestamp of the packet returned....
-        rv= rdt_parse_packet(s, pkt, &timestamp, NULL, 0, flags);
+        rv= s->parse_packet(s, pkt, &timestamp, NULL, 0, flags);
         return rv;
     }
 
@@ -232,7 +235,7 @@ ff_rdt_parse_packet(RTPDemuxContext *s, 
     len -= rv;
     s->seq = seq;
 
-    rv = rdt_parse_packet(s, pkt, &timestamp, buf, len, flags);
+    rv = s->parse_packet(s, pkt, &timestamp, buf, len, flags);
 
     return rv;
 }
@@ -313,7 +316,8 @@ static RTPDynamicProtocolHandler ff_rdt_
     CODEC_ID_NONE, \
     rdt_parse_sdp_line, \
     rdt_new_extradata, \
-    rdt_free_extradata \
+    rdt_free_extradata, \
+    rdt_parse_packet \
 };
 
 RDT_HANDLER(live_video, "x-pn-multirate-realvideo-live", CODEC_TYPE_VIDEO);




More information about the ffmpeg-cvslog mailing list