aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/gpu
diff options
context:
space:
mode:
authorGravatar Robert Phillips <robertphillips@google.com>2017-06-14 01:43:29 +0000
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-06-14 01:43:38 +0000
commitfcd5fddb0264d062a461435618ad54a29ff80fc0 (patch)
tree3fdf24eff4b5aac832b4aec30ffd1754bbcc7263 /tools/gpu
parent9647637f780d61535ac4daa1ff681d2a71b9620d (diff)
Revert "Revert "Update skia to use ifdefs for Vulkan code instead of dummy header""
This reverts commit fad9e3f54112ea8c8bb6bb72384f47b9759578f5. Reason for revert: Can't find the error message anymore (?!?) Let's try again shall we Original change's description: > Revert "Update skia to use ifdefs for Vulkan code instead of dummy header" > > This reverts commit c0f8e426c59eec6c720b8e1329dcb966cf1b6800. > > Reason for revert: Experiment to see if this will unblock the Android roll > > Original change's description: > > Update skia to use ifdefs for Vulkan code instead of dummy header > > > > Bug: skia:6721 > > Change-Id: I80a4c9f2acc09c174497f625c50ed12a8bb76505 > > Reviewed-on: https://skia-review.googlesource.com/19547 > > Reviewed-by: Mike Klein <mtklein@google.com> > > Commit-Queue: Greg Daniel <egdaniel@google.com> > > TBR=egdaniel@google.com,mtklein@google.com,bsalomon@google.com > > Change-Id: Ib51c1672570f2071a17b6fbde692a5174b0358ce > No-Presubmit: true > No-Tree-Checks: true > No-Try: true > Bug: skia:6721 > Reviewed-on: https://skia-review.googlesource.com/19724 > Reviewed-by: Robert Phillips <robertphillips@google.com> > Commit-Queue: Robert Phillips <robertphillips@google.com> TBR=egdaniel@google.com,mtklein@google.com,bsalomon@google.com,robertphillips@google.com Change-Id: Iecef7ddcfe31d82938336120a4193525ac6693be No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: skia:6721 Reviewed-on: https://skia-review.googlesource.com/19782 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'tools/gpu')
-rw-r--r--tools/gpu/GrTest.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/tools/gpu/GrTest.cpp b/tools/gpu/GrTest.cpp
index 5a9fc9690e..f486993bbc 100644
--- a/tools/gpu/GrTest.cpp
+++ b/tools/gpu/GrTest.cpp
@@ -61,14 +61,15 @@ void SetupAlwaysEvictAtlas(GrContext* context) {
GrBackendTexture CreateBackendTexture(GrBackend backend, int width, int height,
GrPixelConfig config, GrBackendObject handle) {
- if (kOpenGL_GrBackend == backend) {
- GrGLTextureInfo* glInfo = (GrGLTextureInfo*)(handle);
- return GrBackendTexture(width, height, config, *glInfo);
- } else {
- SkASSERT(kVulkan_GrBackend == backend);
+#if SK_VULKAN
+ if (kVulkan_GrBackend == backend) {
GrVkImageInfo* vkInfo = (GrVkImageInfo*)(handle);
return GrBackendTexture(width, height, *vkInfo);
}
+#endif
+ SkASSERT(kOpenGL_GrBackend == backend);
+ GrGLTextureInfo* glInfo = (GrGLTextureInfo*)(handle);
+ return GrBackendTexture(width, height, config, *glInfo);
}
};