Index: src/gpu/SkGr.cpp |
diff --git a/src/gpu/SkGr.cpp b/src/gpu/SkGr.cpp |
index 64142fe07e7acab7a9130fb95f36042e035b0292..a3972806f7c319df1160ca04980421bf3c97187f 100644 |
--- a/src/gpu/SkGr.cpp |
+++ b/src/gpu/SkGr.cpp |
@@ -514,15 +514,8 @@ void SkPaint2GrPaintNoShader(GrContext* context, const SkPaint& skPaint, GrColor |
grPaint->setAntiAlias(skPaint.isAntiAlias()); |
SkXfermode* mode = skPaint.getXfermode(); |
- GrFragmentProcessor* fragmentProcessor = NULL; |
GrXPFactory* xpFactory = NULL; |
- if (SkXfermode::AsFragmentProcessorOrXPFactory(mode, &fragmentProcessor, &xpFactory)) { |
- if (fragmentProcessor) { |
- SkASSERT(NULL == xpFactory); |
- grPaint->addColorProcessor(fragmentProcessor)->unref(); |
- xpFactory = GrPorterDuffXPFactory::Create(SkXfermode::kSrc_Mode); |
- } |
- } else { |
+ if (!SkXfermode::AsXPFactory(mode, &xpFactory)) { |
// Fall back to src-over |
xpFactory = GrPorterDuffXPFactory::Create(SkXfermode::kSrcOver_Mode); |
} |