aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/mpegenc.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/mpegenc.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/mpegenc.c')
-rw-r--r--libavformat/mpegenc.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/libavformat/mpegenc.c b/libavformat/mpegenc.c
index a471b38bb9..32a3858f56 100644
--- a/libavformat/mpegenc.c
+++ b/libavformat/mpegenc.c
@@ -335,7 +335,7 @@ static int mpeg_mux_init(AVFormatContext *ctx)
av_set_pts_info(st, 64, 1, 90000);
switch(st->codec->codec_type) {
- case CODEC_TYPE_AUDIO:
+ case AVMEDIA_TYPE_AUDIO:
if (st->codec->codec_id == CODEC_ID_AC3) {
stream->id = ac3_id++;
} else if (st->codec->codec_id == CODEC_ID_DTS) {
@@ -363,7 +363,7 @@ static int mpeg_mux_init(AVFormatContext *ctx)
stream->max_buffer_size = 4 * 1024;
s->audio_bound++;
break;
- case CODEC_TYPE_VIDEO:
+ case AVMEDIA_TYPE_VIDEO:
stream->id = mpv_id++;
if (st->codec->rc_buffer_size)
stream->max_buffer_size = 6*1024 + st->codec->rc_buffer_size/8;
@@ -379,7 +379,7 @@ static int mpeg_mux_init(AVFormatContext *ctx)
#endif
s->video_bound++;
break;
- case CODEC_TYPE_SUBTITLE:
+ case AVMEDIA_TYPE_SUBTITLE:
stream->id = mps_id++;
stream->max_buffer_size = 16 * 1024;
break;
@@ -1046,7 +1046,7 @@ retry:
/* for subtitle, a single PES packet must be generated,
so we flush after every single subtitle packet */
if(s->packet_size > avail_data && !flush
- && st->codec->codec_type != CODEC_TYPE_SUBTITLE)
+ && st->codec->codec_type != AVMEDIA_TYPE_SUBTITLE)
return 0;
if(avail_data==0)
continue;
@@ -1156,7 +1156,7 @@ static int mpeg_mux_write_packet(AVFormatContext *ctx, AVPacket *pkt)
int64_t pts, dts;
PacketDesc *pkt_desc;
const int preload= av_rescale(ctx->preload, 90000, AV_TIME_BASE);
- const int is_iframe = st->codec->codec_type == CODEC_TYPE_VIDEO && (pkt->flags & PKT_FLAG_KEY);
+ const int is_iframe = st->codec->codec_type == AVMEDIA_TYPE_VIDEO && (pkt->flags & PKT_FLAG_KEY);
pts= pkt->pts;
dts= pkt->dts;