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

Unified Diff: samplecode/SampleFatBits.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 | « samplecode/SampleDash.cpp ('k') | samplecode/SampleHairModes.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samplecode/SampleFatBits.cpp
diff --git a/samplecode/SampleFatBits.cpp b/samplecode/SampleFatBits.cpp
index 6900fae3eb6583e9394fbae83a273d3e360566b7..9ea1d9e47999658fea77fd374453c4067bd73f70 100644
--- a/samplecode/SampleFatBits.cpp
+++ b/samplecode/SampleFatBits.cpp
@@ -43,13 +43,10 @@ static SkShader* createChecker() {
bm.lockPixels();
*bm.getAddr32(0, 0) = *bm.getAddr32(1, 1) = SkPreMultiplyColor(colors[0]);
*bm.getAddr32(0, 1) = *bm.getAddr32(1, 0) = SkPreMultiplyColor(colors[1]);
- SkShader* s = SkShader::CreateBitmapShader(bm, SkShader::kRepeat_TileMode,
- SkShader::kRepeat_TileMode);
-
SkMatrix m;
m.setScale(12, 12);
- s->setLocalMatrix(m);
- return s;
+ return SkShader::CreateBitmapShader(bm, SkShader::kRepeat_TileMode,
+ SkShader::kRepeat_TileMode, &m);
}
class FatBits {
« no previous file with comments | « samplecode/SampleDash.cpp ('k') | samplecode/SampleHairModes.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698