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

Unified Diff: src/gpu/SkGpuDevice.cpp

Issue 374923002: Goodbye GrEffectRef. (Closed) Base URL: https://skia.googlesource.com/skia.git@noref3
Patch Set: Address comments Created 6 years, 5 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/GrOvalRenderer.cpp ('k') | src/gpu/SkGr.cpp » ('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 cf152fa6e51b023027c697250b06fd1fb05725dd..76e6ef79f025f9719ae4c091e509b1fb2f1160be 100644
--- a/src/gpu/SkGpuDevice.cpp
+++ b/src/gpu/SkGpuDevice.cpp
@@ -1327,7 +1327,7 @@ void SkGpuDevice::internalDrawBitmap(const SkBitmap& bitmap,
SkScalarMul(srcRect.fBottom, hInv));
SkRect textureDomain = SkRect::MakeEmpty();
- SkAutoTUnref<GrEffectRef> effect;
+ SkAutoTUnref<GrEffect> effect;
if (needsTextureDomain && !(flags & SkCanvas::kBleed_DrawBitmapRectFlag)) {
// Use a constrained texture domain to avoid color bleeding
SkScalar left, top, right, bottom;
@@ -1368,9 +1368,9 @@ void SkGpuDevice::internalDrawBitmap(const SkBitmap& bitmap,
GrPaint grPaint;
grPaint.addColorEffect(effect);
bool alphaOnly = !(kAlpha_8_SkColorType == bitmap.colorType());
- GrColor grColor = (alphaOnly) ? SkColor2GrColorJustAlpha(paint.getColor()) :
- SkColor2GrColor(paint.getColor());
- SkPaint2GrPaintNoShader(this->context(), paint, grColor, false, &grPaint);
+ GrColor paintColor = (alphaOnly) ? SkColor2GrColorJustAlpha(paint.getColor()) :
+ SkColor2GrColor(paint.getColor());
+ SkPaint2GrPaintNoShader(this->context(), paint, paintColor, false, &grPaint);
fContext->drawRectToRect(grPaint, dstRect, paintRect, NULL);
}
« no previous file with comments | « src/gpu/GrOvalRenderer.cpp ('k') | src/gpu/SkGr.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698