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

Unified Diff: src/gpu/GrResourceCache2.h

Issue 703303003: Add GrGpuResource::CacheAccess (Closed) Base URL: https://skia.googlesource.com/skia.git@nohash
Patch Set: fix warning Created 6 years, 1 month 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 | « src/gpu/GrResourceCache.cpp ('k') | src/gpu/GrResourceCache2.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrResourceCache2.h
diff --git a/src/gpu/GrResourceCache2.h b/src/gpu/GrResourceCache2.h
index ba07c20f011e009de700f27d205fef89dd4e86c4..1cc958799d44a538674cdb2573e368a8c058b8cd 100644
--- a/src/gpu/GrResourceCache2.h
+++ b/src/gpu/GrResourceCache2.h
@@ -10,6 +10,7 @@
#define GrResourceCache2_DEFINED
#include "GrGpuResource.h"
+#include "GrGpuResourceCacheAccess.h"
#include "GrResourceKey.h"
#include "SkRefCnt.h"
#include "SkTInternalLList.h"
@@ -74,7 +75,7 @@ private:
struct ScratchMapTraits {
static const GrResourceKey& GetKey(const GrGpuResource& r) {
- return r.getScratchKey();
+ return r.cacheAccess().getScratchKey();
}
static uint32_t Hash(const GrResourceKey& key) { return key.getHash(); }
@@ -83,7 +84,7 @@ private:
struct ContentHashTraits {
static const GrResourceKey& GetKey(const GrGpuResource& r) {
- return *r.getContentKey();
+ return *r.cacheAccess().getContentKey();
}
static uint32_t Hash(const GrResourceKey& key) { return key.getHash(); }
« no previous file with comments | « src/gpu/GrResourceCache.cpp ('k') | src/gpu/GrResourceCache2.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698