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

Unified Diff: include/core/SkPixelRef.h

Issue 374743003: Skia side RGB to YUV gpu conversion (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Some changes to getYUV8Planes() Created 6 years, 5 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
Index: include/core/SkPixelRef.h
diff --git a/include/core/SkPixelRef.h b/include/core/SkPixelRef.h
index 263145ba3d90baefabd5552cefed18892fed1c02..ccdbceaec96e0930ae7c1adc15ae69ba1fef4327 100644
--- a/include/core/SkPixelRef.h
+++ b/include/core/SkPixelRef.h
@@ -14,6 +14,7 @@
#include "SkString.h"
#include "SkFlattenable.h"
#include "SkImageInfo.h"
+#include "SkSize.h"
#include "SkTDArray.h"
//#define xed
@@ -227,6 +228,16 @@ public:
*/
virtual GrTexture* getTexture() { return NULL; }
+ /**
+ * If the 2nd argument is NULL, this should output the sizes and return true
+ * if it can efficiently return YUV planar data. If it cannot, it should return false.
+ *
+ * If the 2nd argument is not NULL, then it should copy the associated Y,U,V data
+ * into those planes of memory supplied by the caller. It should validate that the sizes
+ * match what it expected. If the sizes do not match, it should return false.
+ */
robertphillips 2014/07/10 12:47:20 SkISize sizes[3], void* planes[3], int rowBytes[3]
sugoi1 2014/07/10 16:10:52 Done.
+ virtual bool getYUV8Planes(SkISize*, void*) { return false; }
+
bool readPixels(SkBitmap* dst, const SkIRect* subset = NULL);
/**
« no previous file with comments | « include/core/SkImageGenerator.h ('k') | src/core/SkImageGenerator.cpp » ('j') | src/gpu/SkGr.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698