comparison rtp.h @ 4387:5c42816e12c6 libavformat

Add "AVFormatContext *ctx" (that being the RTSP demuxer's) as first argument to the parse_packet() function pointer in RTPDynamicProtocolHandlers. This allows these functions to peek back and retrieve values from the demuxer's context (or RTSPState). The ASF/RTP payload parser will use this to be able to parse SDP values (which occur even before the payload ID is given), store them in the RTSPState and then retrieve them while parsing payload data. See "[PATCH] RTSP-MS 13/15: add RTSP demuxer AVFormatContext to parse_packet() function pointer (was: transport context)" mailinglist thread.
author rbultje
date Fri, 06 Feb 2009 01:37:19 +0000
parents 1b695f013cd3
children 80f21f72d7d6
comparison
equal deleted inserted replaced
4386:3dbd7fa2c2af 4387:5c42816e12c6
105 } RTPStatistics; 105 } RTPStatistics;
106 106
107 /** 107 /**
108 * Packet parsing for "private" payloads in the RTP specs. 108 * Packet parsing for "private" payloads in the RTP specs.
109 * 109 *
110 * @param ctx RTSP demuxer context
110 * @param s stream context 111 * @param s stream context
111 * @param st stream that this packet belongs to 112 * @param st stream that this packet belongs to
112 * @param pkt packet in which to write the parsed data 113 * @param pkt packet in which to write the parsed data
113 * @param timestamp pointer in which to write the timestamp of this RTP packet 114 * @param timestamp pointer in which to write the timestamp of this RTP packet
114 * @param buf pointer to raw RTP packet data 115 * @param buf pointer to raw RTP packet data
115 * @param len length of buf 116 * @param len length of buf
116 * @param flags flags from the RTP packet header (PKT_FLAG_*) 117 * @param flags flags from the RTP packet header (PKT_FLAG_*)
117 */ 118 */
118 typedef int (*DynamicPayloadPacketHandlerProc) (PayloadContext *s, 119 typedef int (*DynamicPayloadPacketHandlerProc) (AVFormatContext *ctx,
120 PayloadContext *s,
119 AVStream *st, 121 AVStream *st,
120 AVPacket * pkt, 122 AVPacket * pkt,
121 uint32_t *timestamp, 123 uint32_t *timestamp,
122 const uint8_t * buf, 124 const uint8_t * buf,
123 int len, int flags); 125 int len, int flags);