[FFmpeg-devel] [PATCH] avfilter/extractplanes: add support for 12-bit YUVA formats

Gyan ffmpeg at gyani.pro
Thu Jan 17 11:47:13 EET 2019


Fixes alpha extraction for sample at

https://08488297638989341201.googlegroups.com/attach/85d30cd6b8095/Circle%20Ink%20Bleed_10.mov

as seen in

     ffplay -i in -vf alphaextract

Gyan
-------------- next part --------------
From 122f500e09b2741f3865da5c3f612ee04dcd7e21 Mon Sep 17 00:00:00 2001
From: Gyan Doshi <ffmpeg at gyani.pro>
Date: Thu, 17 Jan 2019 15:01:11 +0530
Subject: [PATCH] avfilter/extractplanes: add support for 12-bit YUVA formats

At present, 16-bit auto-scaled format results in incorrect alpha
extraction.
---
 libavfilter/vf_extractplanes.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavfilter/vf_extractplanes.c b/libavfilter/vf_extractplanes.c
index f9171572ed..739c2420cb 100644
--- a/libavfilter/vf_extractplanes.c
+++ b/libavfilter/vf_extractplanes.c
@@ -99,6 +99,8 @@ AVFILTER_DEFINE_CLASS(extractplanes);
         AV_PIX_FMT_YUV422P12##suf,                             \
         AV_PIX_FMT_YUV444P12##suf,                             \
         AV_PIX_FMT_YUV440P12##suf,                             \
+        AV_PIX_FMT_YUVA422P12##suf,                            \
+        AV_PIX_FMT_YUVA444P12##suf,                            \
         AV_PIX_FMT_GBRP10##suf, AV_PIX_FMT_GBRAP10##suf,       \
         AV_PIX_FMT_GBRP12##suf, AV_PIX_FMT_GBRAP12##suf,       \
         AV_PIX_FMT_YUV420P9##suf,                              \
-- 
2.19.2


More information about the ffmpeg-devel mailing list