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

Unified Diff: include/core/SkGraphics.h

Issue 1722603002: add SkGraphics::PurageAllCaches (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 10 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 | « no previous file | src/core/SkGraphics.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkGraphics.h
diff --git a/include/core/SkGraphics.h b/include/core/SkGraphics.h
index 5aecc7acd00f029ffd85fd2035fae98fd63152c7..d5a730d9e0fc88103656ef64ce47fe5f2712cce4 100644
--- a/include/core/SkGraphics.h
+++ b/include/core/SkGraphics.h
@@ -120,6 +120,14 @@ public:
static void DumpMemoryStatistics(SkTraceMemoryDump* dump);
/**
+ * Free as much globally cached memory as possible. This will purge all private caches in Skia,
+ * including font and image caches.
+ *
+ * If there are caches associated with GPU context, those will not be affected by this call.
+ */
+ static void PurgeAllCaches();
+
+ /**
* Applications with command line options may pass optional state, such
* as cache sizes, here, for instance:
* font-cache-limit=12345678
« no previous file with comments | « no previous file | src/core/SkGraphics.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698