aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrResourceCache.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gpu/GrResourceCache.h')
-rw-r--r--src/gpu/GrResourceCache.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gpu/GrResourceCache.h b/src/gpu/GrResourceCache.h
index 3e5df38d77..8331bf5d16 100644
--- a/src/gpu/GrResourceCache.h
+++ b/src/gpu/GrResourceCache.h
@@ -171,6 +171,9 @@ public:
void dumpStats(SkString*) const;
#endif
+ // This function is for unit testing and is only defined in test tools.
+ void changeTimestamp(uint32_t newTimestamp);
+
private:
///////////////////////////////////////////////////////////////////////////
/// @name Methods accessible via ResourceAccess
@@ -192,6 +195,8 @@ private:
void removeFromNonpurgeableArray(GrGpuResource*);
bool overBudget() const { return fBudgetedBytes > fMaxBytes || fBudgetedCount > fMaxCount; }
+ uint32_t getNextTimestamp();
+
#ifdef SK_DEBUG
bool isInCache(const GrGpuResource* r) const;
void validate() const;