GLXCREATEGLXPBUFFERSGIX(3GL)GLXCREATEGLXPBUFFERSGIX(3GL)NAME
glXCreateGLXPbufferSGIX - create a Pbuffer
C SPECIFICATION
GLXPbuffer glXCreateGLXPbufferSGIX ( Display *dpy,
GLXFBConfig config,
unsigned int width,
unsigned int height'
int *attribu_list)
PARAMETERS
dpy Specifies the connection to the X server.
config Specifies the GLX configuration that defines the capa‐
blilty of the Pbuffer.
width Specify the width of Pbuffer.
height Specify the height of Pbuffer.
attrib_list Specifies a list of attributes for the pbuffer.
DESCRIPTION
glXCreateGLXPbufferSGIX creates a non-visible rendering pixel buffer
GLXPbuffer, or pbuffer for short) for an OpenGL renderer, and returns
its XID. GLXPbuffers are equivalent to GLXPixmaps with the following
exceptions:
1. There is no associated X pixmap. Also, since a GLXPbuffer is a
GLX resource, it may not be possible to render to it using X or
an X extension other than GLX.
2. The format of the color buffers and the type and size of any
associated ancillary buffers for a GLXPbuffer can only be
described with a GLXFBConfig which an X Visual cannot be used.
3.
GLXPbuffers can be rendered to using either direct or indirect
rendering contexts.
Any GLX rendering context created with a GLXFBConfig or X Visual that
is "compatible" with the <config> may be used to render into the
pbuffer. (See glXCreateContextWithConfigSGIX, glXMakeCurrent, and glX‐
MakeCurrentReadSGI for definition of "compatible".)
In some implementations, a GLXPbuffer is allocated on off-screen frame
buffer memory. In this case, the contents of a GLXPbuffer may be asyn‐
chronously lost at any time.
<attrib_list> can be NULL, in which case all the attributes assume
their default values as described below. If it not NULL then each
attribute is immediately followed by the corresponding desired value
and the list is terminated with None.
The two pbuffer attributes are defined:
GLX_LARGEST_PBUFFER_SGIX
If True, the largest available pbuffer s allocated when the
allocation of the pbuffer would otherwise fail. The width or
height of the allocated pbuffer never exceed <width> and
<height>, respectively. The default is False.
GLX_PRESERVED_CONTENTS_SGIX
If False, then an "unpreserved" pbuffer is created and the con‐
tents of the pbuffer may be lost at any time. If True, then the
contents of the pbuffer will be preserved when a resource con‐
flict occurs. The default is True. The client can register to
receive a "buffer clobber" event which is generated when the
pbuffer contents have been preserved or have been damaged. (See
glXGetSelectedEventSGIX.)
NOTES
1. The pbuffer contains color buffers and ancillary as specified by
config. In Sun's implementation, Pbuffer is single-buffered, and
the color buffer depth is 24 (See glXChooseFBConfigSGIX).
Pbuffer is allocated in the main memory, and
GLX_LARGEST_PBUFFER_SGIX is always False and GLX_PRESERVED_CON‐
TENTS_SGIX True. That is, pbuffer content is always preserved.
2. glXCreateGLXPbufferSGIX is part of the SGIX_pbuffer extension,
not part of the core GLX command set. If SGIX_pbuffer is
included in the string returned by glXQueryExtensionsString,
extension SGIX_pbuffer is supported by the connection.
3. This function is superseded by glXCreatePbuffer, which is part
of GLX Version 1.3 command set. glXCreateGLXPbufferSGIX is sup‐
ported only for backward compatibility.
ERRORS
BadAlloc is generated and None is returned if glXCreateGLXPbufferSGIX
fails to create a GLXPbuffer due to insufficient resources.
GLXBadFBConfigSGIX is generated if config is not a valid GLXFBConfig.
BadMatch is generated if config does not support GLXPbuffers.
SEE ALSO
glXChooseFBConfigSGIX, glXCreateContextWithConfigSGIX, glXDestroyGLXP‐
bufferSGIX, glXMakeCurrent, glXMakeCurrentReadSGI, glXSelectEventSGIX,
glXQueryExtensionsString.
21 May 01 GLXCREATEGLXPBUFFERSGIX(3GL)