move parts of SkPoint to SkPointPriv
Move specialized SkPoint methods to SkPointPriv.
Use constexpr and inline initialization where possible.
R=reed@google.com,bsalomon@google.com
Bug: skia: 6898
Change-Id: I01ec5186f010f2dc80c068c70d9cc352f3221338
Reviewed-on: https://skia-review.googlesource.com/68700
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Ravi Mistry <rmistry@google.com>
diff --git a/include/core/SkRRect.h b/include/core/SkRRect.h
index 28b3fc4..06edab9 100644
--- a/include/core/SkRRect.h
+++ b/include/core/SkRRect.h
@@ -234,15 +234,11 @@
}
friend bool operator==(const SkRRect& a, const SkRRect& b) {
- return a.fRect == b.fRect &&
- SkScalarsEqual(a.fRadii[0].asScalars(),
- b.fRadii[0].asScalars(), 8);
+ return a.fRect == b.fRect && SkScalarsEqual(&a.fRadii[0].fX, &b.fRadii[0].fX, 8);
}
friend bool operator!=(const SkRRect& a, const SkRRect& b) {
- return a.fRect != b.fRect ||
- !SkScalarsEqual(a.fRadii[0].asScalars(),
- b.fRadii[0].asScalars(), 8);
+ return a.fRect != b.fRect || !SkScalarsEqual(&a.fRadii[0].fX, &b.fRadii[0].fX, 8);
}
/**