
GLX extension support is not checked correctly
Posted Thursday, 9 August, 2012 - 21:10 by benjamin| Project: | The Open Toolkit library |
| Version: | 1.x-dev |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | open |
OpenTK assumes that if glXGetProcAddress returns non-NULL for a function, the extension which defines it can be used. When the client implements an extension but the server does not, such as is currently the case with GLX_ARB_create_context on Intel Ivy Bridge and Sandy Bridge with current drivers on Linux, glXGetProcAddress will return non-NULL for functions defined by an extension which cannot be used, which can result in the process being killed if it attempts to call the resulting delegate. OpenTK calls one such function, glXCreateContextAttribs, in creating an OpenGL 3.0+ context, causing processes requesting such to be killed on systems as described above.
The correct way to check for GLX extension support is by inspecting the return value of glXQueryExtensionsString, which takes the union of server-supported and client-supported GLX extensions.

