diff options
author | Jeremy Huddleston <jeremyhu@apple.com> | 2011-06-15 00:27:55 -0700 |
---|---|---|
committer | Jeremy Huddleston <jeremyhu@apple.com> | 2011-06-20 16:54:58 -0700 |
commit | 559e4f8ebcb186b491d7d687ac43f22a62448fc1 (patch) | |
tree | 5bf792e38573f8d1a54d1c70c1c3427f692533e8 /src/glx/glxcmds.c | |
parent | fbd7448977efd49afba322cbb0853e9981ec2d2d (diff) | |
download | external_mesa3d-559e4f8ebcb186b491d7d687ac43f22a62448fc1.zip external_mesa3d-559e4f8ebcb186b491d7d687ac43f22a62448fc1.tar.gz external_mesa3d-559e4f8ebcb186b491d7d687ac43f22a62448fc1.tar.bz2 |
glx: Allow a context-specific fallback for glXGetProcAddress
In applegl, GLX advertises the same extensions provided by OpenGL.framework
even if such extensions are not provided by glapi. This allows a client
to get access to such API.
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
Diffstat (limited to 'src/glx/glxcmds.c')
-rw-r--r-- | src/glx/glxcmds.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/glx/glxcmds.c b/src/glx/glxcmds.c index cd8bc97..e6816ea 100644 --- a/src/glx/glxcmds.c +++ b/src/glx/glxcmds.c @@ -2521,6 +2521,12 @@ _X_EXPORT void (*glXGetProcAddressARB(const GLubyte * procName)) (void) #endif if (!f) f = (gl_function) _glapi_get_proc_address((const char *) procName); + if (!f) { + struct glx_context *gc = __glXGetCurrentContext(); + + if (gc != NULL && gc->vtable->get_proc_address != NULL) + f = gc->vtable->get_proc_address((const char *) procName); + } } return f; } |