PDA

View Full Version : Opening 2 Glut Windows in separate threads



amoskoh
03-19-2005, 11:16 AM
I am experimenting with threads and GLUT. It worked when I opened a single thread that does the init and glutmainloop.

However, I tried adding a second thread with the same function to pthread_create.

I got this error when trying to run it

GLUT: Fatal Error in (unamed): visual with necessary capabilities not found.

I googled it up and the tips I got was to increase the Depth (bits per pixel) in Xlib?

marcus256
04-14-2005, 04:32 AM
I may be wrong, but I believe that GLUT does not support multiple threads (i.e. the GLUT context is not thread safe). At least it's worth checking if you haven't already.