add explicit mapScalars and mapMScalars entry-points, instead of just map()
git-svn-id: http://skia.googlecode.com/svn/trunk@6373 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/include/utils/SkMatrix44.h b/include/utils/SkMatrix44.h
index c59aa75..9926b79 100644
--- a/include/utils/SkMatrix44.h
+++ b/include/utils/SkMatrix44.h
@@ -186,9 +186,29 @@
/** Apply the matrix to the src vector, returning the new vector in dst.
It is legal for src and dst to point to the same memory.
*/
- void map(const SkScalar src[4], SkScalar dst[4]) const;
+ void mapScalars(const SkScalar src[4], SkScalar dst[4]) const;
+ void mapScalars(SkScalar vec[4]) const {
+ this->mapScalars(vec, vec);
+ }
+
+ // DEPRECATED: call mapScalars()
+ void map(const SkScalar src[4], SkScalar dst[4]) const {
+ this->mapScalars(src, dst);
+ }
+ // DEPRECATED: call mapScalars()
void map(SkScalar vec[4]) const {
- this->map(vec, vec);
+ this->mapScalars(vec, vec);
+ }
+
+#ifdef SK_MSCALAR_IS_DOUBLE
+ void mapMScalars(SkMScalar src[4], SkMScalar dst[4]) const;
+#else
+ void mapMScalars(SkMScalar src[4], SkMScalar dst[4]) const {
+ this->mapScalars(src, dst);
+ }
+#endif
+ void mapMScalars(SkMScalar vec[4]) const {
+ this->mapMScalars(vec, vec);
}
friend SkVector4 operator*(const SkMatrix44& m, const SkVector4& src) {