There are two sequences of commands: the X stream, and the OpenGL stream. In general these two streams are independent: Although the commands in each stream will be processed in sequence, there is no guarantee that commands in the separate streams will be processed in the order in which they were issued by the calling thread.
An exception to this rule arises when a single command appears in both streams. This forces the two streams to rendezvous.
Because the processing of the two streams may take place at different rates, and some operations may depend on the results of commands in a different stream, we distinguish between commands assigned to each of the X and OpenGL streams.
The following commands are in the X stream and obey the sequentiality guarantees for X requests:
glXCreateContextglXDestroyContext
glXMakeCurrent
glXGetCurrentContext
glXGetCurrentDrawable
glXIsDirect
glXGetConfig
glXQueryVersion
glXWaitGL
glXCreateGLXPixmap
glXDestroyGLXPixmap
glXChooseVisual
glXSwapBuffers (but see below)
glXCopyContext (see below)
glXSwapBuffers is in the X stream if and only if the display and drawable are not those belonging to the calling thread's current context; otherwise it is in the OpenGL stream. glXCopyContext is in the X stream alone if and only if its source context differs from the calling thread's current context; otherwise it is in both streams.
Commands in the OpenGL stream, which obey the sequentiality guarantees for OpenGL requests:
glXWaitXglXSwapBuffers (see below)
All OpenGL Commands
glXSwapBuffers is in the OpenGL stream if and only if the display and drawable are those belonging to the calling thread's current context; otherwise it is in the X stream.
Commands in both streams, which force a rendezvous:
glXCopyContext (see below)glXUseXFont
glXCopyContext is in both streams if and only if the source context is the same as the current context of the calling thread; otherwise it is in the X stream only.