OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2006 The Android Open Source Project | 2 * Copyright 2006 The Android Open Source Project |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #ifndef SkPathMeasure_DEFINED | 8 #ifndef SkPathMeasure_DEFINED |
9 #define SkPathMeasure_DEFINED | 9 #define SkPathMeasure_DEFINED |
10 | 10 |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 SkScalar getScalarT() const; | 100 SkScalar getScalarT() const; |
101 }; | 101 }; |
102 SkTDArray<Segment> fSegments; | 102 SkTDArray<Segment> fSegments; |
103 SkTDArray<SkPoint> fPts; // Points used to define the segments | 103 SkTDArray<SkPoint> fPts; // Points used to define the segments |
104 | 104 |
105 static const Segment* NextSegment(const Segment*); | 105 static const Segment* NextSegment(const Segment*); |
106 | 106 |
107 void buildSegments(); | 107 void buildSegments(); |
108 SkScalar compute_quad_segs(const SkPoint pts[3], SkScalar distance, | 108 SkScalar compute_quad_segs(const SkPoint pts[3], SkScalar distance, |
109 int mint, int maxt, int ptIndex); | 109 int mint, int maxt, int ptIndex); |
| 110 #ifdef SK_SUPPORT_LEGACY_CONIC_MEASURE |
110 SkScalar compute_conic_segs(const SkConic&, SkScalar distance, int mint, int
maxt, int ptIndex); | 111 SkScalar compute_conic_segs(const SkConic&, SkScalar distance, int mint, int
maxt, int ptIndex); |
| 112 #else |
| 113 SkScalar compute_conic_segs(const SkConic&, SkScalar distance, |
| 114 int mint, const SkPoint& minPt, |
| 115 int maxt, const SkPoint& maxPt, int ptIndex); |
| 116 #endif |
111 SkScalar compute_cubic_segs(const SkPoint pts[3], SkScalar distance, | 117 SkScalar compute_cubic_segs(const SkPoint pts[3], SkScalar distance, |
112 int mint, int maxt, int ptIndex); | 118 int mint, int maxt, int ptIndex); |
113 const Segment* distanceToSegment(SkScalar distance, SkScalar* t); | 119 const Segment* distanceToSegment(SkScalar distance, SkScalar* t); |
114 }; | 120 }; |
115 | 121 |
116 #endif | 122 #endif |
OLD | NEW |