diff options
| author | 2010-09-08 18:04:33 -0700 | |
|---|---|---|
| committer | 2010-09-08 18:04:33 -0700 | |
| commit | a2341a9f6addcd79723965ec5b1a1c5ae0f8bd65 (patch) | |
| tree | ce61e01a0719f9fc52e48be002fe1d57d3af9c68 /libs/hwui/PathCache.h | |
| parent | 9aaa8269a3e7291aab84d01c3fc9c744d8f2d2f4 (diff) | |
Purge Skia objects from GL caches as needed.
Change-Id: I754c671cf790ad5ae8bf047ad328034217da4ecc
Diffstat (limited to 'libs/hwui/PathCache.h')
| -rw-r--r-- | libs/hwui/PathCache.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libs/hwui/PathCache.h b/libs/hwui/PathCache.h index 522e5e0f65ad..bde0e7d845e9 100644 --- a/libs/hwui/PathCache.h +++ b/libs/hwui/PathCache.h @@ -114,6 +114,10 @@ public: * Clears the cache. This causes all textures to be deleted. */ void clear(); + /** + * Removes an entry. + */ + void remove(SkPath* path); /** * Sets the maximum size of the cache in bytes. @@ -143,6 +147,12 @@ private: uint32_t mSize; uint32_t mMaxSize; GLuint mMaxTextureSize; + + /** + * Used to access mCache and mSize. All methods are accessed from a single + * thread except for remove(). + */ + mutable Mutex mLock; }; // class PathCache }; // namespace uirenderer |