Index: src/core/SkStrokerPriv.cpp |
diff --git a/src/core/SkStrokerPriv.cpp b/src/core/SkStrokerPriv.cpp |
index fbd552abfd5dc10dc79b2e29c24e210ed2b9c035..bc8e0435a1e1dbd161003694c82995ca1c1e9195 100644 |
--- a/src/core/SkStrokerPriv.cpp |
+++ b/src/core/SkStrokerPriv.cpp |
@@ -22,21 +22,6 @@ static void RoundCapper(SkPath* path, const SkPoint& pivot, |
const SkVector& normal, const SkPoint& stop, |
SkPath*) |
{ |
-#ifdef SK_SUPPORT_LEGACY_ARCTO_QUADS |
- SkScalar px = pivot.fX; |
- SkScalar py = pivot.fY; |
- SkScalar nx = normal.fX; |
- SkScalar ny = normal.fY; |
- SkScalar sx = SkScalarMul(nx, CUBIC_ARC_FACTOR); |
- SkScalar sy = SkScalarMul(ny, CUBIC_ARC_FACTOR); |
- |
- path->cubicTo(px + nx + CWX(sx, sy), py + ny + CWY(sx, sy), |
- px + CWX(nx, ny) + sx, py + CWY(nx, ny) + sy, |
- px + CWX(nx, ny), py + CWY(nx, ny)); |
- path->cubicTo(px + CWX(nx, ny) - sx, py + CWY(nx, ny) - sy, |
- px - nx + CWX(sx, sy), py - ny + CWY(sx, sy), |
- stop.fX, stop.fY); |
-#else |
SkVector parallel; |
normal.rotateCW(¶llel); |
@@ -44,7 +29,6 @@ static void RoundCapper(SkPath* path, const SkPoint& pivot, |
path->conicTo(projectedCenter + normal, projectedCenter, SK_ScalarRoot2Over2); |
path->conicTo(projectedCenter - normal, stop, SK_ScalarRoot2Over2); |
-#endif |
} |
static void SquareCapper(SkPath* path, const SkPoint& pivot, |
@@ -149,18 +133,6 @@ static void RoundJoiner(SkPath* outer, SkPath* inner, const SkVector& beforeUnit |
SkMatrix matrix; |
matrix.setScale(radius, radius); |
matrix.postTranslate(pivot.fX, pivot.fY); |
-#ifdef SK_SUPPORT_LEGACY_ARCTO_QUADS |
- SkPoint pts[kSkBuildQuadArcStorage]; |
- int count = SkBuildQuadArc(before, after, dir, &matrix, pts); |
- SkASSERT((count & 1) == 1); |
- if (count > 1) { |
- for (int i = 1; i < count; i += 2) { |
- outer->quadTo(pts[i].fX, pts[i].fY, pts[i+1].fX, pts[i+1].fY); |
- } |
- after.scale(radius); |
- HandleInnerJoin(inner, pivot, after); |
- } |
-#else |
SkConic conics[SkConic::kMaxConicsForArc]; |
int count = SkConic::BuildUnitArc(before, after, dir, &matrix, conics); |
if (count > 0) { |
@@ -170,7 +142,6 @@ static void RoundJoiner(SkPath* outer, SkPath* inner, const SkVector& beforeUnit |
after.scale(radius); |
HandleInnerJoin(inner, pivot, after); |
} |
-#endif |
} |
#define kOneOverSqrt2 (0.707106781f) |