| Index: src/effects/SkBlurMaskFilter.cpp
|
| diff --git a/src/effects/SkBlurMaskFilter.cpp b/src/effects/SkBlurMaskFilter.cpp
|
| index b5bcc3c5de9b9dbdba9378ec8b93790f44f7782a..6fbc8b4c165c66f91177ca3a0235ccd80b4022e8 100644
|
| --- a/src/effects/SkBlurMaskFilter.cpp
|
| +++ b/src/effects/SkBlurMaskFilter.cpp
|
| @@ -24,6 +24,7 @@
|
| #include "GrInvariantOutput.h"
|
| #include "gl/GrGLProcessor.h"
|
| #include "gl/builders/GrGLProgramBuilder.h"
|
| +#include "effects/GrPorterDuffXferProcessor.h"
|
| #include "effects/GrSimpleTextureEffect.h"
|
| #include "GrTBackendProcessorFactory.h"
|
| #include "SkGrPixelRef.h"
|
| @@ -1221,15 +1222,21 @@ bool SkBlurMaskFilterImpl::filterMaskGPU(GrTexture* src,
|
| paint.addColorProcessor(GrSimpleTextureEffect::Create(src, matrix))->unref();
|
| if (kInner_SkBlurStyle == fBlurStyle) {
|
| // inner: dst = dst * src
|
| - paint.setBlendFunc(kDC_GrBlendCoeff, kZero_GrBlendCoeff);
|
| + GrXPFactory* xpFactory = GrPorterDuffXPFactory::Create(kDC_GrBlendCoeff,
|
| + kZero_GrBlendCoeff);
|
| + paint.setXPFactory(xpFactory)->unref();
|
| } else if (kSolid_SkBlurStyle == fBlurStyle) {
|
| // solid: dst = src + dst - src * dst
|
| // = (1 - dst) * src + 1 * dst
|
| - paint.setBlendFunc(kIDC_GrBlendCoeff, kOne_GrBlendCoeff);
|
| + GrXPFactory* xpFactory = GrPorterDuffXPFactory::Create(kIDC_GrBlendCoeff,
|
| + kOne_GrBlendCoeff);
|
| + paint.setXPFactory(xpFactory)->unref();
|
| } else if (kOuter_SkBlurStyle == fBlurStyle) {
|
| // outer: dst = dst * (1 - src)
|
| // = 0 * src + (1 - src) * dst
|
| - paint.setBlendFunc(kZero_GrBlendCoeff, kISC_GrBlendCoeff);
|
| + GrXPFactory* xpFactory = GrPorterDuffXPFactory::Create(kZero_GrBlendCoeff,
|
| + kISC_GrBlendCoeff);
|
| + paint.setXPFactory(xpFactory)->unref();
|
| }
|
| context->drawRect(paint, clipRect);
|
| }
|
|
|