mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 23:32:09 +00:00
don't use glXGetProcAddressARB to look up the glX functions. hopefully fixes
the nvidea segfault
This commit is contained in:
parent
8ebef28b7a
commit
aa5ad0f0f9
1 changed files with 5 additions and 1 deletions
|
@ -90,6 +90,8 @@ Bool (* qfglXMakeCurrent) (Display *dpy, GLXDrawable drawable, GLXContext ctx);
|
|||
|
||||
// ============================================================================
|
||||
|
||||
static int use_gl_procaddress;
|
||||
|
||||
#if defined(HAVE_DLOPEN)
|
||||
|
||||
void * (* glGetProcAddress) (const char *symbol) = NULL;
|
||||
|
@ -99,7 +101,7 @@ QFGL_GetProcAddress (void *handle, const char *name)
|
|||
{
|
||||
void *glfunc = NULL;
|
||||
|
||||
if (glGetProcAddress)
|
||||
if (use_gl_procaddress && glGetProcAddress)
|
||||
glfunc = glGetProcAddress (name);
|
||||
if (!glfunc)
|
||||
glfunc = dlsym (handle, name);
|
||||
|
@ -191,6 +193,8 @@ VID_Init (unsigned char *palette)
|
|||
true);
|
||||
qfglXMakeCurrent = QFGL_ProcAddress (libgl_handle, "glXMakeCurrent", true);
|
||||
|
||||
use_gl_procaddress = 1;
|
||||
|
||||
Cmd_AddCommand ("vid_center", VID_Center_f, "Center the view port on the "
|
||||
"quake window in a virtual desktop.\n");
|
||||
|
||||
|
|
Loading…
Reference in a new issue