[vlc-commits] avcodec: add mappings for gbrp 9/10-bit LE,BE

Tristan Matthews git at videolan.org
Wed Jun 24 23:24:00 CEST 2015


vlc/vlc-2.2 | branch: master | Tristan Matthews <tmatth at videolan.org> | Wed Jun 24 14:28:06 2015 -0600| [6a7b82adcf3bb9010aad0d48acb0d06ed7e00664] | committer: Tristan Matthews

avcodec: add mappings for gbrp 9/10-bit LE,BE

(cherry-picked from commit 22a9c02f42a0070cfcdf5c8de2a09e692d6b9fc4)
Fixes #14909

> http://git.videolan.org/gitweb.cgi/vlc/vlc-2.2.git/?a=commit;h=6a7b82adcf3bb9010aad0d48acb0d06ed7e00664
---

 NEWS                           |    1 +
 modules/codec/avcodec/chroma.c |    4 ++++
 src/misc/fourcc.c              |    4 ++++
 3 files changed, 9 insertions(+)

diff --git a/NEWS b/NEWS
index 1ac1c5d..729cf09 100644
--- a/NEWS
+++ b/NEWS
@@ -14,6 +14,7 @@ Demux:
 Decoders:
  * Fix importing surface from main memory in VDPAU
  * Fix possible double-free in ADPCM decoder
+ * Support 9-bit and 10-bit GBR planar formats
 
 Audio output:
  * Fix audio drop after a flush with pulseaudio
diff --git a/modules/codec/avcodec/chroma.c b/modules/codec/avcodec/chroma.c
index fbbe29a..393364b 100644
--- a/modules/codec/avcodec/chroma.c
+++ b/modules/codec/avcodec/chroma.c
@@ -136,6 +136,10 @@ static const struct
 
 #if LIBAVUTIL_VERSION_CHECK(51, 42, 0, 74,100)
     {VLC_CODEC_GBR_PLANAR, AV_PIX_FMT_GBRP, 0, 0, 0 },
+    {VLC_CODEC_GBR_PLANAR_9L, AV_PIX_FMT_GBRP9LE, 0, 0, 0 },
+    {VLC_CODEC_GBR_PLANAR_9B, AV_PIX_FMT_GBRP9BE, 0, 0, 0 },
+    {VLC_CODEC_GBR_PLANAR_10L, AV_PIX_FMT_GBRP10LE, 0, 0, 0 },
+    {VLC_CODEC_GBR_PLANAR_10B, AV_PIX_FMT_GBRP10BE, 0, 0, 0 },
 #endif
 
     /* XYZ */
diff --git a/src/misc/fourcc.c b/src/misc/fourcc.c
index d76ae11..bed372d 100644
--- a/src/misc/fourcc.c
+++ b/src/misc/fourcc.c
@@ -2062,6 +2062,10 @@ static const struct
     { { VLC_CODEC_YUV422A },                   PLANAR_8(4, 2, 1) },
 
     { { VLC_CODEC_GBR_PLANAR },                PLANAR_8(3, 1, 1) },
+    { { VLC_CODEC_GBR_PLANAR_9L,
+        VLC_CODEC_GBR_PLANAR_9B },             PLANAR_16(3, 1, 1, 9) },
+    { { VLC_CODEC_GBR_PLANAR_10L,
+        VLC_CODEC_GBR_PLANAR_10B },            PLANAR_16(3, 1, 1, 10) },
 
     { { VLC_CODEC_I420_10L,
         VLC_CODEC_I420_10B },                  PLANAR_16(3, 2, 2, 10) },



More information about the vlc-commits mailing list