Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1431)

Unified Diff: media/base/yuv_convert.h

Issue 242643011: Add correct support for videos with YUVJ420P color format, in the software conversion path. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@yuvnopic
Patch Set: YUVJ browsertest now passes, update expectation Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/base/simd/yuv_to_rgb_table.cc ('k') | media/base/yuv_convert.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/yuv_convert.h
diff --git a/media/base/yuv_convert.h b/media/base/yuv_convert.h
index 8f64c79689a3dfaf33a1944d23d4e1ac66655f6b..cf13edb17ab285ff5e74e52e2a26fce2f7a5cdff 100644
--- a/media/base/yuv_convert.h
+++ b/media/base/yuv_convert.h
@@ -7,6 +7,7 @@
#include "base/basictypes.h"
#include "media/base/media_export.h"
+#include "media/base/simd/yuv_to_rgb_table.h"
// Visual Studio 2010 does not support MMX intrinsics on x64.
// Some win64 yuv_convert code paths use SSE+MMX yasm, so without rewriting
@@ -22,12 +23,18 @@
namespace media {
// Type of YUV surface.
-// The value of these enums matter as they are used to shift vertical indices.
enum YUVType {
- YV16 = 0, // YV16 is half width and full height chroma channels.
- YV12 = 1, // YV12 is half width and half height chroma channels.
+ YV16 = 0, // YV16 is half width and full height chroma channels.
+ YV12 = 1, // YV12 is half width and half height chroma channels.
+ YV12J = 2, // YV12J is the same as YV12, but in JPEG color range.
};
+// Get the appropriate value to bitshift by for vertical indices.
+MEDIA_EXPORT int GetVerticalShift(YUVType type);
+
+// Get the appropriate lookup table for a given YUV format.
+MEDIA_EXPORT const int16 (&GetLookupTable(YUVType type))[1024][4];
+
// Mirror means flip the image horizontally, as in looking in a mirror.
// Rotate happens after mirroring.
enum Rotate {
« no previous file with comments | « media/base/simd/yuv_to_rgb_table.cc ('k') | media/base/yuv_convert.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698