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

Unified Diff: include/core/SkMatrix44.h

Issue 2085653003: Enable flattening and unflattening of SkColorSpace (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Fix unit tests Created 4 years, 6 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 | « include/core/SkColorSpace.h ('k') | src/core/SkColorSpace.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkMatrix44.h
diff --git a/include/core/SkMatrix44.h b/include/core/SkMatrix44.h
index d64d4b7074055e489ed673ffa75c31bc9d869bf7..715ee782c868d6b1b65525860934a7a4e8f73e70 100644
--- a/include/core/SkMatrix44.h
+++ b/include/core/SkMatrix44.h
@@ -439,6 +439,15 @@ private:
kAllPublic_Masks = 0xF
};
+ /** Efficiently reads 12 matrix entries, ignoring the last col.
+ * This is typically useful when we know the last col is (0, 0, 0, 1).
+ */
+ void as4x3ColMajorf(float[]) const;
+
+ /* This sets the top-left of the matrix and clears the
+ * perspective components (with [3][3] set to 1). */
+ void set4x3ColMajorf(const float[]);
+
SkMScalar transX() const { return fMat[3][0]; }
SkMScalar transY() const { return fMat[3][1]; }
SkMScalar transZ() const { return fMat[3][2]; }
@@ -469,6 +478,8 @@ private:
inline bool isTriviallyIdentity() const {
return 0 == fTypeMask;
}
+
+ friend class SkColorSpace;
};
#endif
« no previous file with comments | « include/core/SkColorSpace.h ('k') | src/core/SkColorSpace.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698