diff mbox series

[FFmpeg-devel,03/16] swscale: add P210/P410/P216/P416 input

Message ID 20211122215821.9849-3-rcombs@rcombs.me
State Accepted
Commit f0204de47d30e40b3f954fa0a15d76a48bcb5afd
Headers show
Series [FFmpeg-devel,01/16] ffmpeg: remove ffmpeg_videotoolbox
Related show

Checks

Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished
andriy/make_ppc success Make finished
andriy/make_fate_ppc success Make fate finished

Commit Message

rcombs Nov. 22, 2021, 9:58 p.m. UTC
---
 libswscale/input.c   | 16 ++++++++++++++++
 libswscale/utils.c   |  8 ++++++++
 libswscale/version.h |  2 +-
 3 files changed, 25 insertions(+), 1 deletion(-)

Comments

Michael Niedermayer Nov. 24, 2021, 7:33 p.m. UTC | #1
On Mon, Nov 22, 2021 at 03:58:08PM -0600, rcombs wrote:
> ---
>  libswscale/input.c   | 16 ++++++++++++++++
>  libswscale/utils.c   |  8 ++++++++
>  libswscale/version.h |  2 +-
>  3 files changed, 25 insertions(+), 1 deletion(-)

should be ok (assuming any dependant changes are in / fate passes)

thx

[...]
diff mbox series

Patch

diff --git a/libswscale/input.c b/libswscale/input.c
index 1351ea5bd4..6acc39f89f 100644
--- a/libswscale/input.c
+++ b/libswscale/input.c
@@ -1238,15 +1238,23 @@  av_cold void ff_sws_init_input_funcs(SwsContext *c)
         c->chrToYV12 = read_ayuv64le_UV_c;
         break;
     case AV_PIX_FMT_P010LE:
+    case AV_PIX_FMT_P210LE:
+    case AV_PIX_FMT_P410LE:
         c->chrToYV12 = p010LEToUV_c;
         break;
     case AV_PIX_FMT_P010BE:
+    case AV_PIX_FMT_P210BE:
+    case AV_PIX_FMT_P410BE:
         c->chrToYV12 = p010BEToUV_c;
         break;
     case AV_PIX_FMT_P016LE:
+    case AV_PIX_FMT_P216LE:
+    case AV_PIX_FMT_P416LE:
         c->chrToYV12 = p016LEToUV_c;
         break;
     case AV_PIX_FMT_P016BE:
+    case AV_PIX_FMT_P216BE:
+    case AV_PIX_FMT_P416BE:
         c->chrToYV12 = p016BEToUV_c;
         break;
     case AV_PIX_FMT_Y210LE:
@@ -1519,6 +1527,8 @@  av_cold void ff_sws_init_input_funcs(SwsContext *c)
     case AV_PIX_FMT_GRAY16LE:
 
     case AV_PIX_FMT_P016LE:
+    case AV_PIX_FMT_P216LE:
+    case AV_PIX_FMT_P416LE:
         c->lumToYV12 = bswap16Y_c;
         break;
     case AV_PIX_FMT_YUVA420P9LE:
@@ -1561,6 +1571,8 @@  av_cold void ff_sws_init_input_funcs(SwsContext *c)
     case AV_PIX_FMT_GRAY16BE:
 
     case AV_PIX_FMT_P016BE:
+    case AV_PIX_FMT_P216BE:
+    case AV_PIX_FMT_P416BE:
         c->lumToYV12 = bswap16Y_c;
         break;
     case AV_PIX_FMT_YUVA420P9BE:
@@ -1687,9 +1699,13 @@  av_cold void ff_sws_init_input_funcs(SwsContext *c)
         c->lumToYV12 = bgr64LEToY_c;
         break;
     case AV_PIX_FMT_P010LE:
+    case AV_PIX_FMT_P210LE:
+    case AV_PIX_FMT_P410LE:
         c->lumToYV12 = p010LEToY_c;
         break;
     case AV_PIX_FMT_P010BE:
+    case AV_PIX_FMT_P210BE:
+    case AV_PIX_FMT_P410BE:
         c->lumToYV12 = p010BEToY_c;
         break;
     case AV_PIX_FMT_GRAYF32LE:
diff --git a/libswscale/utils.c b/libswscale/utils.c
index c726922527..ae92ac9fbc 100644
--- a/libswscale/utils.c
+++ b/libswscale/utils.c
@@ -268,6 +268,14 @@  static const FormatEntry format_entries[] = {
     [AV_PIX_FMT_Y210LE]      = { 1, 0 },
     [AV_PIX_FMT_X2RGB10LE]   = { 1, 1 },
     [AV_PIX_FMT_X2BGR10LE]   = { 1, 1 },
+    [AV_PIX_FMT_P210BE]      = { 1, 0 },
+    [AV_PIX_FMT_P210LE]      = { 1, 0 },
+    [AV_PIX_FMT_P410BE]      = { 1, 0 },
+    [AV_PIX_FMT_P410LE]      = { 1, 0 },
+    [AV_PIX_FMT_P216BE]      = { 1, 0 },
+    [AV_PIX_FMT_P216LE]      = { 1, 0 },
+    [AV_PIX_FMT_P416BE]      = { 1, 0 },
+    [AV_PIX_FMT_P416LE]      = { 1, 0 },
 };
 
 int sws_isSupportedInput(enum AVPixelFormat pix_fmt)
diff --git a/libswscale/version.h b/libswscale/version.h
index 0d3b7cf363..15ad54319c 100644
--- a/libswscale/version.h
+++ b/libswscale/version.h
@@ -28,7 +28,7 @@ 
 
 #define LIBSWSCALE_VERSION_MAJOR   6
 #define LIBSWSCALE_VERSION_MINOR   1
-#define LIBSWSCALE_VERSION_MICRO 100
+#define LIBSWSCALE_VERSION_MICRO 101
 
 #define LIBSWSCALE_VERSION_INT  AV_VERSION_INT(LIBSWSCALE_VERSION_MAJOR, \
                                                LIBSWSCALE_VERSION_MINOR, \