Revert "De-GL-ify tests, gm and tools"
This reverts commit 89fb346d2bcefd3196aba01f66f1a74f040a5368.
Reason for revert: Google3 failure
Original change's description:
> De-GL-ify tests, gm and tools
>
> Change-Id: Id15a3a4b2c8b80b9dc7ecdab1cf1af1f9282f442
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/215447
> Reviewed-by: Jim Van Verth <jvanverth@google.com>
> Commit-Queue: Robert Phillips <robertphillips@google.com>
TBR=jvanverth@google.com,robertphillips@google.com
Change-Id: I155b033ac48d9fea15f66b22a090fb34f3bb81fa
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/215521
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
diff --git a/tools/gpu/GrContextFactory.cpp b/tools/gpu/GrContextFactory.cpp
index f7d2380..f5520d2 100644
--- a/tools/gpu/GrContextFactory.cpp
+++ b/tools/gpu/GrContextFactory.cpp
@@ -8,25 +8,20 @@
#include "src/gpu/GrContextPriv.h"
#include "tools/gpu/GrContextFactory.h"
-
-#ifdef SK_GL
#include "tools/gpu/gl/GLTestContext.h"
#if SK_ANGLE
#include "tools/gpu/gl/angle/GLTestContext_angle.h"
#endif
#include "tools/gpu/gl/command_buffer/GLTestContext_command_buffer.h"
-#endif
-
#ifdef SK_VULKAN
#include "tools/gpu/vk/VkTestContext.h"
#endif
-
#ifdef SK_METAL
#include "tools/gpu/mtl/MtlTestContext.h"
#endif
-
#include "src/gpu/GrCaps.h"
+#include "src/gpu/gl/GrGLGpu.h"
#include "tools/gpu/mock/MockTestContext.h"
#if defined(SK_BUILD_FOR_WIN) && defined(SK_ENABLE_DISCRETE_GPU)
@@ -154,7 +149,6 @@
std::unique_ptr<TestContext> testCtx;
GrBackendApi backend = ContextTypeBackend(type);
switch (backend) {
-#ifdef SK_GL
case GrBackendApi::kOpenGL: {
GLTestContext* glShareContext = masterContext
? static_cast<GLTestContext*>(masterContext->fTestContext) : nullptr;
@@ -202,7 +196,6 @@
testCtx.reset(glCtx);
break;
}
-#endif
#ifdef SK_VULKAN
case GrBackendApi::kVulkan: {
VkTestContext* vkSharedContext = masterContext
@@ -216,7 +209,6 @@
return ContextInfo();
}
-#ifdef SK_GL
// There is some bug (either in Skia or the NV Vulkan driver) where VkDevice
// destruction will hang occaisonally. For some reason having an existing GL
// context fixes this.
@@ -226,7 +218,6 @@
fSentinelGLContext.reset(CreatePlatformGLTestContext(kGLES_GrGLStandard));
}
}
-#endif
break;
}
#endif