aboutsummaryrefslogtreecommitdiffhomepage
path: root/bench/nanobench.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'bench/nanobench.cpp')
-rw-r--r--bench/nanobench.cpp15
1 files changed, 10 insertions, 5 deletions
diff --git a/bench/nanobench.cpp b/bench/nanobench.cpp
index c097a4d14e..99bea4f60f 100644
--- a/bench/nanobench.cpp
+++ b/bench/nanobench.cpp
@@ -58,18 +58,22 @@ extern bool gSkForceRasterPipelineBlitter;
#ifndef SK_BUILD_FOR_WIN
#include <unistd.h>
+
#endif
#if SK_SUPPORT_GPU
- #include "gl/GrGLDefines.h"
#include "GrCaps.h"
- #include "GrContextPriv.h"
#include "GrContextFactory.h"
- #include "gl/GrGLUtil.h"
+ #include "GrContextPriv.h"
#include "SkGr.h"
+ #include "gl/GrGLDefines.h"
+ #include "gl/GrGLGpu.h"
+ #include "gl/GrGLUtil.h"
+
using sk_gpu_test::ContextInfo;
using sk_gpu_test::GrContextFactory;
using sk_gpu_test::TestContext;
+
GrContextOptions grContextOpts;
#endif
@@ -217,8 +221,9 @@ struct GPUTarget : public Target {
void fillOptions(ResultsWriter* log) override {
const GrGLubyte* version;
if (this->contextInfo.backend() == kOpenGL_GrBackend) {
- const GrGLInterface* gl = reinterpret_cast<const GrGLInterface*>(
- this->contextInfo.testContext()->backendContext());
+ const GrGLInterface* gl =
+ static_cast<GrGLGpu*>(this->contextInfo.grContext()->contextPriv().getGpu())
+ ->glInterface();
GR_GL_CALL_RET(gl, version, GetString(GR_GL_VERSION));
log->configOption("GL_VERSION", (const char*)(version));