Index: include/core/SkPathMeasure.h |
diff --git a/include/core/SkPathMeasure.h b/include/core/SkPathMeasure.h |
index 415ee2709c05891c631b0040c6ed7f3f81207bb9..8ca33f383f3ced5974525152475352ab54fdb444 100644 |
--- a/include/core/SkPathMeasure.h |
+++ b/include/core/SkPathMeasure.h |
@@ -21,7 +21,7 @@ public: |
a different path (or null), since the measure object keeps a pointer to the |
path object (does not copy its data). |
*/ |
- SkPathMeasure(const SkPath& path, bool forceClosed); |
+ SkPathMeasure(const SkPath& path, bool forceClosed, SkScalar resScale = 1); |
reed1
2016/01/21 14:33:59
// resScale controls the precision of the measure.
caryclark
2016/01/21 14:52:57
Done.
|
~SkPathMeasure(); |
/** Reset the pathmeasure with the specified path. The path must remain valid |
@@ -82,6 +82,7 @@ public: |
private: |
SkPath::Iter fIter; |
const SkPath* fPath; |
+ SkScalar fInvResScale; |
reed1
2016/01/21 14:33:59
nit: rename to fTolerance?
caryclark
2016/01/21 14:52:57
Done.
|
SkScalar fLength; // relative to the current contour |
int fFirstPtIndex; // relative to the current contour |
bool fIsClosed; // relative to the current contour |
@@ -117,6 +118,12 @@ private: |
SkScalar compute_cubic_segs(const SkPoint pts[3], SkScalar distance, |
int mint, int maxt, int ptIndex); |
const Segment* distanceToSegment(SkScalar distance, SkScalar* t); |
+ bool quad_too_curvy(const SkPoint pts[3]); |
+#ifndef SK_SUPPORT_LEGACY_CONIC_MEASURE |
+ bool conic_too_curvy(const SkPoint& firstPt, const SkPoint& midTPt,const SkPoint& lastPt); |
+#endif |
+ bool cheap_dist_exceeds_limit(const SkPoint& pt, SkScalar x, SkScalar y); |
+ bool cubic_too_curvy(const SkPoint pts[4]); |
}; |
#endif |