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

Unified Diff: gm/shadertext3.cpp

Issue 245963010: Move SkShader::fLocalMatrix into SkShader constructor. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: nit Created 6 years, 8 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/shadertext2.cpp ('k') | gm/xfermodes.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/shadertext3.cpp
diff --git a/gm/shadertext3.cpp b/gm/shadertext3.cpp
index a1c2d6006b505fd21a7e0884f451497ad13c8313..6ae3159b917739f3cf5247b7442c8ede9c7e110e 100644
--- a/gm/shadertext3.cpp
+++ b/gm/shadertext3.cpp
@@ -100,14 +100,15 @@ protected:
int i = 0;
for (size_t tm0 = 0; tm0 < SK_ARRAY_COUNT(kTileModes); ++tm0) {
for (size_t tm1 = 0; tm1 < SK_ARRAY_COUNT(kTileModes); ++tm1) {
- SkAutoTUnref<SkShader> shader(SkShader::CreateBitmapShader(fBmp,
- kTileModes[tm0],
- kTileModes[tm1]));
SkMatrix localM;
localM.setTranslate(5.f, 5.f);
localM.postRotate(20);
localM.postScale(1.15f, .85f);
- shader->setLocalMatrix(localM);
+
+ SkAutoTUnref<SkShader> shader(SkShader::CreateBitmapShader(fBmp,
+ kTileModes[tm0],
+ kTileModes[tm1],
+ &localM));
SkPaint fillPaint;
fillPaint.setAntiAlias(true);
« no previous file with comments | « gm/shadertext2.cpp ('k') | gm/xfermodes.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698