aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/gpu
diff options
context:
space:
mode:
authorGravatar bsalomon <bsalomon@google.com>2014-11-05 14:47:41 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2014-11-05 14:47:42 -0800
commit334355742137cc238887d4f85856e6c4d9ec8aa8 (patch)
treef9534c36e04abd374ff41973eedaee8e2dbe21ee /include/gpu
parentd5cd4ee5b81b51e43be7ed13f3c0f0f6c1b3fe14 (diff)
Add mock context and use in ResourceCacheTest.
Diffstat (limited to 'include/gpu')
-rw-r--r--include/gpu/GrContext.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/gpu/GrContext.h b/include/gpu/GrContext.h
index 464f36d123..2adc84211a 100644
--- a/include/gpu/GrContext.h
+++ b/include/gpu/GrContext.h
@@ -63,6 +63,11 @@ public:
*/
static GrContext* Create(GrBackend, GrBackendContext, const Options* opts = NULL);
+ /**
+ * Only defined in test apps.
+ */
+ static GrContext* CreateMockContext();
+
virtual ~GrContext();
/**
@@ -978,6 +983,8 @@ private:
GrContext(const Options&); // init must be called after the constructor.
bool init(GrBackend, GrBackendContext);
+ void initMockContext();
+ void initCommon();
void setupDrawBuffer();