15bd8deadSopenharmony_ciXXX - Not complete.
25bd8deadSopenharmony_ci
35bd8deadSopenharmony_ciName
45bd8deadSopenharmony_ci
55bd8deadSopenharmony_ci    SGIX_dmbuffer
65bd8deadSopenharmony_ci
75bd8deadSopenharmony_ciName Strings
85bd8deadSopenharmony_ci
95bd8deadSopenharmony_ci    GLX_SGIX_dm_buffer
105bd8deadSopenharmony_ci
115bd8deadSopenharmony_ciVersion
125bd8deadSopenharmony_ci
135bd8deadSopenharmony_ci    $Date: 1997/09/26 09:48:00 $ $Revision: 1.6 $
145bd8deadSopenharmony_ci
155bd8deadSopenharmony_ciNumber
165bd8deadSopenharmony_ci
175bd8deadSopenharmony_ci    86
185bd8deadSopenharmony_ci
195bd8deadSopenharmony_ciDependencies
205bd8deadSopenharmony_ci
215bd8deadSopenharmony_ci    SGIX_FBConfig is required
225bd8deadSopenharmony_ci    SGI_make_current_read is required.
235bd8deadSopenharmony_ci    SGIX_pbuffer
245bd8deadSopenharmony_ci
255bd8deadSopenharmony_ciOverview
265bd8deadSopenharmony_ci
275bd8deadSopenharmony_ci    This extension introduces a new type of GLXPbuffer, a DM or Digital
285bd8deadSopenharmony_ci    Media pbuffer.  A DM pbuffer is a GLXPbuffer that adopts one or more 
295bd8deadSopenharmony_ci    of its buffers from an externally defined and allocated DMbuffer. 
305bd8deadSopenharmony_ci    In this way it resembles a GLXPixmap that attaches to an existing
315bd8deadSopenharmony_ci    X pixmap.  Like a standard pbuffer it can be used as a non-displayable
325bd8deadSopenharmony_ci    rendering area, or as a read source for pixel data.  The externally
335bd8deadSopenharmony_ci    defined buffers of the DM pbuffer can be sequentially associated 
345bd8deadSopenharmony_ci    with other DM buffers of the same size and configuration.  
355bd8deadSopenharmony_ci
365bd8deadSopenharmony_ci    .  The DM pbuffer is described with a new attrib passed to 
375bd8deadSopenharmony_ci       glXCreateGLXPbuffer.  
385bd8deadSopenharmony_ci
395bd8deadSopenharmony_ci    .  A new GLX command allows associating a compatible DMbuffer with 
405bd8deadSopenharmony_ci       the DM GLXPbuffer.  At associate time the DM buffers described 
415bd8deadSopenharmony_ci       by the DMparams are used directly as the corresponding 
425bd8deadSopenharmony_ci       buffers of the GLXPbuffer drawable, as described by the FBconfig.  
435bd8deadSopenharmony_ci       All other buffers that are part of the config will be created by
445bd8deadSopenharmony_ci       GL without externally referenceable names.  A DM pbuffer must be
455bd8deadSopenharmony_ci       associated with a compatible DMbuffer before it can be made current
465bd8deadSopenharmony_ci       to a GLX context. 
475bd8deadSopenharmony_ci
485bd8deadSopenharmony_ci    .  The externally defined buffers of the DM pbuffer can be changed at 
495bd8deadSopenharmony_ci       any time by successfully associating a new DMbuffer with the GLXPbuffer 
505bd8deadSopenharmony_ci       through the associate command.  It will be the application's 
515bd8deadSopenharmony_ci       responsibility to synchronize DMedia, GLX, and GL commands that 
525bd8deadSopenharmony_ci       effect the contents of the DM pbuffer.
535bd8deadSopenharmony_ci
545bd8deadSopenharmony_ci    .  Any direct GLX rendering context that satisfies config compatibility
555bd8deadSopenharmony_ci       can be used to render to or read from a DM GLXPbuffer.
565bd8deadSopenharmony_ci       A currently associated DMbuffer may simultaneously be in use by 
575bd8deadSopenharmony_ci       other clients on the same Display, but will not be destroyed
585bd8deadSopenharmony_ci       while associated with a GLXPbuffer.  When the GLXpbuffer is
595bd8deadSopenharmony_ci       destroyed, all buffers that have no remaining clients, including
605bd8deadSopenharmony_ci       the DMbuffer, will be freed.
615bd8deadSopenharmony_ci
625bd8deadSopenharmony_ci    DM GLXPbuffers are proposed as a means for OpenGL to access buffers
635bd8deadSopenharmony_ci    generated by the VL, compression, and other digital media libraries in 
645bd8deadSopenharmony_ci    a uniform way.  The DMbuffer and DMparams descriptors are left 
655bd8deadSopenharmony_ci    intentionally abstract so that the GLX extension can adapt to future 
665bd8deadSopenharmony_ci    DM library changes.  
675bd8deadSopenharmony_ci    The initial implementation will require that the DMparams descriptor
685bd8deadSopenharmony_ci    supply at least pixel format and packing information, and that the  
695bd8deadSopenharmony_ci    DMbuffer provide the size and location of a colorbuffer.  GLX will do 
705bd8deadSopenharmony_ci    compatibility checking when possible based on the config, params, and 
715bd8deadSopenharmony_ci    buffer information at associate time. 
725bd8deadSopenharmony_ci     
735bd8deadSopenharmony_ciIssues
745bd8deadSopenharmony_ci
755bd8deadSopenharmony_ci
765bd8deadSopenharmony_ciNew Procedures and Functions
775bd8deadSopenharmony_ci
785bd8deadSopenharmony_ci    Bool glXAssociateDMPbufferSGIX(Display *dpy,
795bd8deadSopenharmony_ci				   GLXPbufferSGIX pbuffer,
805bd8deadSopenharmony_ci                                   DMparams *params,
815bd8deadSopenharmony_ci                                   DMbuffer dmbuffer);
825bd8deadSopenharmony_ci
835bd8deadSopenharmony_ciNew Tokens
845bd8deadSopenharmony_ci
855bd8deadSopenharmony_ci    Accepted by the <attrib_list> parameter of glXCreateGLXPbufferSGIX
865bd8deadSopenharmony_ci    and by the <attribute> parameter of glXQueryGLXPbufferSGIX:
875bd8deadSopenharmony_ci
885bd8deadSopenharmony_ci        GLX_DIGITAL_MEDIA_PBUFFER_SGIX             0x8024
895bd8deadSopenharmony_ci
905bd8deadSopenharmony_ci
915bd8deadSopenharmony_ciAdditions to Chapter 2 of the 1.0 Specification (OpenGL Operation)
925bd8deadSopenharmony_ci
935bd8deadSopenharmony_ci    None
945bd8deadSopenharmony_ci
955bd8deadSopenharmony_ciAdditions to Chapter 3 of the 1.0 Specification (Rasterization)
965bd8deadSopenharmony_ci
975bd8deadSopenharmony_ci    None
985bd8deadSopenharmony_ci
995bd8deadSopenharmony_ciAdditions to Chapter 4 of the 1.0 Specification (Per-Fragment Operations
1005bd8deadSopenharmony_ciand the Frame buffer)
1015bd8deadSopenharmony_ci
1025bd8deadSopenharmony_ciAdditions to Chapter 5 of the 1.0 Specification (Special Functions)
1035bd8deadSopenharmony_ci
1045bd8deadSopenharmony_ci    None.
1055bd8deadSopenharmony_ci
1065bd8deadSopenharmony_ciAdditions to Chapter 6 of the 1.0 Specification (State and State Requests)
1075bd8deadSopenharmony_ci
1085bd8deadSopenharmony_ci    None.
1095bd8deadSopenharmony_ci
1105bd8deadSopenharmony_ciAdditions to the GLX Specification
1115bd8deadSopenharmony_ci
1125bd8deadSopenharmony_ci    XXX - not complete yet
1135bd8deadSopenharmony_ci
1145bd8deadSopenharmony_ci    [Add the following to section 3.2.3 on Offscreen Rendering]
1155bd8deadSopenharmony_ci
1165bd8deadSopenharmony_ci    To create a GLXPbuffer call:
1175bd8deadSopenharmony_ci
1185bd8deadSopenharmony_ci        GLXPbuffer glXCreateGLXPbufferSGIX(Display *dpy,
1195bd8deadSopenharmony_ci                                           GLXFBConfig config,
1205bd8deadSopenharmony_ci                                           unsigned int width,
1215bd8deadSopenharmony_ci                                           unsigned int height,
1225bd8deadSopenharmony_ci                                           int *attrib_list);
1235bd8deadSopenharmony_ci
1245bd8deadSopenharmony_ci    This creates a single GLXPbuffer and returns its XID. <width> and <height>
1255bd8deadSopenharmony_ci    specify the pixel width and height of the rectangular pbuffer and
1265bd8deadSopenharmony_ci    <attrib_list> specifies a list of attributes for the pbuffer. Currently
1275bd8deadSopenharmony_ci    only three attributes can be specified in <attrib_list>:
1285bd8deadSopenharmony_ci    GLX_PRESERVED_CONTENTS_SGIX, GLX_LARGEST_PBUFFER_SGIX and
1295bd8deadSopenharmony_ci    GLX_DIGITAL_MEDIA_PBUFFER_SGIX.
1305bd8deadSopenharmony_ci
1315bd8deadSopenharmony_ci    [Add following the section on the GLX_PRESERVED_CONTENTS_SGIX attrib]
1325bd8deadSopenharmony_ci
1335bd8deadSopenharmony_ci    The resulting pbuffer, when made current, will contain color buffers 
1345bd8deadSopenharmony_ci    and ancillary buffers as specified by <config>. It is possible to create 
1355bd8deadSopenharmony_ci    a pbuffer with back buffers and to swap the front and back buffers by 
1365bd8deadSopenharmony_ci    calling glXSwapBuffers. Note that some pbuffers use framebuffer resources 
1375bd8deadSopenharmony_ci    so applications should consider deallocating them when they are not in use.
1385bd8deadSopenharmony_ci
1395bd8deadSopenharmony_ci    If the GLX_DIGITAL_MEDIA_PBUFFER_SGIX attribute is set to True in
1405bd8deadSopenharmony_ci    <attrib_list>, then one or more of the pbuffer's color or ancillary 
1415bd8deadSopenharmony_ci    buffers may be shared with those of a currently associated DMbuffer.  
1425bd8deadSopenharmony_ci    Buffers described by the pbuffer's GLXFBConfig which are not defined
1435bd8deadSopenharmony_ci    by the DMbuffer, are GLX resources that remain associated with the
1445bd8deadSopenharmony_ci    DM pbuffer until it is destroyed.
1455bd8deadSopenharmony_ci    An implementation may fail glXCreateGLXPbufferSGIX and generate a
1465bd8deadSopenharmony_ci    BadMatch error when the sepcified <config> does not describe a  
1475bd8deadSopenharmony_ci    drawable that is compatible with any supported DMbuffers.
1485bd8deadSopenharmony_ci
1495bd8deadSopenharmony_ci    The GLXPbuffer is associated with a DMbuffer by calling:
1505bd8deadSopenharmony_ci
1515bd8deadSopenharmony_ci        Bool glXAssociateDMPbufferSGIX(Display *dpy,
1525bd8deadSopenharmony_ci                                       GLXPbufferSGIX pbuffer,
1535bd8deadSopenharmony_ci                                       DMparams *params,
1545bd8deadSopenharmony_ci                                       DMbuffer dmbuffer);
1555bd8deadSopenharmony_ci
1565bd8deadSopenharmony_ci    The parameter <display> specifies a connection to an X server, and must 
1575bd8deadSopenharmony_ci    match the display used to create the GLXPbuffer <pbuffer>.  The 
1585bd8deadSopenharmony_ci    DMparams <params> arg specifies the digital media characteristics
1595bd8deadSopenharmony_ci    of the <dmbuffer> that will be associated with the DM pbuffer.  
1605bd8deadSopenharmony_ci    If glXAssociateDMbufferSGIX succeeds, any previously associated DMbuffer
1615bd8deadSopenharmony_ci    is released and a value of True is returned.  Subsequent GL commands 
1625bd8deadSopenharmony_ci    effect <dmbuffer> as they would any standard pbuffer.  If a newly 
1635bd8deadSopenharmony_ci    released DMbuffer has no remaining clients, its buffers will also be freed. 
1645bd8deadSopenharmony_ci    A BadMatch error is generated when the specified DMparams or DMbuffer
1655bd8deadSopenharmony_ci    are not compatible with the <pbuffer>, and a value of False is returned.
1665bd8deadSopenharmony_ci
1675bd8deadSopenharmony_ci    Before the DM pbuffer can be made current to a GLXContext, it must 
1685bd8deadSopenharmony_ci    be associated with a compatible DMbuffer.  glXMakeCurrentReadSGI will 
1695bd8deadSopenharmony_ci    return False and generate a GLXBadDrawable error when a DM pbuffer 
1705bd8deadSopenharmony_ci    drawable has no associated DMbuffer.
1715bd8deadSopenharmony_ci
1725bd8deadSopenharmony_ci    A GLXPbuffer is destroyed by calling:
1735bd8deadSopenharmony_ci
1745bd8deadSopenharmony_ci        void glXDestroyGLXPbufferSGIX(Display *dpy,
1755bd8deadSopenharmony_ci                                      GLXPbuffer pbuf);
1765bd8deadSopenharmony_ci
1775bd8deadSopenharmony_ci    The GLXPbuffer will be destroyed once it is no longer current to any
1785bd8deadSopenharmony_ci    client. When a GLXPbuffer is destroyed, any memory resources that
1795bd8deadSopenharmony_ci    attached to it, are freed, and its XID is made available for reuse.
1805bd8deadSopenharmony_ci    Associated DMbuffers are released, and if they no lonnger have a 
1815bd8deadSopenharmony_ci    client, are also freed. 
1825bd8deadSopenharmony_ci
1835bd8deadSopenharmony_ciErrors
1845bd8deadSopenharmony_ci
1855bd8deadSopenharmony_ci    XXX - not complete yet
1865bd8deadSopenharmony_ci
1875bd8deadSopenharmony_ciNew State
1885bd8deadSopenharmony_ci
1895bd8deadSopenharmony_ci    None.
1905bd8deadSopenharmony_ci
1915bd8deadSopenharmony_ciNew Implementation Dependent State
1925bd8deadSopenharmony_ci
1935bd8deadSopenharmony_ci    None.
1945bd8deadSopenharmony_ci
195