I’m using GLX and want to render accelerated 3D in one part of an X window, and draw 2D
using Xlib independently in the other part.
I’ve tried to restrict 3D rendering using
glViewPort with an area smaller than the window. The actual rendering is then confined
into this smaller area, but glClear/glXSwapBuffers() still clear the
whole window… Why?
I’d be very grateful for any suggestions how
to make this work…
I haven’t yet tried glScissors, but in case someone wants to know, I just figured out another way to fix it. Just create a subwindow inside the main window (with the
main window as parent) and attach glX to the subwindow. Works just fine and there’s no way to tell there’s actually two separate
windows.