Revert[8] "replace SkXfermode obj with SkBlendMode enum in paints"
This reverts commit c245574ba3d0e2ade6c94b2812de3baa383bf4c4.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2396953002
TBR=
Review-Url: https://codereview.chromium.org/2396953002
diff --git a/src/gpu/GrContext.cpp b/src/gpu/GrContext.cpp
index 6cec1da..176d5da 100644
--- a/src/gpu/GrContext.cpp
+++ b/src/gpu/GrContext.cpp
@@ -356,7 +356,7 @@
}
GrPaint paint;
paint.addColorFragmentProcessor(std::move(fp));
- paint.setPorterDuffXPFactory(SkXfermode::kSrc_Mode);
+ paint.setPorterDuffXPFactory(SkBlendMode::kSrc);
paint.setAllowSRGBInputs(true);
SkRect rect = SkRect::MakeWH(SkIntToScalar(width), SkIntToScalar(height));
drawContext->drawRect(GrNoClip(), paint, matrix, rect, nullptr);
@@ -471,7 +471,7 @@
if (fp) {
GrPaint paint;
paint.addColorFragmentProcessor(std::move(fp));
- paint.setPorterDuffXPFactory(SkXfermode::kSrc_Mode);
+ paint.setPorterDuffXPFactory(SkBlendMode::kSrc);
paint.setAllowSRGBInputs(true);
SkRect rect = SkRect::MakeWH(SkIntToScalar(width), SkIntToScalar(height));
tempDC->drawRect(GrNoClip(), paint, SkMatrix::I(), rect, nullptr);