aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/gpu/TestContext.cpp
diff options
context:
space:
mode:
authorGravatar Greg Daniel <egdaniel@google.com>2017-07-13 15:07:54 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-07-13 21:29:33 +0000
commitb76a72a659f53b8bf449c5ca2685045d08a21e43 (patch)
treecc2e1b3c997817f514438e79c248d3b890e65ef7 /tools/gpu/TestContext.cpp
parentee3e0bacc8bedd1e3ebfb52fbc8b1cc3ccdad358 (diff)
Add support for creating a GrContext backed by Metal.
Also adds the support code to allow our TestContext to create a Metal backend. Bug: skia: Change-Id: Ia850687019d79b897bb16e2c151f4f8526721ad9 Reviewed-on: https://skia-review.googlesource.com/22644 Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Greg Daniel <egdaniel@google.com>
Diffstat (limited to 'tools/gpu/TestContext.cpp')
-rw-r--r--tools/gpu/TestContext.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/gpu/TestContext.cpp b/tools/gpu/TestContext.cpp
index 90aba43880..c80c4ea4df 100644
--- a/tools/gpu/TestContext.cpp
+++ b/tools/gpu/TestContext.cpp
@@ -10,6 +10,8 @@
#include "GpuTimer.h"
+#include "GrContext.h"
+
namespace sk_gpu_test {
TestContext::TestContext()
: fFenceSync(nullptr)
@@ -29,6 +31,10 @@ TestContext::~TestContext() {
SkASSERT(!fGpuTimer);
}
+sk_sp<GrContext> TestContext::makeGrContext(const GrContextOptions&) {
+ return nullptr;
+}
+
void TestContext::makeCurrent() const { this->onPlatformMakeCurrent(); }
void TestContext::swapBuffers() { this->onPlatformSwapBuffers(); }