Gussius's picture

BadWindow or GLXBadDrawable Exceptions on Exit

Project:The Open Toolkit library
Version:1.0-beta-3
Component:Miscellaneous
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

I am currently learning how to program in C# using the OpenTK library. My skills are rather elementary in C# but we have to start somewhere.
I am stepping through the examples in the Red Book except using OpenTK library calls instead. Everything is working well so far except I get a similar problem to a prevoius issue ...

http://www.opentk.com/node/1190

X Error of failed request: BadWindow (invalid Window parameter)
Major opcode of failed request: 25 (X_SendEvent)
Resource id in failed request: 0x5800002
Serial number of failed request: 68
Current serial number in output stream: 68

OR

X Error of failed request: GLXBadDrawable
Major opcode of failed request: 128 (GLX)
Minor opcode of failed request: 11 (X_GLXSwapBuffers)
Serial number of failed request: 69
Current serial number in output stream: 70

On exit the program stalls, monodevelop needs to be restarted if it was running debugging, otherwise the program needs to be ^C to stop in a console.

The code I am writing is to recreate the Sun and Planet example in the Red Book. I can't seem to pin it down. I think GL.Normal3(...) had something to do with the GLXBadDrawable error. But the BadWindow error seems to be intermittant once I comment out the offending lines which cause GLXBadDrawable.

I am using Linux Mint 8 (Ubuntu derivative) x86 with GeForce 8800 GTS (185.13.36), mono 2.4.3, monodevelop 2.0, OpenTK library 1.0 beta 2.

I can continue to program but this little problem is bugging me. I would like to know what is behind it.


Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
the Fiddler's picture

#1

OpenTK 1.0-beta-3 was just released, can you please test whether this issue is still reproducible? It contains a number of fixes that could be relevant.

the Fiddler's picture

#2

Status:open» need info
Gussius's picture

#3

Status:need info» closed

I can't reproduce this issue with OpenTK Library 1.0 - beta 3. So problem solved.
Looking at the change logs I'm guessing it had something to do with this change...

* Source/OpenTK/GameWindow.cs,
Source/OpenTK/Platform/X11/X11GLContext.cs,
Source/OpenTK/Platform/X11/X11GLNative.cs: Do not call Dispose()
automatically on GameWindow.Close(). Ensure that Unload event is
raised before window destruction, Ensure that Render and
UpdateFrame events are not called once the shutdown sequence is
initiated.

Thanks for your time.

the Fiddler's picture

#4

Version:1.0-beta-2» 1.0-beta-3

Thanks for confirming!

Who's online

There are currently 0 users and 14 guests online.