Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(287)

Unified Diff: src/gpu/SkGpuDevice.cpp

Issue 926593005: Use SkXfermode as public facing enum for GrPorterDuffXP (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Review fixes Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/GrPipelineBuilder.h ('k') | src/gpu/effects/GrCoverageSetOpXP.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/SkGpuDevice.cpp
diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp
index 8912851d8f369c88a9b36aeb7d281c8b2490c690..b6cc69d8587cb0d8ff7dc46a7bf2b38dcc4b5d46 100644
--- a/src/gpu/SkGpuDevice.cpp
+++ b/src/gpu/SkGpuDevice.cpp
@@ -9,7 +9,6 @@
#include "effects/GrBicubicEffect.h"
#include "effects/GrDashingEffect.h"
-#include "effects/GrPorterDuffXferProcessor.h"
#include "effects/GrTextureDomain.h"
#include "effects/GrSimpleTextureEffect.h"
@@ -677,16 +676,8 @@ GrTexture* create_mask_GPU(GrContext* context,
context->clear(NULL, 0x0, true, mask->asRenderTarget());
GrPaint tempPaint;
- if (doAA) {
- tempPaint.setAntiAlias(true);
- // AA uses the "coverage" stages on GrDrawTarget. Coverage with a dst
- // blend coeff of zero requires dual source blending support in order
- // to properly blend partially covered pixels. This means the AA
- // code path may not be taken. So we use a dst blend coeff of ISA. We
- // could special case AA draws to a dst surface with known alpha=0 to
- // use a zero dst coeff when dual source blending isn't available.
- tempPaint.setPorterDuffXPFactory(kOne_GrBlendCoeff, kISC_GrBlendCoeff);
- }
+ tempPaint.setAntiAlias(doAA);
+ tempPaint.setCoverageSetOpXPFactory(SkRegion::kReplace_Op);
// Draw the mask into maskTexture with the path's top-left at the origin using tempPaint.
SkMatrix translate;
« no previous file with comments | « src/gpu/GrPipelineBuilder.h ('k') | src/gpu/effects/GrCoverageSetOpXP.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698