Index: include/core/SkMatrix.h |
diff --git a/include/core/SkMatrix.h b/include/core/SkMatrix.h |
index a6edc1804fba2b0916056b8ae140290e74863629..71d9525962ef392ecae88303948c156a79c4dd2e 100644 |
--- a/include/core/SkMatrix.h |
+++ b/include/core/SkMatrix.h |
@@ -60,6 +60,10 @@ public: |
return this->getType() == 0; |
} |
+ bool isScaleTranslate() const { |
+ return !(this->getType() & ~(kScale_Mask | kTranslate_Mask)); |
+ } |
+ |
/** Returns true if will map a rectangle to another rectangle. This can be |
true if the matrix is identity, scale-only, or rotates a multiple of |
90 degrees. |