diff options
Diffstat (limited to 'src/opengl/qglextensions.cpp')
-rw-r--r-- | src/opengl/qglextensions.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/opengl/qglextensions.cpp b/src/opengl/qglextensions.cpp index 8e2bbd4..6aec8ae 100644 --- a/src/opengl/qglextensions.cpp +++ b/src/opengl/qglextensions.cpp @@ -255,6 +255,10 @@ bool qt_resolve_glsl_extensions(QGLContext *ctx) glFramebufferTextureLayerEXT = (_glFramebufferTextureLayerEXT) ctx->getProcAddress(QLatin1String("glFramebufferTextureLayerEXT")); glFramebufferTextureFaceEXT = (_glFramebufferTextureFaceEXT) ctx->getProcAddress(QLatin1String("glFramebufferTextureFaceEXT")); + // Must at least have the FragmentShader extension to continue. + if (!(QGLExtensions::glExtensions() & QGLExtensions::FragmentShader)) + return false; + glCreateShader = (_glCreateShader) ctx->getProcAddress(QLatin1String("glCreateShader")); if (glCreateShader) { glShaderSource = (_glShaderSource) ctx->getProcAddress(QLatin1String("glShaderSource")); |