summaryrefslogtreecommitdiff
path: root/firefox-gtk2/firefox-support-YUV420J-pixel-format.patch
diff options
context:
space:
mode:
authorMark Weiman <mark.weiman@markzz.com>2016-01-02 01:22:31 -0500
committerMark Weiman <mark.weiman@markzz.com>2016-01-02 01:22:31 -0500
commit5c3b7276abf0d01b53662f38db5b4d52377343ed (patch)
tree8286ac3539ed49a2a1e9a65f8b7fca0976a06de6 /firefox-gtk2/firefox-support-YUV420J-pixel-format.patch
downloadmarkzz-5c3b7276abf0d01b53662f38db5b4d52377343ed.tar.gz
markzz-5c3b7276abf0d01b53662f38db5b4d52377343ed.zip
initial commit
Signed-off-by: Mark Weiman <mark.weiman@markzz.com>
Diffstat (limited to 'firefox-gtk2/firefox-support-YUV420J-pixel-format.patch')
-rw-r--r--firefox-gtk2/firefox-support-YUV420J-pixel-format.patch34
1 files changed, 34 insertions, 0 deletions
diff --git a/firefox-gtk2/firefox-support-YUV420J-pixel-format.patch b/firefox-gtk2/firefox-support-YUV420J-pixel-format.patch
new file mode 100644
index 0000000..178c589
--- /dev/null
+++ b/firefox-gtk2/firefox-support-YUV420J-pixel-format.patch
@@ -0,0 +1,34 @@
+
+# HG changeset patch
+# User Jean-Yves Avenard <jyavenard@mozilla.com>
+# Date 1450657258 -39600
+# Node ID 8b0ced62c1957f6da6028af686c32ada1ccb570c
+# Parent e1a98377eb38679bda820456ee6d20bdc17eaa8e
+Bug 1233340: [ffmpeg] Support YUV420J pixel format. r=kentuckyfriedtakahe
+
+YUV420J is 12bpp YUV420P.
+
+
+diff --git a/dom/media/platforms/ffmpeg/FFmpegDataDecoder.cpp b/dom/media/platforms/ffmpeg/FFmpegDataDecoder.cpp
+--- a/dom/media/platforms/ffmpeg/FFmpegDataDecoder.cpp
++++ b/dom/media/platforms/ffmpeg/FFmpegDataDecoder.cpp
+@@ -52,17 +52,17 @@ FFmpegDataDecoder<LIBAV_VER>::~FFmpegDat
+ * For now, we just look for YUV420P as it is the only non-HW accelerated format
+ * supported by FFmpeg's H264 decoder.
+ */
+ static PixelFormat
+ ChoosePixelFormat(AVCodecContext* aCodecContext, const PixelFormat* aFormats)
+ {
+ FFMPEG_LOG("Choosing FFmpeg pixel format for video decoding.");
+ for (; *aFormats > -1; aFormats++) {
+- if (*aFormats == PIX_FMT_YUV420P) {
++ if (*aFormats == PIX_FMT_YUV420P || *aFormats == PIX_FMT_YUVJ420P) {
+ FFMPEG_LOG("Requesting pixel format YUV420P.");
+ return PIX_FMT_YUV420P;
+ }
+ }
+
+ NS_WARNING("FFmpeg does not share any supported pixel formats.");
+ return PIX_FMT_NONE;
+ }
+