GLXDrawable dra )
PARAMETERS
dpy Specifies the connection to the X server.
dra Specifies a GLX drawable that to render into. Must be an XID rep‐
resenting a GLXWindow, GLXPixmap, or GLXPbuffer.
_param3
Specifies a GLX drawable that to read from. Must be an XID repre‐
senting a GLXWindow, GLXPixmap, or GLXPbuffer.
_param4
Specifies the GLX context to be bound to _param3 and _param4.
DESCRIPTION
glXMakeContextCurrent binds _param4 to the current rendering thread and
to the dra and _param3 GLX drawables. dra and _param3 may be the same.
dra is used for all OpenGL operations except:
Any pixel data that are read based on the value of GL_READ_BUFFER.
Note that accumulation operations use the value of GL_READ_BUFFER, but
are not allowed unless dra is identical to _param3.
Any depth values that are retrieved by glReadPixels or glCopyPixels.
Any stencil values that are retrieved by glReadPixels or glCopyPixels.
Frame buffer values are taken from dra.
If the current rendering thread has a current rendering context, that
context is flushed and replaced by _param4.
The first time that _param4 is made current, the viewport and scissor
dimensions are set to the size of the dra drawable. The viewport and
scissor are not modified when _param4 is subsequently made current.
To release the current context without assigning a new one, call
glXMakeContextCurrent with dra and _param3 set to None and _param4 set
to NULL.
glXMakeContextCurrent returns True if it is successful, False otherwise.
If False is returned, the previously current rendering context and draw‐
able (if any) remain unchanged.
NOTES
glXMakeContextCurrent is available only if the GLX version is 1.3 or
greater.
If the GLX version is 1.1 or 1.0, the GL version must be 1.0. If the
GLX version is 1.2, then the GL version must be 1.1. If the GLX version
able.
GLXBadWindow is generated if the underlying X window for either dra or
_param3 is no longer valid.
GLXBadCurrentDrawable is generated if the previous context of the call‐
ing thread has unflushed commands, and the previous drawable is no
longer valid.
BadAlloc is generated if the X server does not have enough resources to
allocate the buffers.
BadMatch is generated if:
dra and _param3 cannot fit into frame buffer memory simultaneously.
dra or _param3 is a GLXPixmap and _param4 is a direct rendering con‐
text.
dra or _param3 is a GLXPixmap and _param4 was previously bound to a
GLXWindow or GLXPbuffer.
dra or _param3 is a GLXWindow or GLXPbuffer and _param4 was previously
bound to a GLXPixmap.
SEE ALSO
glXCreateNewContext, glXCreateWindow, glXCreatePixmap, glXCreatePbuffer,
glXDestroyContext, glXGetCurrentContext, glXGetCurrentDisplay,
glXGetCurrentDrawable, glXGetCurrentReadDrawable, glXMakeCurrent
GLXMAKECONTEXTCURRENT(3G)
Man(1) output converted with
man2html