Index: src/gpu/GrStencilAndCoverPathRenderer.cpp |
=================================================================== |
--- src/gpu/GrStencilAndCoverPathRenderer.cpp (revision 11314) |
+++ src/gpu/GrStencilAndCoverPathRenderer.cpp (working copy) |
@@ -34,8 +34,7 @@ |
fGpu->unref(); |
} |
-bool GrStencilAndCoverPathRenderer::canDrawPath(const SkPath& path, |
- const SkStrokeRec& stroke, |
+bool GrStencilAndCoverPathRenderer::canDrawPath(const SkStrokeRec& stroke, |
const GrDrawTarget* target, |
bool antiAlias) const { |
return stroke.isFillStyle() && |
@@ -44,22 +43,19 @@ |
} |
GrPathRenderer::StencilSupport GrStencilAndCoverPathRenderer::onGetStencilSupport( |
- const SkPath&, |
const SkStrokeRec& , |
const GrDrawTarget*) const { |
return GrPathRenderer::kStencilOnly_StencilSupport; |
} |
-void GrStencilAndCoverPathRenderer::onStencilPath(const SkPath& path, |
- const SkStrokeRec& stroke, |
+void GrStencilAndCoverPathRenderer::onStencilPath(const SkStrokeRec& stroke, |
GrDrawTarget* target) { |
- SkASSERT(!path.isInverseFillType()); |
- SkAutoTUnref<GrPath> p(fGpu->createPath(path)); |
- target->stencilPath(p, stroke, path.getFillType()); |
+ SkASSERT(!fPath.isInverseFillType()); |
+ SkAutoTUnref<GrPath> p(fGpu->createPath(fPath)); |
+ target->stencilPath(p, stroke, fPath.getFillType()); |
} |
-bool GrStencilAndCoverPathRenderer::onDrawPath(const SkPath& path, |
- const SkStrokeRec& stroke, |
+bool GrStencilAndCoverPathRenderer::onDrawPath(const SkStrokeRec& stroke, |
GrDrawTarget* target, |
bool antiAlias) { |
SkASSERT(!antiAlias); |
@@ -68,9 +64,9 @@ |
GrDrawState* drawState = target->drawState(); |
SkASSERT(drawState->getStencil().isDisabled()); |
- SkAutoTUnref<GrPath> p(fGpu->createPath(path)); |
+ SkAutoTUnref<GrPath> p(fGpu->createPath(fPath)); |
- SkPath::FillType nonInvertedFill = SkPath::ConvertToNonInverseFillType(path.getFillType()); |
+ SkPath::FillType nonInvertedFill = SkPath::ConvertToNonInverseFillType(fPath.getFillType()); |
target->stencilPath(p, stroke, nonInvertedFill); |
// TODO: Use built in cover operation rather than a rect draw. This will require making our |
@@ -81,7 +77,7 @@ |
SkScalar bloat = drawState->getViewMatrix().getMaxStretch() * SK_ScalarHalf; |
GrDrawState::AutoViewMatrixRestore avmr; |
- if (nonInvertedFill == path.getFillType()) { |
+ if (nonInvertedFill == fPath.getFillType()) { |
GR_STATIC_CONST_SAME_STENCIL(kStencilPass, |
kZero_StencilOp, |
kZero_StencilOp, |