Mercurial > libavformat.hg
diff dvenc.c @ 5910:536e5527c1e0 libavformat
Define AVMediaType enum, and use it instead of enum CodecType, which
is deprecated and will be dropped at the next major bump.
author | stefano |
---|---|
date | Tue, 30 Mar 2010 23:30:55 +0000 |
parents | 15f34b5059ed |
children | 9fef9c7acf03 |
line wrap: on
line diff
--- a/dvenc.c Tue Mar 30 15:50:57 2010 +0000 +++ b/dvenc.c Tue Mar 30 23:30:55 2010 +0000 @@ -239,7 +239,7 @@ reqasize = 4 * dv_audio_frame_size(c->sys, c->frames); switch (st->codec->codec_type) { - case CODEC_TYPE_VIDEO: + case AVMEDIA_TYPE_VIDEO: /* FIXME: we have to have more sensible approach than this one */ if (c->has_video) av_log(st->codec, AV_LOG_ERROR, "Can't process DV frame #%d. Insufficient audio data or severe sync problem.\n", c->frames); @@ -247,7 +247,7 @@ memcpy(*frame, data, c->sys->frame_size); c->has_video = 1; break; - case CODEC_TYPE_AUDIO: + case AVMEDIA_TYPE_AUDIO: for (i = 0; i < c->n_ast && st != c->ast[i]; i++); /* FIXME: we have to have more sensible approach than this one */ @@ -299,11 +299,11 @@ /* We have to sort out where audio and where video stream is */ for (i=0; i<s->nb_streams; i++) { switch (s->streams[i]->codec->codec_type) { - case CODEC_TYPE_VIDEO: + case AVMEDIA_TYPE_VIDEO: if (vst) return NULL; vst = s->streams[i]; break; - case CODEC_TYPE_AUDIO: + case AVMEDIA_TYPE_AUDIO: if (c->n_ast > 1) return NULL; c->ast[c->n_ast++] = s->streams[i]; break;