aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools
diff options
context:
space:
mode:
authorGravatar Brian Salomon <bsalomon@google.com>2018-03-23 16:10:36 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-03-23 21:12:50 +0000
commit032aaae5be51e92ec9677d6c511241b19a7cb70d (patch)
tree8fe817c2a16ff23bcb18dfda5a70cec1cc9524de /tools
parenta6a3df7d64dc81082619ab103450fc6d0af7c644 (diff)
Remove legacy GrContext factories function and supporting code/types.
Change-Id: I437a4a0a58bf70ea1b8b0659b099a2af2bfa64fe Reviewed-on: https://skia-review.googlesource.com/116197 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Greg Daniel <egdaniel@google.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/gpu/TestContext.h1
-rw-r--r--tools/gpu/gl/GLTestContext.h3
-rw-r--r--tools/gpu/mock/MockTestContext.cpp4
-rw-r--r--tools/gpu/mtl/MtlTestContext.mm2
-rw-r--r--tools/gpu/vk/VkTestContext.h3
-rw-r--r--tools/sk_app/GLWindowContext.h4
-rw-r--r--tools/sk_app/RasterWindowContext.h3
-rw-r--r--tools/sk_app/VulkanWindowContext.h4
-rw-r--r--tools/sk_app/WindowContext.h1
9 files changed, 1 insertions, 24 deletions
diff --git a/tools/gpu/TestContext.h b/tools/gpu/TestContext.h
index 5b512db7ba..2949cc709e 100644
--- a/tools/gpu/TestContext.h
+++ b/tools/gpu/TestContext.h
@@ -59,7 +59,6 @@ public:
SkScopeExit SK_WARN_UNUSED_RESULT makeCurrentAndAutoRestore() const;
virtual GrBackend backend() = 0;
- virtual GrBackendContext backendContext() = 0;
virtual sk_sp<GrContext> makeGrContext(const GrContextOptions&);
diff --git a/tools/gpu/gl/GLTestContext.h b/tools/gpu/gl/GLTestContext.h
index cea630ac49..f5a05932a2 100644
--- a/tools/gpu/gl/GLTestContext.h
+++ b/tools/gpu/gl/GLTestContext.h
@@ -21,9 +21,6 @@ public:
~GLTestContext() override;
virtual GrBackend backend() override { return kOpenGL_GrBackend; }
- virtual GrBackendContext backendContext() override {
- return reinterpret_cast<GrBackendContext>(fGL.get());
- }
bool isValid() const { return SkToBool(this->gl()); }
diff --git a/tools/gpu/mock/MockTestContext.cpp b/tools/gpu/mock/MockTestContext.cpp
index 5cc5529dfe..6075bc83c2 100644
--- a/tools/gpu/mock/MockTestContext.cpp
+++ b/tools/gpu/mock/MockTestContext.cpp
@@ -20,9 +20,7 @@ public:
~MockTestContext() override {}
virtual GrBackend backend() override { return kMock_GrBackend; }
- virtual GrBackendContext backendContext() override {
- return reinterpret_cast<GrBackendContext>(nullptr);
- }
+
void testAbandon() override {}
void submit() override {}
void finish() override {}
diff --git a/tools/gpu/mtl/MtlTestContext.mm b/tools/gpu/mtl/MtlTestContext.mm
index 38755b2ef0..cdc0f8f168 100644
--- a/tools/gpu/mtl/MtlTestContext.mm
+++ b/tools/gpu/mtl/MtlTestContext.mm
@@ -122,8 +122,6 @@ public:
GrBackend backend() override { return kMetal_GrBackend; }
- GrBackendContext backendContext() override { return 0; }
-
void testAbandon() override {}
// There is really nothing to here since we don't own any unqueued command buffers here.
diff --git a/tools/gpu/vk/VkTestContext.h b/tools/gpu/vk/VkTestContext.h
index 5090f556b4..9fd4170d9d 100644
--- a/tools/gpu/vk/VkTestContext.h
+++ b/tools/gpu/vk/VkTestContext.h
@@ -18,9 +18,6 @@ namespace sk_gpu_test {
class VkTestContext : public TestContext {
public:
virtual GrBackend backend() override { return kVulkan_GrBackend; }
- virtual GrBackendContext backendContext() override {
- return reinterpret_cast<GrBackendContext>(fVk.get());
- }
sk_sp<const GrVkBackendContext> getVkBackendContext() {
return fVk;
diff --git a/tools/sk_app/GLWindowContext.h b/tools/sk_app/GLWindowContext.h
index 44810c93d2..68fd1eb709 100644
--- a/tools/sk_app/GLWindowContext.h
+++ b/tools/sk_app/GLWindowContext.h
@@ -31,10 +31,6 @@ public:
void setDisplayParams(const DisplayParams& params) override;
- GrBackendContext getBackendContext() override {
- return (GrBackendContext) fBackendContext.get();
- }
-
protected:
GLWindowContext(const DisplayParams&);
// This should be called by subclass constructor. It is also called when window/display
diff --git a/tools/sk_app/RasterWindowContext.h b/tools/sk_app/RasterWindowContext.h
index 75bde03ad7..db8600acd5 100644
--- a/tools/sk_app/RasterWindowContext.h
+++ b/tools/sk_app/RasterWindowContext.h
@@ -16,9 +16,6 @@ class RasterWindowContext : public WindowContext {
public:
RasterWindowContext(const DisplayParams& params) : WindowContext(params) {}
- // Explicitly convert nullptr to GrBackendContext is needed for compiling
- GrBackendContext getBackendContext() override { return (GrBackendContext) nullptr; }
-
protected:
bool isGpuContext() override { return false; }
};
diff --git a/tools/sk_app/VulkanWindowContext.h b/tools/sk_app/VulkanWindowContext.h
index df6ef33959..1fca9dc83e 100644
--- a/tools/sk_app/VulkanWindowContext.h
+++ b/tools/sk_app/VulkanWindowContext.h
@@ -38,10 +38,6 @@ public:
this->initializeContext();
}
- GrBackendContext getBackendContext() override {
- return (GrBackendContext) fBackendContext.get();
- }
-
/** Platform specific function that creates a VkSurfaceKHR for a window */
using CreateVkSurfaceFn = std::function<VkSurfaceKHR(VkInstance)>;
/** Platform specific function that determines whether presentation will succeed. */
diff --git a/tools/sk_app/WindowContext.h b/tools/sk_app/WindowContext.h
index 71c21ac089..9a12f2c04b 100644
--- a/tools/sk_app/WindowContext.h
+++ b/tools/sk_app/WindowContext.h
@@ -45,7 +45,6 @@ public:
fSurfaceProps = props;
}
- virtual GrBackendContext getBackendContext() = 0;
GrContext* getGrContext() const { return fContext.get(); }
int width() const { return fWidth; }