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

Side by Side 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 unified diff | Download patch
« no previous file with comments | « no previous file | src/core/SkGraphics.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkGraphics_DEFINED 8 #ifndef SkGraphics_DEFINED
9 #define SkGraphics_DEFINED 9 #define SkGraphics_DEFINED
10 10
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 static size_t GetResourceCacheSingleAllocationByteLimit(); 113 static size_t GetResourceCacheSingleAllocationByteLimit();
114 static size_t SetResourceCacheSingleAllocationByteLimit(size_t newLimit); 114 static size_t SetResourceCacheSingleAllocationByteLimit(size_t newLimit);
115 115
116 /** 116 /**
117 * Dumps memory usage of caches using the SkTraceMemoryDump interface. See SkTraceMemoryDump 117 * Dumps memory usage of caches using the SkTraceMemoryDump interface. See SkTraceMemoryDump
118 * for usage of this method. 118 * for usage of this method.
119 */ 119 */
120 static void DumpMemoryStatistics(SkTraceMemoryDump* dump); 120 static void DumpMemoryStatistics(SkTraceMemoryDump* dump);
121 121
122 /** 122 /**
123 * Free as much globally cached memory as possible. This will purge all pri vate caches in Skia,
124 * including font and image caches.
125 *
126 * If there are caches associated with GPU context, those will not be affec ted by this call.
127 */
128 static void PurgeAllCaches();
129
130 /**
123 * Applications with command line options may pass optional state, such 131 * Applications with command line options may pass optional state, such
124 * as cache sizes, here, for instance: 132 * as cache sizes, here, for instance:
125 * font-cache-limit=12345678 133 * font-cache-limit=12345678
126 * 134 *
127 * The flags format is name=value[;name=value...] with no spaces. 135 * The flags format is name=value[;name=value...] with no spaces.
128 * This format is subject to change. 136 * This format is subject to change.
129 */ 137 */
130 static void SetFlags(const char* flags); 138 static void SetFlags(const char* flags);
131 139
132 /** 140 /**
(...skipping 30 matching lines...) Expand all
163 }; 171 };
164 172
165 class SkAutoGraphics { 173 class SkAutoGraphics {
166 public: 174 public:
167 SkAutoGraphics() { 175 SkAutoGraphics() {
168 SkGraphics::Init(); 176 SkGraphics::Init();
169 } 177 }
170 }; 178 };
171 179
172 #endif 180 #endif
OLDNEW
« 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