summaryrefslogtreecommitdiff
path: root/libavformat/rtp.h
diff options
context:
space:
mode:
authorLuca Abeni <lucabe72@email.it>2009-02-28 17:24:56 +0000
committerLuca Abeni <lucabe72@email.it>2009-02-28 17:24:56 +0000
commitd3a57949583670dab00713401d469fba013d4c7e (patch)
tree62fd12530918a8e5d23354a2fdc53b7e84994247 /libavformat/rtp.h
parent81f052cb7dc3f6c6b8192436dbbaff6d1f2bf676 (diff)
downloadffmpeg-d3a57949583670dab00713401d469fba013d4c7e.tar.gz
Document ff_rtp_get_codec_info()
Originally committed as revision 17661 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/rtp.h')
-rw-r--r--libavformat/rtp.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/libavformat/rtp.h b/libavformat/rtp.h
index f340f413c0..dbed54e31d 100644
--- a/libavformat/rtp.h
+++ b/libavformat/rtp.h
@@ -33,6 +33,18 @@
*/
int ff_rtp_get_payload_type(AVCodecContext *codec);
+/**
+ * Initialize a codec context based on the payload type.
+ *
+ * Fill the codec_type and codec_id fields of a codec context with
+ * information depending on the payload type; for audio codecs, the
+ * channels and sample_rate fields are also filled.
+ *
+ * @param codec The context of the codec
+ * @param payload_type The the payload type (the 'PT' field in the RTP header)
+ * @return In case of unknown payload type or dynamic payload type, a
+ * negative value is returned; otherwise, 0 is returned
+ */
int ff_rtp_get_codec_info(AVCodecContext *codec, int payload_type);
const char *ff_rtp_enc_name(int payload_type);
enum CodecID ff_rtp_codec_id(const char *buf, enum CodecType codec_type);