diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2009-02-24 18:27:52 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2009-02-24 18:27:52 +0000 |
commit | 09a9b45e4fa77a533391184ace5cadb30c6b83c7 (patch) | |
tree | 34f02c95a47afb6caa773b065708f3402e4ed3d7 /libavcodec/h264.c | |
parent | c0aec489a67d0d228ddc0a2931774a68f857eaaf (diff) | |
download | ffmpeg-09a9b45e4fa77a533391184ace5cadb30c6b83c7.tar.gz |
Add and use ff_pixfmt_list_420.
Originally committed as revision 17564 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/h264.c')
-rw-r--r-- | libavcodec/h264.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c index 4537fb179f..f5d2a8082a 100644 --- a/libavcodec/h264.c +++ b/libavcodec/h264.c @@ -2178,12 +2178,10 @@ static av_cold int decode_init(AVCodecContext *avctx){ s->quarter_sample = 1; s->low_delay= 1; - if(avctx->codec_id == CODEC_ID_SVQ3) - avctx->pix_fmt= PIX_FMT_YUVJ420P; - else if(s->avctx->codec->capabilities&CODEC_CAP_HWACCEL_VDPAU) + if(s->avctx->codec->capabilities&CODEC_CAP_HWACCEL_VDPAU) avctx->pix_fmt= PIX_FMT_VDPAU_H264; else - avctx->pix_fmt= PIX_FMT_YUV420P; + avctx->pix_fmt= avctx->get_format(avctx, avctx->codec->pix_fmts); decode_init_vlc(); @@ -8097,6 +8095,7 @@ AVCodec h264_decoder = { /*CODEC_CAP_DRAW_HORIZ_BAND |*/ CODEC_CAP_DR1 | CODEC_CAP_DELAY, .flush= flush_dpb, .long_name = NULL_IF_CONFIG_SMALL("H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10"), + .pix_fmts= ff_pixfmt_list_420, }; #if CONFIG_H264_VDPAU_DECODER |