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

Unified Diff: include/core/SkMatrix.h

Issue 2111703002: speed up maprect for scale+trans case (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: apply comments from #14 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 | « bench/MatrixBench.cpp ('k') | src/core/SkMatrix.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkMatrix.h
diff --git a/include/core/SkMatrix.h b/include/core/SkMatrix.h
index 6738a0eb69b17a1fa0a953acdd4c446815c1b1cc..d6d029597f14598dfeb4140767227b7ae7b506f2 100644
--- a/include/core/SkMatrix.h
+++ b/include/core/SkMatrix.h
@@ -561,6 +561,12 @@ public:
this->mapPoints(dst, 4);
}
+ /**
+ * Maps a rect to another rect, asserting (in debug mode) that the matrix only contains
+ * scale and translate elements. If it contains other elements, the results are undefined.
+ */
+ void mapRectScaleTranslate(SkRect* dst, const SkRect& src) const;
+
/** Return the mean radius of a circle after it has been mapped by
this matrix. NOTE: in perspective this value assumes the circle
has its center at the origin.
« no previous file with comments | « bench/MatrixBench.cpp ('k') | src/core/SkMatrix.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698