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

Unified Diff: gm/gm.cpp

Issue 1772463002: use Make instead of Create to return a shared shader (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
« no previous file with comments | « gm/bitmapshader.cpp ('k') | gm/lcdblendmodes.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/gm.cpp
diff --git a/gm/gm.cpp b/gm/gm.cpp
index dc882fd646d4772644416b7625cafac154614d05..ebdc4f183c3a6b36a7cbf3898a5d088801333d10 100644
--- a/gm/gm.cpp
+++ b/gm/gm.cpp
@@ -85,10 +85,9 @@ void GM::DrawGpuOnlyMessage(SkCanvas* canvas) {
SkMatrix localM;
localM.setRotate(35.f);
localM.postTranslate(10.f, 0.f);
- SkAutoTUnref<SkShader> shader(SkShader::CreateBitmapShader(bmp, SkShader::kMirror_TileMode,
- SkShader::kMirror_TileMode,
- &localM));
- paint.setShader(shader);
+ paint.setShader(SkShader::MakeBitmapShader(bmp, SkShader::kMirror_TileMode,
+ SkShader::kMirror_TileMode,
+ &localM));
paint.setFilterQuality(kMedium_SkFilterQuality);
canvas->drawPaint(paint);
return;
« no previous file with comments | « gm/bitmapshader.cpp ('k') | gm/lcdblendmodes.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698