From 0feb63deb391ee035e1f89c2de8c6052836550d1 Mon Sep 17 00:00:00 2001 From: "Ryan C. Gordon" Date: Tue, 24 May 2011 04:38:48 -0400 Subject: [PATCH] Test for the GL extension, not whether the entry point is NULL. (glXGetProcAddress() can legally return a non-NULL pointer...you have to make sure it is safe to call yourself by checking the GL_EXTENSIONS string!) --- mojoshader_opengl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mojoshader_opengl.c b/mojoshader_opengl.c index e2d57f5e..d97bbbf2 100644 --- a/mojoshader_opengl.c +++ b/mojoshader_opengl.c @@ -689,7 +689,7 @@ static void impl_ARB1_PushUniforms(void) else if (type == MOJOSHADER_UNIFORM_INT) { int i; - if (ctx->glProgramLocalParameterI4ivNV != NULL) + if (ctx->have_GL_NV_gpu_program4) { // GL_NV_gpu_program4 has integer uniform loading support. for (i = 0; i < size; i++, srci += 4, loc++) @@ -710,7 +710,7 @@ static void impl_ARB1_PushUniforms(void) else if (type == MOJOSHADER_UNIFORM_BOOL) { int i; - if (ctx->glProgramLocalParameterI4ivNV != NULL) + if (ctx->have_GL_NV_gpu_program4) { // GL_NV_gpu_program4 has integer uniform loading support. for (i = 0; i < size; i++, srcb++, loc++)