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

Unified Diff: bench/SKPBench.cpp

Issue 1034273002: Add matrix constructing helpers to SkMatrix (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 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 | « bench/PathBench.cpp ('k') | gm/aarectmodes.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bench/SKPBench.cpp
diff --git a/bench/SKPBench.cpp b/bench/SKPBench.cpp
index 3f521799fa0d27af6e8f7a174137e1904df37e5d..6f74ff942d8aefbb7fbc86477e726b65abe9056f 100644
--- a/bench/SKPBench.cpp
+++ b/bench/SKPBench.cpp
@@ -116,9 +116,8 @@ void SKPBench::onDraw(const int loops, SkCanvas* canvas) {
} else {
for (int i = 0; i < loops; i++) {
for (int j = 0; j < fTileRects.count(); ++j) {
- SkMatrix trans;
- trans.setTranslate(-fTileRects[j].fLeft / fScale,
- -fTileRects[j].fTop / fScale);
+ const SkMatrix trans = SkMatrix::MakeTrans(-fTileRects[j].fLeft / fScale,
+ -fTileRects[j].fTop / fScale);
fSurfaces[j]->getCanvas()->drawPicture(fPic, &trans, NULL);
}
« no previous file with comments | « bench/PathBench.cpp ('k') | gm/aarectmodes.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698