aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools
diff options
context:
space:
mode:
authorGravatar Kevin Lubick <kjlubick@google.com>2017-05-24 15:30:35 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-05-24 20:30:05 +0000
commitffce079f4e0ca4ccb7f24aa647eee1de5feb6e02 (patch)
treecd5290fcc657d362dc491b4d28aafc94847dba18 /tools
parent56a1e6a1095567809cfb45f450dfbe104cad5aaf (diff)
Enable chromecast gpu perf
The new #ifndef account for what the chromecast sdk cannot handle (e.g. posix). Bug: skia:6581 Change-Id: I3d64d25980d80185f8b95c05badee5f665d97cd3 Reviewed-on: https://skia-review.googlesource.com/13811 Reviewed-by: Ethan Nicholas <ethannicholas@google.com> Commit-Queue: Kevin Lubick <kjlubick@google.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/gpu/GrContextFactory.cpp2
-rw-r--r--tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp3
-rw-r--r--tools/gpu/gl/egl/CreatePlatformGLTestContext_egl.cpp4
3 files changed, 9 insertions, 0 deletions
diff --git a/tools/gpu/GrContextFactory.cpp b/tools/gpu/GrContextFactory.cpp
index 5aa57853b5..0238898d71 100644
--- a/tools/gpu/GrContextFactory.cpp
+++ b/tools/gpu/GrContextFactory.cpp
@@ -162,9 +162,11 @@ ContextInfo GrContextFactory::getContextInfoInternal(ContextType type, ContextOv
glShareContext).release();
break;
#endif
+#ifndef SK_NO_COMMAND_BUFFER
case kCommandBuffer_ContextType:
glCtx = CommandBufferGLTestContext::Create(glShareContext);
break;
+#endif
#if SK_MESA
case kMESA_ContextType:
glCtx = CreateMesaGLTestContext(glShareContext);
diff --git a/tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp b/tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp
index 82888d8984..54845fc28b 100644
--- a/tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp
+++ b/tools/gpu/gl/command_buffer/GLTestContext_command_buffer.cpp
@@ -6,6 +6,8 @@
* found in the LICENSE file.
*/
+#ifndef SK_NO_COMMAND_BUFFER
+
#include "SkMutex.h"
#include "SkOnce.h"
#include "gl/GrGLInterface.h"
@@ -302,3 +304,4 @@ int CommandBufferGLTestContext::getSampleCount() {
}
} // namespace sk_gpu_test
+#endif // SK_NO_COMMAND_BUFFER
diff --git a/tools/gpu/gl/egl/CreatePlatformGLTestContext_egl.cpp b/tools/gpu/gl/egl/CreatePlatformGLTestContext_egl.cpp
index e5939f4a79..c006098d2f 100644
--- a/tools/gpu/gl/egl/CreatePlatformGLTestContext_egl.cpp
+++ b/tools/gpu/gl/egl/CreatePlatformGLTestContext_egl.cpp
@@ -237,6 +237,7 @@ GrGLuint EGLGLTestContext::eglImageToExternalTexture(GrEGLImage image) const {
if (!this->gl()->hasExtension("GL_OES_EGL_image_external")) {
return 0;
}
+#ifndef EGL_NO_IMAGE_EXTERNAL
typedef GrGLvoid (*EGLImageTargetTexture2DProc)(GrGLenum, GrGLeglImage);
EGLImageTargetTexture2DProc glEGLImageTargetTexture2D =
@@ -260,6 +261,9 @@ GrGLuint EGLGLTestContext::eglImageToExternalTexture(GrEGLImage image) const {
return 0;
}
return texID;
+#else
+ return 0;
+#endif //EGL_NO_IMAGE_EXTERNAL
}
std::unique_ptr<sk_gpu_test::GLTestContext> EGLGLTestContext::makeNew() const {