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

Unified Diff: gm/shadows.cpp

Issue 1793303002: Reland of "more shader-->sp conversions (patchset #5 id:80001 of https://codereview.chromium… (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: make pictureRef a value, so its clearer what's going on Created 4 years, 9 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 | « gm/shadertext3.cpp ('k') | gm/shallowgradient.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/shadows.cpp
diff --git a/gm/shadows.cpp b/gm/shadows.cpp
index bb2bf3c5bd3cd287ed316f2f3005068d1126a85f..5696240d21ed3ca00b7603b0b8ce0ff53b6e3c85 100644
--- a/gm/shadows.cpp
+++ b/gm/shadows.cpp
@@ -128,12 +128,11 @@ protected:
canvas->drawBitmap(fBitmap, 10, 10, &paint);
canvas->translate(0, 40);
- SkAutoTUnref<SkShader> shader(SkShader::CreateBitmapShader(
+ paint.setShader(SkShader::MakeBitmapShader(
fBitmap, SkShader::kRepeat_TileMode,
SkShader::kRepeat_TileMode));
// see bug.skia.org/562 (shows bug as reported)
- paint.setShader(shader);
paint.setStyle(SkPaint::kFill_Style);
canvas->drawRect(SkRect::MakeXYWH(10, 10, 20, 20), paint);
paint.setShader(nullptr);
« no previous file with comments | « gm/shadertext3.cpp ('k') | gm/shallowgradient.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698