aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/rmenc.c
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2010-03-30 23:30:55 +0000
committerStefano Sabatini <stefano.sabatini-lala@poste.it>2010-03-30 23:30:55 +0000
commit72415b2adb2c25f95ceede49001bb97ed9247dbb (patch)
tree99247889aa61bb7621c966466ea4b84c100207d3 /libavformat/rmenc.c
parentca6e7708b42e7d33ba3053bcd447d52a077bca25 (diff)
downloadffmpeg-72415b2adb2c25f95ceede49001bb97ed9247dbb.tar.gz
Define AVMediaType enum, and use it instead of enum CodecType, which
is deprecated and will be dropped at the next major bump. Originally committed as revision 22735 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/rmenc.c')
-rw-r--r--libavformat/rmenc.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/libavformat/rmenc.c b/libavformat/rmenc.c
index 21748d5d52..9dbe3d08dc 100644
--- a/libavformat/rmenc.c
+++ b/libavformat/rmenc.c
@@ -141,7 +141,7 @@ static void rv10_write_header(AVFormatContext *ctx,
stream = &rm->streams[i];
- if (stream->enc->codec_type == CODEC_TYPE_AUDIO) {
+ if (stream->enc->codec_type == AVMEDIA_TYPE_AUDIO) {
desc = "The Audio Stream";
mimetype = "audio/x-pn-realaudio";
codec_data_size = 73;
@@ -177,7 +177,7 @@ static void rv10_write_header(AVFormatContext *ctx,
put_str8(s, mimetype);
put_be32(s, codec_data_size);
- if (stream->enc->codec_type == CODEC_TYPE_AUDIO) {
+ if (stream->enc->codec_type == AVMEDIA_TYPE_AUDIO) {
int coded_frame_size, fscode, sample_rate;
sample_rate = stream->enc->sample_rate;
coded_frame_size = (stream->enc->bit_rate *
@@ -309,7 +309,7 @@ static int rm_write_header(AVFormatContext *s)
stream->enc = codec;
switch(codec->codec_type) {
- case CODEC_TYPE_AUDIO:
+ case AVMEDIA_TYPE_AUDIO:
rm->audio_stream = stream;
stream->frame_rate = (float)codec->sample_rate / (float)codec->frame_size;
/* XXX: dummy values */
@@ -317,7 +317,7 @@ static int rm_write_header(AVFormatContext *s)
stream->nb_packets = 0;
stream->total_frames = stream->nb_packets;
break;
- case CODEC_TYPE_VIDEO:
+ case AVMEDIA_TYPE_VIDEO:
rm->video_stream = stream;
stream->frame_rate = (float)codec->time_base.den / (float)codec->time_base.num;
/* XXX: dummy values */
@@ -408,7 +408,7 @@ static int rm_write_video(AVFormatContext *s, const uint8_t *buf, int size, int
static int rm_write_packet(AVFormatContext *s, AVPacket *pkt)
{
if (s->streams[pkt->stream_index]->codec->codec_type ==
- CODEC_TYPE_AUDIO)
+ AVMEDIA_TYPE_AUDIO)
return rm_write_audio(s, pkt->data, pkt->size, pkt->flags);
else
return rm_write_video(s, pkt->data, pkt->size, pkt->flags);