diff options
author | Paul B Mahol <onemda@gmail.com> | 2012-10-12 15:13:42 +0000 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2012-10-12 15:31:42 +0000 |
commit | a51540d81167547f1c7c2b8f545c246711611071 (patch) | |
tree | ed001a8c92dbf84c5dcaf0f434cb9ccb4519a27e /libavcodec/ffv1.c | |
parent | 27ccc82e1bb1b97a85e5fb33b92082267078b4d1 (diff) | |
download | ffmpeg-a51540d81167547f1c7c2b8f545c246711611071.tar.gz |
lavc: do not use av_pix_fmt_descriptors directly
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavcodec/ffv1.c')
-rw-r--r-- | libavcodec/ffv1.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/ffv1.c b/libavcodec/ffv1.c index c63a27f8aa..a09644eda4 100644 --- a/libavcodec/ffv1.c +++ b/libavcodec/ffv1.c @@ -916,6 +916,7 @@ static int sort_stt(FFV1Context *s, uint8_t stt[256]){ static av_cold int encode_init(AVCodecContext *avctx) { + const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(avctx->pix_fmt); FFV1Context *s = avctx->priv_data; int i, j, k, m; @@ -983,7 +984,7 @@ static av_cold int encode_init(AVCodecContext *avctx) case AV_PIX_FMT_YUV420P: case AV_PIX_FMT_YUV411P: case AV_PIX_FMT_YUV410P: - s->chroma_planes= av_pix_fmt_descriptors[avctx->pix_fmt].nb_components < 3 ? 0 : 1; + s->chroma_planes= desc->nb_components < 3 ? 0 : 1; s->colorspace= 0; break; case AV_PIX_FMT_YUVA444P: |