cogl: Don't bother checking for NPOTs or VBOs on later GLs
For VBOs, we don't need to check for the extension if the GL version is greater than 1.5. Non-power-of-two textures are given in 2.0. We could also assume shader support in GL 2.0 except that the function names are different from those in the extension so it wouldn't work well with the current mechanism.
This commit is contained in:
parent
058d79dce2
commit
2a53b84d18
@ -100,6 +100,8 @@ COGL_FEATURE_FUNCTION (void, glRenderbufferStorageMultisample,
|
||||
GLsizei height))
|
||||
COGL_FEATURE_END ()
|
||||
|
||||
/* The function names in OpenGL 2.0 are different so we can't easily
|
||||
just check for GL 2.0 */
|
||||
COGL_FEATURE_BEGIN (shaders_glsl, 255, 255,
|
||||
"ARB\0",
|
||||
"shader_objects\0"
|
||||
@ -237,7 +239,7 @@ COGL_FEATURE_FUNCTION (void, glUniformMatrix4fv,
|
||||
|
||||
COGL_FEATURE_END ()
|
||||
|
||||
COGL_FEATURE_BEGIN (vbos, 255, 255,
|
||||
COGL_FEATURE_BEGIN (vbos, 1, 5,
|
||||
"ARB\0",
|
||||
"vertex_buffer_object\0",
|
||||
COGL_FEATURE_VBOS)
|
||||
|
@ -213,7 +213,8 @@ _cogl_features_init (void)
|
||||
|
||||
gl_extensions = (const gchar*) glGetString (GL_EXTENSIONS);
|
||||
|
||||
if (cogl_check_extension ("GL_ARB_texture_non_power_of_two", gl_extensions))
|
||||
if (COGL_CHECK_GL_VERSION (gl_major, gl_minor, 2, 0) ||
|
||||
cogl_check_extension ("GL_ARB_texture_non_power_of_two", gl_extensions))
|
||||
{
|
||||
#ifdef HAVE_CLUTTER_OSX
|
||||
if (really_enable_npot ())
|
||||
|
Loading…
Reference in New Issue
Block a user