tags:

views:

25

answers:

1

Hi,

I am looking at the NeHe OpenGL tutorials (nehe.gamedev.net), which as almost every example also for Linux/glx.

But how can open several windows and draw into all of them? Thanks!

A: 

Creating more than one window is easy, just repeat the procedure. If you want to draw the same scene to different windows, you can draw the scene using multiple render targets. Google knows lots of tutorials for that.

If you want to draw different things into different windows, you can either use multiple OpenGL instances in separate threads/processes or use so-called swap-chains in Direct3D. I don't know exactly how to translate them into OpenGL. You can share a single OpenGL device between multiple rendering threads using makeCurrent(). Sharing common resources is not trivial though.

Hey,When googling for render targets and opengl, I only find entries explaining how to render to a texture.I want to open several windows and draw a different view of a scene into them. So they need to share textures.
Nathan
I found a mini-tutorial here:http://www.cs.uml.edu/~hmasterm/Charts/Managing_Multiple_Windows.ppt
thanks, but I do not want to use glut
Nathan