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

Unified Diff: ui/gfx/color_space.h

Issue 2670773002: Towards deleting YUV to RGB computation redundancy (Closed)
Patch Set: Created 3 years, 11 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: ui/gfx/color_space.h
diff --git a/ui/gfx/color_space.h b/ui/gfx/color_space.h
index fbbb78690df39aa52a701190369f4ae979912155..1f12b0a810e7c847ababf144d8e3d47bd83a8aad 100644
--- a/ui/gfx/color_space.h
+++ b/ui/gfx/color_space.h
@@ -178,6 +178,10 @@ class GFX_EXPORT ColorSpace {
bool GetTransferFunction(SkColorSpaceTransferFn* fn) const;
bool GetInverseTransferFunction(SkColorSpaceTransferFn* fn) const;
+ // For most formats, this is the RGB to YUV matrix.
+ void GetTransferMatrix(SkMatrix44* matrix) const;
hubbe 2017/02/02 04:51:37 Maybe return a bool since this is not always possi
ccameron 2017/02/02 17:33:52 I was going back-and-forth on this, but in the end
hubbe 2017/02/02 18:35:25 Doing so would make the implementation a lot bigge
+ void GetRangeAdjustMatrix(SkMatrix44* matrix) const;
+
private:
PrimaryID primaries_ = PrimaryID::UNSPECIFIED;
TransferID transfer_ = TransferID::UNSPECIFIED;

Powered by Google App Engine
This is Rietveld 408576698