From e909fdbf8c4dc1bd082ccb7fc50a7c4b52bdb647 Mon Sep 17 00:00:00 2001 From: Spoike Date: Sun, 30 Jan 2011 12:30:15 +0000 Subject: [PATCH] Workaround for wine. git-svn-id: https://svn.code.sf.net/p/fteqw/code/branches/wip@3732 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/gl/gl_vidcommon.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/engine/gl/gl_vidcommon.c b/engine/gl/gl_vidcommon.c index 6132f32d6..ec5ea51e9 100644 --- a/engine/gl/gl_vidcommon.c +++ b/engine/gl/gl_vidcommon.c @@ -975,10 +975,11 @@ void GL_Init(void *(*getglfunction) (char *name)) s++; gl_minor_version = atoi(s); } - qglGetIntegerv(GL_NUM_EXTENSIONS, &gl_num_extensions); - if (!qglGetError() && gl_num_extensions) + /*gl3 adds glGetStringi instead, as core, with the old form require GL_ARB_compatibility*/ + if (gl_major_version >= 3 && qglGetStringi) /*warning: wine fails to export qglGetStringi*/ { int i; + qglGetIntegerv(GL_NUM_EXTENSIONS, &gl_num_extensions); if (developer.value) { Con_Printf ("GL_EXTENSIONS:\n");