GLBuffer: fix isVBOSupported()

This commit is contained in:
Zheng, Lei
2018-08-29 12:39:45 +08:00
committed by wmayer
parent 864ca1e470
commit 3f0c474a71
3 changed files with 6 additions and 3 deletions

View File

@@ -71,8 +71,11 @@ OpenGLBuffer::~OpenGLBuffer()
* When calling this function there must be a current OpenGL context.
* \return
*/
bool OpenGLBuffer::isVBOSupported()
bool OpenGLBuffer::isVBOSupported(uint32_t ctx)
{
auto glue = cc_glglue_instance(ctx);
if (!glue || !cc_glglue_has_vertex_buffer_object(glue))
return false;
const GLubyte * str = glGetString(GL_EXTENSIONS);
if (!str)
return false;