X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavcodec%2Flibvpxdec.c;h=c69e88899e8efab68cca2af55602e617df8fbcb6;hb=c508fef3c737321ad719db6ec62e1d011726baa8;hp=75231f8be736c748692df2ad084c41cd57a22dd7;hpb=ffed987a4d4afb8851d80b772eb9ee02cda20ef9;p=ffmpeg diff --git a/libavcodec/libvpxdec.c b/libavcodec/libvpxdec.c index 75231f8be73..c69e88899e8 100644 --- a/libavcodec/libvpxdec.c +++ b/libavcodec/libvpxdec.c @@ -72,6 +72,11 @@ static int set_pix_fmt(AVCodecContext *avctx, struct vpx_image *img) case VPX_IMG_FMT_I422: avctx->pix_fmt = AV_PIX_FMT_YUV422P; return 0; +#if VPX_IMAGE_ABI_VERSION >= 3 + case VPX_IMG_FMT_I440: + avctx->pix_fmt = AV_PIX_FMT_YUV440P; + return 0; +#endif case VPX_IMG_FMT_I444: avctx->pix_fmt = AV_PIX_FMT_YUV444P; return 0; @@ -96,6 +101,18 @@ static int set_pix_fmt(AVCodecContext *avctx, struct vpx_image *img) } else { return AVERROR_INVALIDDATA; } +#if VPX_IMAGE_ABI_VERSION >= 3 + case VPX_IMG_FMT_I44016: + if (img->bit_depth == 10) { + avctx->pix_fmt = AV_PIX_FMT_YUV440P10LE; + return 0; + } else if (img->bit_depth == 12) { + avctx->pix_fmt = AV_PIX_FMT_YUV440P12LE; + return 0; + } else { + return AVERROR_INVALIDDATA; + } +#endif case VPX_IMG_FMT_I44416: if (img->bit_depth == 10) { avctx->pix_fmt = AV_PIX_FMT_YUV444P10LE;