Index: src/gpu/SkGpuDevice.cpp |
diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp |
index ce02f2c55fc97fa76beba1068cc36ae9277b44c6..4527dec1304e0be655d9225d828e7cd84a1bc628 100644 |
--- a/src/gpu/SkGpuDevice.cpp |
+++ b/src/gpu/SkGpuDevice.cpp |
@@ -904,7 +904,7 @@ void SkGpuDevice::drawPath(const SkDraw& draw, const SkPath& origSrcPath, |
// transform the path into device space |
pathPtr->transform(fContext->getMatrix(), devPathPtr); |
- |
+ |
SkRect maskRect; |
if (paint.getMaskFilter()->canFilterMaskGPU(devPathPtr->getBounds(), |
draw.fClip->getBounds(), |
@@ -920,6 +920,14 @@ void SkGpuDevice::drawPath(const SkDraw& draw, const SkPath& origSrcPath, |
// nothing to draw |
return; |
} |
+ |
+ bool doFill = paint.getStyle() == SkPaint::kFill_Style; |
+ |
+ if (paint.getMaskFilter()->directFilterMaskGPU(fContext, &grPaint, doFill, devPathPtr)) { |
+ // the mask filter was able to draw itself directly, so there's nothing |
+ // left to do. |
+ return; |
+ } |
GrAutoScratchTexture mask; |