aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/mpeg12.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2003-08-26 07:42:25 +0000
committerMichael Niedermayer <michaelni@gmx.at>2003-08-26 07:42:25 +0000
commit922bc38d55995536e84db1b704fdccc140870d26 (patch)
tree4fc62daffb1badfa2042b0ba71271be898a2a9c5 /libavcodec/mpeg12.c
parente4eadb4b44a5bd446d2f83e92a7baeddb82448ad (diff)
downloadffmpeg-922bc38d55995536e84db1b704fdccc140870d26.tar.gz
mpeg2 regression test
add mpeg2video_decoder, thats more consistant with the encoders, note, both mpeg1video and mpeg2video decoder will happily decode both mpeg1 and 2 Originally committed as revision 2166 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/mpeg12.c')
-rw-r--r--libavcodec/mpeg12.c17
1 files changed, 15 insertions, 2 deletions
diff --git a/libavcodec/mpeg12.c b/libavcodec/mpeg12.c
index a2a1bbd7ac..d65ad86f21 100644
--- a/libavcodec/mpeg12.c
+++ b/libavcodec/mpeg12.c
@@ -2496,8 +2496,8 @@ static int mpeg_decode_end(AVCodecContext *avctx)
return 0;
}
-AVCodec mpeg_decoder = {
- "mpegvideo",
+AVCodec mpeg1video_decoder = {
+ "mpeg1video",
CODEC_TYPE_VIDEO,
CODEC_ID_MPEG1VIDEO,
sizeof(Mpeg1Context),
@@ -2509,6 +2509,19 @@ AVCodec mpeg_decoder = {
.flush= ff_mpeg_flush,
};
+AVCodec mpeg2video_decoder = {
+ "mpeg2video",
+ CODEC_TYPE_VIDEO,
+ CODEC_ID_MPEG2VIDEO,
+ sizeof(Mpeg1Context),
+ mpeg_decode_init,
+ NULL,
+ mpeg_decode_end,
+ mpeg_decode_frame,
+ CODEC_CAP_DRAW_HORIZ_BAND | CODEC_CAP_DR1 | CODEC_CAP_TRUNCATED,
+ .flush= ff_mpeg_flush,
+};
+
#ifdef HAVE_XVMC
static int mpeg_mc_decode_init(AVCodecContext *avctx){
Mpeg1Context *s;