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

Unified Diff: gm/imagefilterscropexpand.cpp

Issue 1789633002: more shader-->sp conversions (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 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
Index: gm/imagefilterscropexpand.cpp
diff --git a/gm/imagefilterscropexpand.cpp b/gm/imagefilterscropexpand.cpp
index 9ceab2036a6e667ec282e8dc68eebb2b226eab00..185bbde0a6628c7103a73b1c8fe9426f8303a51d 100644
--- a/gm/imagefilterscropexpand.cpp
+++ b/gm/imagefilterscropexpand.cpp
@@ -151,12 +151,9 @@ private:
SkColor colors[2];
colors[0] = SK_ColorWHITE;
colors[1] = SK_ColorBLACK;
- SkAutoTUnref<SkShader> shader(
- SkGradientShader::CreateRadial(SkPoint::Make(x, y), radius, colors, nullptr, 2,
- SkShader::kClamp_TileMode)
- );
SkPaint paint;
- paint.setShader(shader);
+ paint.setShader(SkGradientShader::MakeRadial(SkPoint::Make(x, y), radius, colors, nullptr,
+ 2, SkShader::kClamp_TileMode));
canvas->drawCircle(x, y, radius, paint);
return surface->newImageSnapshot();
« no previous file with comments | « gm/imagefiltersclipped.cpp ('k') | gm/imagefiltersscaled.cpp » ('j') | gm/pictureshadertile.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698