aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/gpu/GrTexture.h
diff options
context:
space:
mode:
authorGravatar robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-06-07 12:08:45 +0000
committerGravatar robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2012-06-07 12:08:45 +0000
commit75b3c9633cb9a594dab0ccf51dab1e694c149a18 (patch)
treeec4669cda6d54e286bf9b92f6495d733cfd58033 /include/gpu/GrTexture.h
parent93b4375fd4d87d3502d14d5e6a98383993b2600c (diff)
Move clientID into texture desc
Diffstat (limited to 'include/gpu/GrTexture.h')
-rw-r--r--include/gpu/GrTexture.h19
1 files changed, 11 insertions, 8 deletions
diff --git a/include/gpu/GrTexture.h b/include/gpu/GrTexture.h
index c3e2946f76..17d4e1e40d 100644
--- a/include/gpu/GrTexture.h
+++ b/include/gpu/GrTexture.h
@@ -17,17 +17,21 @@ class GrRenderTarget;
class GrResourceKey;
class GrSamplerState;
+/*
+ * All uncached textures should have this value as their fClientCacheID
+ */
+static const uint64_t kUncached_CacheID = 0xAAAAAAAA;
+
+/*
+ * Scratch textures should all have this value as their fClientCacheID
+ */
+static const uint64_t kScratch_CacheID = 0xBBBBBBBB;
+
+
class GrTexture : public GrResource {
public:
/**
- * Key generated by client. Should be a unique key on the texture data.
- * Does not need to consider that width and height of the texture. Two
- * textures with the same TextureKey but different bounds will not collide.
- */
- typedef uint64_t TextureKey;
-
- /**
* Retrieves the width of the texture.
*
* @return the width in texels
@@ -141,7 +145,6 @@ public:
static GrResourceKey ComputeKey(const GrGpu* gpu,
const GrSamplerState* sampler,
- TextureKey clientKey,
const GrTextureDesc& desc,
bool scratch);