I have written a small programme using GTK+ and
GtkGLExt. My programme was previously using
GtkDrawingArea but is now using GdkPixmap for GL
rendering. Since switching to GdkPixmap, running my
programme gives the following error:
myprompt> ./test_glext --sync
[*** I got as far as glXMakeCurrent ***]
The program 'test_glext' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadValue (integer parameter out of range
(Details: serial 266 error_code 2 request_code 128
(Note to programmers: normally, X errors are reported
that is, you will receive the error a while after
To debug your program, run it with the --sync
option to change this behavior. You can then get a
backtrace from your debugger if you break on the
I started breaking down my code to find exactly where
the crash occurs and tracked it down to the function
I downloaded the code for GtkGLExt to find where within
this function the crash occurs. I tracked it down to
glXMakeCurrent(xdisplay, glxpixmap, glxcontext)
I have attached the code which replicates the bug.
Could someone help me resolve this problem?