diff options
Diffstat (limited to 'src/gpu/gl/GrGLInterface.cpp')
-rw-r--r-- | src/gpu/gl/GrGLInterface.cpp | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/gpu/gl/GrGLInterface.cpp b/src/gpu/gl/GrGLInterface.cpp index 84c51fb252..728fb3f9e5 100644 --- a/src/gpu/gl/GrGLInterface.cpp +++ b/src/gpu/gl/GrGLInterface.cpp @@ -424,6 +424,21 @@ bool GrGLInterface::validate() const { } if (kGL_GrGLStandard == fStandard) { + if (glVer >= GR_GL_VER(3,1)) { + if (nullptr == fFunctions.fTexBuffer) { + RETURN_FALSE_INTERFACE; + } + } + } else { + if (glVer >= GR_GL_VER(3,2) || fExtensions.has("GL_OES_texture_buffer") || + fExtensions.has("GL_EXT_texture_buffer")) { + if (nullptr == fFunctions.fTexBuffer) { + RETURN_FALSE_INTERFACE; + } + } + } + + if (kGL_GrGLStandard == fStandard) { if (glVer >= GR_GL_VER(3, 0) || fExtensions.has("GL_ARB_vertex_array_object")) { if (nullptr == fFunctions.fBindVertexArray || nullptr == fFunctions.fDeleteVertexArrays || @@ -746,6 +761,11 @@ bool GrGLInterface::validate() const { RETURN_FALSE_INTERFACE } } + if (glVer >= GR_GL_VER(3,1)) { + if (nullptr == fFunctions.fTextureBuffer) { + RETURN_FALSE_INTERFACE; + } + } } if ((kGL_GrGLStandard == fStandard && glVer >= GR_GL_VER(4,3)) || |