Mercurial > libavformat.hg
changeset 2901:0d0ffa1a0478 libavformat
Make AVRtpPayloadTypes static and constant
Patch by Diego 'Flameeyes' Petten (flameeyes AT gmail DOT com)
author | lucabe |
---|---|
date | Sun, 06 Jan 2008 10:00:04 +0000 |
parents | a28c002dd2b4 |
children | cb12e3352bf5 |
files | rtp.c rtp.h |
diffstat | 2 files changed, 9 insertions(+), 12 deletions(-) [+] |
line wrap: on
line diff
--- a/rtp.c Sat Jan 05 22:33:27 2008 +0000 +++ b/rtp.c Sun Jan 06 10:00:04 2008 +0000 @@ -29,7 +29,15 @@ //#define DEBUG /* from http://www.iana.org/assignments/rtp-parameters last updated 05 January 2005 */ -AVRtpPayloadType_t AVRtpPayloadTypes[]= +static const struct +{ + int pt; + const char enc_name[50]; /* XXX: why 50 ? */ + enum CodecType codec_type; + enum CodecID codec_id; + int clock_rate; + int audio_channels; +} AVRtpPayloadTypes[]= { {0, "PCMU", CODEC_TYPE_AUDIO, CODEC_ID_PCM_MULAW, 8000, 1}, {1, "Reserved", CODEC_TYPE_UNKNOWN, CODEC_ID_NONE, -1, -1},
--- a/rtp.h Sat Jan 05 22:33:27 2008 +0000 +++ b/rtp.h Sun Jan 06 10:00:04 2008 +0000 @@ -85,16 +85,6 @@ int cur_au_index; } rtp_payload_data_t; -typedef struct AVRtpPayloadType_s -{ - int pt; - const char enc_name[50]; /* XXX: why 50 ? */ - enum CodecType codec_type; - enum CodecID codec_id; - int clock_rate; - int audio_channels; -} AVRtpPayloadType_t; - #if 0 typedef enum { RTCP_SR = 200, @@ -120,5 +110,4 @@ } rtcp_sdes_type_t; #endif -extern AVRtpPayloadType_t AVRtpPayloadTypes[]; #endif /* FFMPEG_RTP_H */