diff --git a/include/gpu/gl/GrGLInterface.h b/include/gpu/gl/GrGLInterface.h index af3ca67dcc..14d2521d12 100644 --- a/include/gpu/gl/GrGLInterface.h +++ b/include/gpu/gl/GrGLInterface.h @@ -85,7 +85,9 @@ public: GrGLExtensions fExtensions; +#ifdef SK_GL bool hasExtension(const char ext[]) const { return fExtensions.has(ext); } +#endif /** * The function pointers are in a struct so that we can have a compiler generated assignment diff --git a/src/gpu/gl/GrGLContext.h b/src/gpu/gl/GrGLContext.h index 93bd57c2c5..487774d7d5 100644 --- a/src/gpu/gl/GrGLContext.h +++ b/src/gpu/gl/GrGLContext.h @@ -45,9 +45,11 @@ public: const GrGLCaps* caps() const { return fGLCaps.get(); } GrGLCaps* caps() { return fGLCaps.get(); } +#ifdef SK_GL bool hasExtension(const char* ext) const { return fInterface->hasExtension(ext); } +#endif const GrGLExtensions& extensions() const { return fInterface->fExtensions; } diff --git a/src/gpu/gl/GrGLGpu.h b/src/gpu/gl/GrGLGpu.h index 50affac85e..f0f28046a9 100644 --- a/src/gpu/gl/GrGLGpu.h +++ b/src/gpu/gl/GrGLGpu.h @@ -277,6 +277,7 @@ private: // compatible stencil format, or negative if there is no compatible stencil format. int getCompatibleStencilIndex(GrGLFormat format); +#ifdef SK_GL GrBackendFormat getPreferredStencilFormat(const GrBackendFormat& format) override { int idx = this->getCompatibleStencilIndex(format.asGLFormat()); if (idx < 0) { @@ -285,6 +286,7 @@ private: return GrBackendFormat::MakeGL(GrGLFormatToEnum(this->glCaps().stencilFormats()[idx]), GR_GL_TEXTURE_NONE); } +#endif void onFBOChanged();