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

Unified Diff: gm/dftext.cpp

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 | « gm/complexclip_blur_tiled.cpp ('k') | gm/displacement.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/dftext.cpp
diff --git a/gm/dftext.cpp b/gm/dftext.cpp
index cccca3863d5938049078944796be4e32eb973ea1..545911c26c065c493f948b41cc31521a6807a439 100644
--- a/gm/dftext.cpp
+++ b/gm/dftext.cpp
@@ -201,9 +201,7 @@ protected:
SkAutoCanvasRestore acr(inputCanvas, true);
// since we prepended this matrix already, we blit using identity
inputCanvas->resetMatrix();
- SkImage* image = surface->newImageSnapshot();
- inputCanvas->drawImage(image, 0, 0, nullptr);
- image->unref();
+ inputCanvas->drawImage(surface->makeImageSnapshot().get(), 0, 0, nullptr);
}
#endif
}
« no previous file with comments | « gm/complexclip_blur_tiled.cpp ('k') | gm/displacement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698