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

Unified Diff: include/gpu/GrCacheable.h

Issue 257093002: Add size change notifications to GrResourceCache (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: rebase Created 6 years, 7 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 | include/gpu/GrTexture.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/gpu/GrCacheable.h
diff --git a/include/gpu/GrCacheable.h b/include/gpu/GrCacheable.h
index 75dec16033f9b2b6dcf86938c54346ce4e7d51df..39c62b1b66c730ba130303c7bafb2b9733af7ce6 100644
--- a/include/gpu/GrCacheable.h
+++ b/include/gpu/GrCacheable.h
@@ -46,6 +46,14 @@ protected:
bool isInCache() const { return NULL != fCacheEntry; }
+ /**
+ * This entry point should be called whenever gpuMemorySize() begins
+ * reporting a different size. If the object is in the cache, it will call
+ * gpuMemorySize() immediately and pass the new size on to the resource
+ * cache.
+ */
+ void didChangeGpuMemorySize() const;
+
private:
GrResourceCacheEntry* fCacheEntry; // NULL if not in cache
« no previous file with comments | « no previous file | include/gpu/GrTexture.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698