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

Unified Diff: tools/VisualBench/WrappedBenchmark.h

Issue 1810813003: update callsites for Make image factories (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: start to take advantage of sk_sp drawImage 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 | « tools/Resources.cpp ('k') | tools/debugger/SkDrawCommand.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/VisualBench/WrappedBenchmark.h
diff --git a/tools/VisualBench/WrappedBenchmark.h b/tools/VisualBench/WrappedBenchmark.h
index c947a3ed37edc0aed0db0dad8131af2ce858a7e8..35d64ee1827e1b0ceba33cca333ab1b2c82c2969 100644
--- a/tools/VisualBench/WrappedBenchmark.h
+++ b/tools/VisualBench/WrappedBenchmark.h
@@ -84,10 +84,10 @@ private:
}
void onBlitToScreen(SkCanvas* canvas, int w, int h) override {
- SkAutoTUnref<SkImage> image(fOffScreen->newImageSnapshot());
+ sk_sp<SkImage> image(fOffScreen->makeImageSnapshot());
SkPaint blitPaint;
blitPaint.setXfermodeMode(SkXfermode::kSrc_Mode);
- canvas->drawImageRect(image, SkIRect::MakeWH(w, h),
+ canvas->drawImageRect(image.get(), SkIRect::MakeWH(w, h),
SkRect::MakeWH(SkIntToScalar(w), SkIntToScalar(h)), &blitPaint);
}
« no previous file with comments | « tools/Resources.cpp ('k') | tools/debugger/SkDrawCommand.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698