Chromium Code Reviews| Index: src/gpu/GrAAConvexPathRenderer.cpp |
| diff --git a/src/gpu/GrAAConvexPathRenderer.cpp b/src/gpu/GrAAConvexPathRenderer.cpp |
| index 311010fcd9e15dc571b9daf856950351f593b76f..3f4a2f1fad7c70614005e99196308fa9a0bf895c 100644 |
| --- a/src/gpu/GrAAConvexPathRenderer.cpp |
| +++ b/src/gpu/GrAAConvexPathRenderer.cpp |
| @@ -15,6 +15,7 @@ |
| #include "GrInvariantOutput.h" |
| #include "GrProcessor.h" |
| #include "GrPathUtils.h" |
| +#include "SkGeometry.h" |
| #include "SkString.h" |
| #include "SkStrokeRec.h" |
| #include "SkTraceEvent.h" |
| @@ -307,6 +308,16 @@ static bool get_segments(const SkPath& path, |
| update_degenerate_test(°enerateData, pts[2]); |
| add_quad_segment(pts, segments, devBounds); |
| break; |
| + case SkPath::kConic_Verb: { |
| + m.mapPoints(pts, 3); |
| + SkScalar weight = iter.conicWeight(); |
| + SkAutoConicToQuads converter; |
| + const SkPoint* quadPts = converter.computeQuads(pts, weight, 0.5f); |
| + for (int i = 0; i < converter.countQuads(); ++i) { |
| + add_quad_segment(quadPts + 2*i, segments, devBounds); |
|
reed1
2014/12/22 20:04:09
update_degenerate_test twice?
egdaniel
2014/12/22 21:37:13
Done.
|
| + } |
| + break; |
| + } |
| case SkPath::kCubic_Verb: { |
| m.mapPoints(pts, 4); |
| update_degenerate_test(°enerateData, pts[1]); |