15bd8deadSopenharmony_ciName 25bd8deadSopenharmony_ci 35bd8deadSopenharmony_ci SGIX_hyperpipe 45bd8deadSopenharmony_ci 55bd8deadSopenharmony_ciName Strings 65bd8deadSopenharmony_ci 75bd8deadSopenharmony_ci GLX_SGIX_hyperpipe 85bd8deadSopenharmony_ci 95bd8deadSopenharmony_ciContact 105bd8deadSopenharmony_ci 115bd8deadSopenharmony_ci Jon Leech, SGI (ljp 'at' sgi.com) 125bd8deadSopenharmony_ci 135bd8deadSopenharmony_ciStatus 145bd8deadSopenharmony_ci 155bd8deadSopenharmony_ci Shipping on SGI Infinite Reality and Ultimate Vision systems. 165bd8deadSopenharmony_ci 175bd8deadSopenharmony_ciVersion 185bd8deadSopenharmony_ci 195bd8deadSopenharmony_ci Last Modified Date: 2004/07/21 205bd8deadSopenharmony_ci Revision: $Header: //depot/main/doc/registry/extensions/SGI/hyperpipe_group.spec#14 $ 215bd8deadSopenharmony_ci 225bd8deadSopenharmony_ciNumber 235bd8deadSopenharmony_ci 245bd8deadSopenharmony_ci 307 255bd8deadSopenharmony_ci 265bd8deadSopenharmony_ciDependencies 275bd8deadSopenharmony_ci 285bd8deadSopenharmony_ci GLX 1.2 is required 295bd8deadSopenharmony_ci SGIX_swap_control affects the definition of this extension. 305bd8deadSopenharmony_ci 315bd8deadSopenharmony_ciOverview 325bd8deadSopenharmony_ci 335bd8deadSopenharmony_ci Even though graphics hardware is constantly improving in speed, there 345bd8deadSopenharmony_ci will always be applications that require more performance than is 355bd8deadSopenharmony_ci available from a single pipeline. In order to overcome these limits, 365bd8deadSopenharmony_ci it is possible to parallelize the rendering task across multiple 375bd8deadSopenharmony_ci pipes; the image outputs of these pipes must then be assembled into 385bd8deadSopenharmony_ci a single display output. This group of pipes is termed a hyperpipe; 395bd8deadSopenharmony_ci the pipes involved must be physically cabled together in some way 405bd8deadSopenharmony_ci to form a hyperpipe network. Typically a hyperpipe network uses one 415bd8deadSopenharmony_ci of the pipes to assemble the rendered images and drive the display. 425bd8deadSopenharmony_ci 435bd8deadSopenharmony_ci In a hyperpipe network, the rendering task may be divided by rendering 445bd8deadSopenharmony_ci each successive frame on a different hardware pipe (temporal division); 455bd8deadSopenharmony_ci by dividing the frame into rectangular subregions and rendering each 465bd8deadSopenharmony_ci on a different pipe (spatial division); or by a combination of these 475bd8deadSopenharmony_ci two techniques. Specific hardware implementations may impose limits 485bd8deadSopenharmony_ci on how rendering may be subdivided; but in general it is possible to 495bd8deadSopenharmony_ci use a subset of the pipes connected to a hyperpipe network if desired. 505bd8deadSopenharmony_ci 515bd8deadSopenharmony_ci This extension provides a means for configuring and managing a group 525bd8deadSopenharmony_ci of rendering pipes which work together to produce a single display. 535bd8deadSopenharmony_ci Typically, a hyperpipe application will be multithreaded, with 545bd8deadSopenharmony_ci one thread per pipe; each thread needs to create its own rendering 555bd8deadSopenharmony_ci context. The hyperpipe extension allows these rendering threads to 565bd8deadSopenharmony_ci communicate with the hardware. 575bd8deadSopenharmony_ci 585bd8deadSopenharmony_ci The API calls allow an application to : 595bd8deadSopenharmony_ci 605bd8deadSopenharmony_ci o Determine the physical configuration of a hyperpipe network. 615bd8deadSopenharmony_ci 625bd8deadSopenharmony_ci o Configure the hyperpipe. The hyperpipe configuration used by the 635bd8deadSopenharmony_ci application may be a subset of the physical hyperpipe network. 645bd8deadSopenharmony_ci The rendering task may be divided in time slices (temporally divided), 655bd8deadSopenharmony_ci in rectangular regions of a single frame (spatially divided), or both. 665bd8deadSopenharmony_ci The hyperpipe configuration is subject to hardware constraints. 675bd8deadSopenharmony_ci 685bd8deadSopenharmony_ci For example, on a hyperpipe network consisting of five pipes, it 695bd8deadSopenharmony_ci would be possible to configure a rendering task in two time slices, 705bd8deadSopenharmony_ci with each slice being rendered by two pipes; thus using four total 715bd8deadSopenharmony_ci pipes. (The fifth pipe would not be used in the hyperpipe, and 725bd8deadSopenharmony_ci could be used for normal non-hyperpipe rendering and display). 735bd8deadSopenharmony_ci 745bd8deadSopenharmony_ci o Maintain state to manage the glXSwapBuffers() call correctly. In 755bd8deadSopenharmony_ci spatial subdivision, swap cannot occur until all pipes rendering 765bd8deadSopenharmony_ci the next frame have completed; and in temporal subdivision, swap 775bd8deadSopenharmony_ci cannot occur until the appropriate time. Swap management is 785bd8deadSopenharmony_ci handled by the displaying pipe. 795bd8deadSopenharmony_ci 805bd8deadSopenharmony_ci o Redirect resize parameters correctly; typically resize is handled 815bd8deadSopenharmony_ci by the displaying pipe, and must be managed synchronously with 825bd8deadSopenharmony_ci swap. 835bd8deadSopenharmony_ci 845bd8deadSopenharmony_ci o Balance load among the pipes in the spatial subdivision case. 855bd8deadSopenharmony_ci 865bd8deadSopenharmony_ci o Clean up operations when a hyperpipe application terminates 875bd8deadSopenharmony_ci (either normally or due to error). 885bd8deadSopenharmony_ci 895bd8deadSopenharmony_ci This extension adds to the set of conditions that must be met before 905bd8deadSopenharmony_ci a buffer swap can take place. 915bd8deadSopenharmony_ci 925bd8deadSopenharmony_ciIssues and Notes 935bd8deadSopenharmony_ci 945bd8deadSopenharmony_ci o This extension will work only on graphics pipelines with suitable 955bd8deadSopenharmony_ci hyperpipe hardware installed. 965bd8deadSopenharmony_ci 975bd8deadSopenharmony_ci 985bd8deadSopenharmony_ciNew Procedures and Functions 995bd8deadSopenharmony_ci 1005bd8deadSopenharmony_ci The following structure definitions are used by the extension: 1015bd8deadSopenharmony_ci 1025bd8deadSopenharmony_ci /* 1035bd8deadSopenharmony_ci * pipeName uniquely names a pipe in the form ":display.screen" 1045bd8deadSopenharmony_ci * networkId is a unique physical hyperpipe network ID. 1055bd8deadSopenharmony_ci */ 1065bd8deadSopenharmony_ci typedef struct { 1075bd8deadSopenharmony_ci char pipeName[GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX]; 1085bd8deadSopenharmony_ci int networkId; 1095bd8deadSopenharmony_ci } GLXHyperpipeNetworkSGIX; 1105bd8deadSopenharmony_ci 1115bd8deadSopenharmony_ci /* 1125bd8deadSopenharmony_ci * pipeName uniquely names a pipe in the form ":display.screen" 1135bd8deadSopenharmony_ci * channel is the channel number associated with the display pipe. 1145bd8deadSopenharmony_ci * participationType is a bitmask describing the attributes of a 1155bd8deadSopenharmony_ci * participating pipe. It may contain one or more of the 1165bd8deadSopenharmony_ci * attribute bits 1175bd8deadSopenharmony_ci * GLX_HYPERPIPE_DISPLAY_PIPE_SGIX 1185bd8deadSopenharmony_ci * GLX_HYPERPIPE_RENDERING_PIPE_SGIX 1195bd8deadSopenharmony_ci * timeSlice is ignored for GLX_HYPERPIPE_DISPLAY_PIPE_SGIX only. 1205bd8deadSopenharmony_ci */ 1215bd8deadSopenharmony_ci typedef struct { 1225bd8deadSopenharmony_ci char pipeName[GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX]; 1235bd8deadSopenharmony_ci int channel; 1245bd8deadSopenharmony_ci unsigned int participationType; 1255bd8deadSopenharmony_ci int timeSlice; 1265bd8deadSopenharmony_ci } GLXHyperpipeConfigSGIX; 1275bd8deadSopenharmony_ci 1285bd8deadSopenharmony_ci /* 1295bd8deadSopenharmony_ci * pipeName uniquely names a pipe in the form ":display.screen" 1305bd8deadSopenharmony_ci * src origin/size are in managed area coordinates (pixels). 1315bd8deadSopenharmony_ci * dest origin/size are in output channel display coordinates. 1325bd8deadSopenharmony_ci */ 1335bd8deadSopenharmony_ci typedef struct { 1345bd8deadSopenharmony_ci char pipeName[GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX]; 1355bd8deadSopenharmony_ci int srcXOrigin; 1365bd8deadSopenharmony_ci int srcYOrigin; 1375bd8deadSopenharmony_ci int srcWidth; 1385bd8deadSopenharmony_ci int srcHeight; 1395bd8deadSopenharmony_ci int destXOrigin; 1405bd8deadSopenharmony_ci int destYOrigin; 1415bd8deadSopenharmony_ci int destWidth; 1425bd8deadSopenharmony_ci int destHeight; 1435bd8deadSopenharmony_ci } GLXPipeRect; 1445bd8deadSopenharmony_ci 1455bd8deadSopenharmony_ci /* 1465bd8deadSopenharmony_ci * pipeName uniquely names a pipe in the form ":display.screen" 1475bd8deadSopenharmony_ci * origin/size are in managed area coordinates (pixels) 1485bd8deadSopenharmony_ci */ 1495bd8deadSopenharmony_ci typedef struct { 1505bd8deadSopenharmony_ci char pipeName[GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX]; 1515bd8deadSopenharmony_ci int XOrigin; /* pixels in managed area */ 1525bd8deadSopenharmony_ci int YOrigin; 1535bd8deadSopenharmony_ci int maxHeight; 1545bd8deadSopenharmony_ci int maxWidth; 1555bd8deadSopenharmony_ci } GLXPipeRectLimits; 1565bd8deadSopenharmony_ci 1575bd8deadSopenharmony_ci GLXHyperpipeNetworkSGIX * 1585bd8deadSopenharmony_ci glXQueryHyperpipeNetworkSGIX( 1595bd8deadSopenharmony_ci Display *dpy, int *npipes); 1605bd8deadSopenharmony_ci 1615bd8deadSopenharmony_ci int glXHyperpipeConfigSGIX( 1625bd8deadSopenharmony_ci Display *dpy, int networkId, int npipes, 1635bd8deadSopenharmony_ci GLXHyperpipeConfigSGIX *cfg, int *hpId); 1645bd8deadSopenharmony_ci 1655bd8deadSopenharmony_ci GLXHyperpipeConfigSGIX * 1665bd8deadSopenharmony_ci glXQueryHyperpipeConfigSGIX( 1675bd8deadSopenharmony_ci Display *dpy, int hpId, int *npipes); 1685bd8deadSopenharmony_ci 1695bd8deadSopenharmony_ci int glXDestroyHyperpipeConfigSGIX( 1705bd8deadSopenharmony_ci Display * dpy, int hpId); 1715bd8deadSopenharmony_ci 1725bd8deadSopenharmony_ci int glXBindHyperpipeSGIX( 1735bd8deadSopenharmony_ci Display *dpy, int hpId); 1745bd8deadSopenharmony_ci 1755bd8deadSopenharmony_ci int glXQueryHyperpipeBestAttribSGIX( 1765bd8deadSopenharmony_ci Display *dpy, int timeSlice, int attrib, int size, 1775bd8deadSopenharmony_ci void *attribList, void *returnAttribList); 1785bd8deadSopenharmony_ci 1795bd8deadSopenharmony_ci int glXHyperpipeAttribSGIX( 1805bd8deadSopenharmony_ci Display *dpy, int timeSlice, int attrib, int size, 1815bd8deadSopenharmony_ci void *attribList); 1825bd8deadSopenharmony_ci 1835bd8deadSopenharmony_ci int glXQueryHyperpipeAttribSGIX( 1845bd8deadSopenharmony_ci Display *dpy, int timeSlice, int attrib, int size, 1855bd8deadSopenharmony_ci void *returnAttribList); 1865bd8deadSopenharmony_ci 1875bd8deadSopenharmony_ci 1885bd8deadSopenharmony_ci 1895bd8deadSopenharmony_ciNew Tokens 1905bd8deadSopenharmony_ci 1915bd8deadSopenharmony_ci Accepted by the <attribute> parameter of glXQueryContextInfoEXT: 1925bd8deadSopenharmony_ci 1935bd8deadSopenharmony_ci GLX_HYPERPIPE_ID_SGIX 0x8030 1945bd8deadSopenharmony_ci 1955bd8deadSopenharmony_ci Maximum length of the string naming a hyperpipe: 1965bd8deadSopenharmony_ci 1975bd8deadSopenharmony_ci GLX_HYPERPIPE_PIPE_NAME_LENGTH_SGIX 80 1985bd8deadSopenharmony_ci 1995bd8deadSopenharmony_ci Bits that may be set in the <participationType> bitfield of the 2005bd8deadSopenharmony_ci GLXHyperpipeConfigSGIX argument passed into glXHyperpipeConfigSGIX 2015bd8deadSopenharmony_ci and returned by glXQueryHyperpipeConfigSGIX: 2025bd8deadSopenharmony_ci 2035bd8deadSopenharmony_ci GLX_HYPERPIPE_DISPLAY_PIPE_SGIX 0x00000001 2045bd8deadSopenharmony_ci GLX_HYPERPIPE_RENDER_PIPE_SGIX 0x00000002 2055bd8deadSopenharmony_ci 2065bd8deadSopenharmony_ci Accepted by the <attrib> parameter of glXQueryHyperpipeAttribSGIX: 2075bd8deadSopenharmony_ci 2085bd8deadSopenharmony_ci GLX_PIPE_RECT_SGIX 0x00000001 2095bd8deadSopenharmony_ci GLX_PIPE_RECT_LIMITS_SGIX 0x00000002 2105bd8deadSopenharmony_ci GLX_HYPERPIPE_STEREO_SGIX 0x00000003 2115bd8deadSopenharmony_ci GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX 0x00000004 2125bd8deadSopenharmony_ci 2135bd8deadSopenharmony_ci Accepted by the <attrib> parameters of and glXHyperpipeAttribSGIX: 2145bd8deadSopenharmony_ci 2155bd8deadSopenharmony_ci GLX_PIPE_RECT_SGIX 2165bd8deadSopenharmony_ci GLX_HYPERPIPE_STEREO_SGIX 2175bd8deadSopenharmony_ci GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX 2185bd8deadSopenharmony_ci 2195bd8deadSopenharmony_ci Accepted by the <attrib> parameter of 2205bd8deadSopenharmony_ci glXQueryHyperpipeBestAttribSGIX: 2215bd8deadSopenharmony_ci 2225bd8deadSopenharmony_ci GLX_PIPE_RECT_SGIX 2235bd8deadSopenharmony_ci GLX_PIPE_RECT_LIMITS_SGIX 2245bd8deadSopenharmony_ci 2255bd8deadSopenharmony_ci New error codes: 2265bd8deadSopenharmony_ci 2275bd8deadSopenharmony_ci GLX_BAD_HYPERPIPE_CONFIG_SGIX 91 2285bd8deadSopenharmony_ci GLX_BAD_HYPERPIPE_SGIX 92 2295bd8deadSopenharmony_ci 2305bd8deadSopenharmony_ci 2315bd8deadSopenharmony_ciAdditions to the GLX 1.3 Specification 2325bd8deadSopenharmony_ci 2335bd8deadSopenharmony_ci Add new section 3.X "Hyperpipes" 2345bd8deadSopenharmony_ci 2355bd8deadSopenharmony_ci Hyperpipes are collections of graphics pipes that may operate 2365bd8deadSopenharmony_ci together to generate images. The pipes may be split either spatially 2375bd8deadSopenharmony_ci (with different pipes rendering different subrectangles of an output 2385bd8deadSopenharmony_ci image), temporally (with different pipes rendering different time 2395bd8deadSopenharmony_ci slices of an output image), or both. 2405bd8deadSopenharmony_ci 2415bd8deadSopenharmony_ci Section 3.X.1 "Hyperpipe Networks" 2425bd8deadSopenharmony_ci 2435bd8deadSopenharmony_ci To determine the physical connectivity of hyperpipes in a system, 2445bd8deadSopenharmony_ci call 2455bd8deadSopenharmony_ci 2465bd8deadSopenharmony_ci GLXHyperpipeNetworkSGIX *glXQueryHyperpipeNetworkSGIX( 2475bd8deadSopenharmony_ci Display *dpy, int *npipes) 2485bd8deadSopenharmony_ci 2495bd8deadSopenharmony_ci There may be more than one hyperpipe network in the system. The 2505bd8deadSopenharmony_ci networks are numbered sequentially. 2515bd8deadSopenharmony_ci 2525bd8deadSopenharmony_ci glXQueryHyperpipeNetworkSGIX returns a pointer to an array of 2535bd8deadSopenharmony_ci GLXHyperpipeNetworkSGIX structures describing the availalable pipes. 2545bd8deadSopenharmony_ci This list is sorted on the physical hyperpipe network number (the 2555bd8deadSopenharmony_ci <networkId> field of the GLXHyperpipeNetworkSGIX structure). 2565bd8deadSopenharmony_ci Networks are numbered sequentially from 0. 2575bd8deadSopenharmony_ci 2585bd8deadSopenharmony_ci The number of pipes is returned in <*npipes>. If no hyperpipe 2595bd8deadSopenharmony_ci network is defined in the system, NULL is returned. returns NULL. 2605bd8deadSopenharmony_ci Use XFree to free the array returned by 2615bd8deadSopenharmony_ci glXQueryHyperpipeNetworkSGIX. 2625bd8deadSopenharmony_ci 2635bd8deadSopenharmony_ci 2645bd8deadSopenharmony_ci Section 3.X.2 "Hyperpipe Configuration" 2655bd8deadSopenharmony_ci 2665bd8deadSopenharmony_ci To specify the logical configuration of a hyperpipe, call 2675bd8deadSopenharmony_ci 2685bd8deadSopenharmony_ci int glXHyperpipeConfigSGIX(Display *dpy, int networkId, 2695bd8deadSopenharmony_ci int npipes, GLXHyperpipeConfigSGIX *cfg, int *hpId); 2705bd8deadSopenharmony_ci 2715bd8deadSopenharmony_ci The physical connectivity of a hyperpipe is determined by the 2725bd8deadSopenharmony_ci cabling of the hardware. It is possible to use only a subset of the 2735bd8deadSopenharmony_ci pipes physically connected together. These participant pipes may 2745bd8deadSopenharmony_ci contribute to the hyperpipe in a temporally interleaved manner 2755bd8deadSopenharmony_ci and/or spatially subdivided manner. The configuration information 2765bd8deadSopenharmony_ci specifies which pipes participate in the hyperpipe. It also 2775bd8deadSopenharmony_ci specifies the relative order of these pipes and their type of 2785bd8deadSopenharmony_ci contribution (spatial or temporal). This configuration cannot be 2795bd8deadSopenharmony_ci arbitrary and is subject to some hardware constraints. 2805bd8deadSopenharmony_ci 2815bd8deadSopenharmony_ci <networkId> specifies the physical hyperpipe network ID to be 2825bd8deadSopenharmony_ci configured. <npipes> specifies the total number of pipes in the 2835bd8deadSopenharmony_ci configuration. <cfg> is a pointer to an array of <npipes> 2845bd8deadSopenharmony_ci GLXHyperpipeConfigSGIX structures, each specifying the configuration 2855bd8deadSopenharmony_ci for a single pipe. 2865bd8deadSopenharmony_ci 2875bd8deadSopenharmony_ci The <pipeName> field of each <cfg> structure specifies the pipe ID 2885bd8deadSopenharmony_ci of that pipe, and the <channel> field specifies a channel number 2895bd8deadSopenharmony_ci associated with that pipe. 2905bd8deadSopenharmony_ci 2915bd8deadSopenharmony_ci If the <participationType> field contains 2925bd8deadSopenharmony_ci GLX_HYPERPIPE_RENDER_PIPE_SGIX, the pipe is designated to render 2935bd8deadSopenharmony_ci data for a subset of the pipeline (spatially or temporally). If the 2945bd8deadSopenharmony_ci field contains GLX_HYPERPIPE_DISPLAY_PIPE_SGIX, the pipe is 2955bd8deadSopenharmony_ci designated to assemble rendered data and display it on that pipe's 2965bd8deadSopenharmony_ci local channel. There can be multiple rendering pipes, but only one 2975bd8deadSopenharmony_ci display pipe in a network. 2985bd8deadSopenharmony_ci 2995bd8deadSopenharmony_ci The <timeSlice> field specifies the time slice to which a rendering 3005bd8deadSopenharmony_ci pipe contributes, and must be in the range 0 to <npipes>-1. 3015bd8deadSopenharmony_ci 3025bd8deadSopenharmony_ci On success, a unique hyperpipe ID is generated and returned in the 3035bd8deadSopenharmony_ci integer pointed to by <hpId>. Subsequent calls may require a valid 3045bd8deadSopenharmony_ci hyperpipe ID parameter. In the case of a multi-process application, 3055bd8deadSopenharmony_ci the master process should configure the hyperpipe, and child 3065bd8deadSopenharmony_ci processes should then use the same hyperpipe ID as the master 3075bd8deadSopenharmony_ci process. The hyperpipe ID is global across multiple processes. If 3085bd8deadSopenharmony_ci another process attempts a configuration using already allocated 3095bd8deadSopenharmony_ci pipes, the second configuration will fail. 3105bd8deadSopenharmony_ci 3115bd8deadSopenharmony_ci If the pipes contribute in a spatially subdivided manner, then the 3125bd8deadSopenharmony_ci screen is divided evenly between them. This division can be 3135bd8deadSopenharmony_ci subsequently changed via calls to glXHyperpipeAttribSGIX(). 3145bd8deadSopenharmony_ci 3155bd8deadSopenharmony_ci glXHyperpipeConfigSGIX() returns GLX_BAD_HYPERPIPE_CONFIG_SGIX if 3165bd8deadSopenharmony_ci the specified <cfg> is invalid. 3175bd8deadSopenharmony_ci 3185bd8deadSopenharmony_ci 3195bd8deadSopenharmony_ci To query the details of a hyperpipe configuration, call 3205bd8deadSopenharmony_ci 3215bd8deadSopenharmony_ci GLXHyperpipeConfigSGIX *glXQueryHyperpipeConfigSGIX( 3225bd8deadSopenharmony_ci Display *dpy, int hpId, int *npipes); 3235bd8deadSopenharmony_ci 3245bd8deadSopenharmony_ci <hpId> is the ID of the hyperpipe configuration to query. It must 3255bd8deadSopenharmony_ci have been obtained from a previous call to glXHyperpipeConfigSGIX. 3265bd8deadSopenharmony_ci 3275bd8deadSopenharmony_ci glXQueryHyperpipeConfigSGIX returns a pointer to an array of 3285bd8deadSopenharmony_ci GLXHyperpipeConfigSGIX structures describing the pipes in the 3295bd8deadSopenharmony_ci configuration. The parameters of the structures are as described for 3305bd8deadSopenharmony_ci glXHyperpipeConfigSGIX. 3315bd8deadSopenharmony_ci 3325bd8deadSopenharmony_ci The number of pipes is returned in <*npipes>. If <hpId> is not a 3335bd8deadSopenharmony_ci valid hyperpipe ID, NULL is returned. Use XFree to free the array 3345bd8deadSopenharmony_ci returned by glXQueryHyperpipeConfigSGIX. 3355bd8deadSopenharmony_ci 3365bd8deadSopenharmony_ci 3375bd8deadSopenharmony_ci To destroy a hyperpipe configuration, call 3385bd8deadSopenharmony_ci 3395bd8deadSopenharmony_ci int glXDestroyHyperpipeConfigSGIX(Display * dpy, int hpId); 3405bd8deadSopenharmony_ci 3415bd8deadSopenharmony_ci <hpId> is the ID of the hyperpipe configuration to destroy. It must 3425bd8deadSopenharmony_ci have been obtained from a previous call to glXHyperpipeConfigSGIX. 3435bd8deadSopenharmony_ci All process should unbind from <hpId> by calling 3445bd8deadSopenharmony_ci glXBindHyperipipeSGIX(dpy, -1) before destroying the hyperpipe 3455bd8deadSopenharmony_ci configuration. 3465bd8deadSopenharmony_ci 3475bd8deadSopenharmony_ci On success, the resources associated with <hpId> are destroyed and 3485bd8deadSopenharmony_ci <hpId> is no longer a valid hyperpipe ID. 3495bd8deadSopenharmony_ci 3505bd8deadSopenharmony_ci glXHyperpipeConfigSGIX() returns GLX_BAD_HYPERPIPE_SGIX if there is 3515bd8deadSopenharmony_ci no valid hyperpipe configuration with the specified ID. 3525bd8deadSopenharmony_ci 3535bd8deadSopenharmony_ci 3545bd8deadSopenharmony_ci Section 3.X.2 "Binding Hyperpipes" 3555bd8deadSopenharmony_ci 3565bd8deadSopenharmony_ci To bind the current rendering context to a hyperpipe, call 3575bd8deadSopenharmony_ci 3585bd8deadSopenharmony_ci int glXBindHyperpipeSGIX(Display *dpy, int hpId); 3595bd8deadSopenharmony_ci 3605bd8deadSopenharmony_ci This establishes an association between the calling process, the 3615bd8deadSopenharmony_ci current context, and the hyperpipe configuration with ID <hpId>. 3625bd8deadSopenharmony_ci When this rendering context is destroyed, the hyperpipe operations 3635bd8deadSopenharmony_ci associated with this hyperpipe group may be terminated. 3645bd8deadSopenharmony_ci 3655bd8deadSopenharmony_ci Every process participating in a hyperpipe should call 3665bd8deadSopenharmony_ci glXBindHyperpipeSGIX after creating and choosing a rendering 3675bd8deadSopenharmony_ci context. Hyperpipe requests to this process will not begin until 3685bd8deadSopenharmony_ci this call is made. 3695bd8deadSopenharmony_ci 3705bd8deadSopenharmony_ci It is possible to determine if a hyperpipe is bound by calling 3715bd8deadSopenharmony_ci glXQueryContextInfoEXT with the attribute GLX_HYPERPIPE_ID_SGIX. 3725bd8deadSopenharmony_ci 3735bd8deadSopenharmony_ci Calling glXBindHyperpipeSGIX with <hpId> == -1 unbinds the current 3745bd8deadSopenharmony_ci rendering context from the hyperpipe. If no hyperpipe is bound, this 3755bd8deadSopenharmony_ci call is ignored and no error is generated. 3765bd8deadSopenharmony_ci 3775bd8deadSopenharmony_ci A process can bind to only one hyperpipe at any time. In order to 3785bd8deadSopenharmony_ci bind to another hyperpipe, the process must explicitly unbind from 3795bd8deadSopenharmony_ci the current hyperpipe. If a process calls glXBindHyperpipeSGIX() 3805bd8deadSopenharmony_ci more than once without an intervening unbind, then the subsequent 3815bd8deadSopenharmony_ci bind will fail. 3825bd8deadSopenharmony_ci 3835bd8deadSopenharmony_ci glXBindHyperpipeSGIX returns GLX_BAD_HYPERPIPE_SGIX if <hpId> is not 3845bd8deadSopenharmony_ci a valid hyperpipe ID. 3855bd8deadSopenharmony_ci 3865bd8deadSopenharmony_ci 3875bd8deadSopenharmony_ci To determine the best possible hyperpipe attributes subject to 3885bd8deadSopenharmony_ci constraints imposed by the hyperpipe implementation, call 3895bd8deadSopenharmony_ci 3905bd8deadSopenharmony_ci int glXQueryHyperpipeBestAttribSGIX(Display *dpy, 3915bd8deadSopenharmony_ci int timeSlice, int attrib, int size, void *attribList, 3925bd8deadSopenharmony_ci void *returnAttribList); 3935bd8deadSopenharmony_ci 3945bd8deadSopenharmony_ci <timeSlice> specifies the time slice for which <attrib> is queried. 3955bd8deadSopenharmony_ci Its value may range from 0 to the maximum number of time slices for 3965bd8deadSopenharmony_ci which the hyperpipe is configure. 3975bd8deadSopenharmony_ci 3985bd8deadSopenharmony_ci <attrib> is a bitmask specifying the type of the attribute for which 3995bd8deadSopenharmony_ci the best attributes are to be determined. 4005bd8deadSopenharmony_ci 4015bd8deadSopenharmony_ci <size> specifies the total size, in bytes, of the arrays pointed to 4025bd8deadSopenharmony_ci by <attribList> and <returnAttribList>. 4035bd8deadSopenharmony_ci 4045bd8deadSopenharmony_ci <attribList> is a pointer to an array of requested values. The array 4055bd8deadSopenharmony_ci contains one value, of type determined by <attrib>, for each pipe 4065bd8deadSopenharmony_ci contributing to the specified time slice. 4075bd8deadSopenharmony_ci 4085bd8deadSopenharmony_ci <returnAttribList> is a pointer to an array in which returned values 4095bd8deadSopenharmony_ci are copied. The array must be large enough to contain one value, of 4105bd8deadSopenharmony_ci type determined by <attrib>, for each pipe contributing to the 4115bd8deadSopenharmony_ci specified time slice (in other words, must be the same size as the 4125bd8deadSopenharmony_ci array pointed to by <attribList>). Values returned will be as close 4135bd8deadSopenharmony_ci as possible to those specified in <attribList>, subject to the 4145bd8deadSopenharmony_ci implementation constraints. 4155bd8deadSopenharmony_ci 4165bd8deadSopenharmony_ci If <attrib> is GLX_PIPE_RECT, the subrectangles composing a 4175bd8deadSopenharmony_ci hyperpipe rectangle during <timeSlice> are queried. <attribList> 4185bd8deadSopenharmony_ci must point to an array of <n> GLXPipeRect structures, one for each 4195bd8deadSopenharmony_ci pipe contributing to the specified <timeSlice> of the currently 4205bd8deadSopenharmony_ci bound hyperpipe, each defining an input source rectangle (origin, 4215bd8deadSopenharmony_ci width, and height in the managed area), and an output destination 4225bd8deadSopenharmony_ci rectangle (origin, width, and height in the output display area). In 4235bd8deadSopenharmony_ci this case <size> must be <n> * sizeof(GLXPipeRect). 4245bd8deadSopenharmony_ci 4255bd8deadSopenharmony_ci If <attrib> is GLX_PIPE_RECT_LIMITS, the maximum size of the 4265bd8deadSopenharmony_ci subrectangles during <timeSlice> are queried. <attribList> must 4275bd8deadSopenharmony_ci point to an array of <n> GLXPipeRectLimits structures, each defining 4285bd8deadSopenharmony_ci an origin and maximum width and height in the managed area. In this 4295bd8deadSopenharmony_ci case <size> must be <n> * sizeof(GLXPipeRectLimits), where <n> is 4305bd8deadSopenharmony_ci the number of pipes participating in <timeSlice>. 4315bd8deadSopenharmony_ci 4325bd8deadSopenharmony_ci glXQueryHyperpipeBestAttribSGIX returns GLX_BAD_HYPERPIPE_SGIX if 4335bd8deadSopenharmony_ci there is no valid hyperpipe configuration bound to the current 4345bd8deadSopenharmony_ci context, or if <size> is too small for the amount of data 4355bd8deadSopenharmony_ci implied by <timeSlice> and <attrib>. 4365bd8deadSopenharmony_ci 4375bd8deadSopenharmony_ci glXQueryHypepipeBestAttribSGIX returns GLX_BAD_VALUE if <attrib> is 4385bd8deadSopenharmony_ci not one of GLX_PIPE_RECT or GLX_PIPE_RECT_LIMITS, or if any of the 4395bd8deadSopenharmony_ci elements in <attribList> cannot be altered to satisfy the 4405bd8deadSopenharmony_ci constraints of the current hyperpipe. 4415bd8deadSopenharmony_ci 4425bd8deadSopenharmony_ci 4435bd8deadSopenharmony_ci 4445bd8deadSopenharmony_ci Section 3.X.3 "Hyperpipe Attributes" 4455bd8deadSopenharmony_ci 4465bd8deadSopenharmony_ci To set hyperpipe attribute values, call 4475bd8deadSopenharmony_ci 4485bd8deadSopenharmony_ci int glXHyperpipeAttribSGIX(Display *dpy, int timeSlice, 4495bd8deadSopenharmony_ci int attrib, int size, void *attribList); 4505bd8deadSopenharmony_ci 4515bd8deadSopenharmony_ci <timeSlice>, <attrib>, and <size> have the same meaning as the 4525bd8deadSopenharmony_ci corresponding attributes of glXQueryHyperpipeBestAttribSGIX. 4535bd8deadSopenharmony_ci 4545bd8deadSopenharmony_ci If <attrib> is GLX_PIPE_RECT_SGIX, <attribList> must point to an 4555bd8deadSopenharmony_ci array of <n> subrectangles defined by GLXPipeRect structures, one for 4565bd8deadSopenharmony_ci each pipe contributing to the specified <timeSlice> of the currently 4575bd8deadSopenharmony_ci bound hyperpipe. This allows load balancing the pipes. In this case 4585bd8deadSopenharmony_ci <size> must be <n> * sizeof(GLXPipeRect). 4595bd8deadSopenharmony_ci 4605bd8deadSopenharmony_ci If <attrib> is GLX_HYPERPIPE_STEREO_SGIX, <attribList> must point to 4615bd8deadSopenharmony_ci an integer controlling alternation between pipes in the hyerpipe. 4625bd8deadSopenharmony_ci One pipe provides the left eye data, and the second provides the 4635bd8deadSopenharmony_ci right eye data. An attribute value of 1 enables stereo for the 4645bd8deadSopenharmony_ci corresponding pipe, and an attribute value of 0 disables stereo. In 4655bd8deadSopenharmony_ci this case <size> = sizeof(int). 4665bd8deadSopenharmony_ci 4675bd8deadSopenharmony_ci If <attrib> is GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX, <attribList> must 4685bd8deadSopenharmony_ci point to an integer controlling averaging of pixel data. An 4695bd8deadSopenharmony_ci attribute value of 1 enables an averaging mode in which 4705bd8deadSopenharmony_ci corresponding pixel values from all pipes in the hyperpipe are 4715bd8deadSopenharmony_ci averaged together before being sent to the display, and an attribute 4725bd8deadSopenharmony_ci value of 0 disables averaging. In this case <size> = sizeof(int). 4735bd8deadSopenharmony_ci 4745bd8deadSopenharmony_ci glXHyperpipeAttribSGIX is swap synchronous; that is, the attributes 4755bd8deadSopenharmony_ci are not changed until glXSwapBuffers is called for the corresponding 4765bd8deadSopenharmony_ci window. 4775bd8deadSopenharmony_ci 4785bd8deadSopenharmony_ci glXHyperpipeAttribSGIX returns GLX_BAD_HYPERPIPE_SGIX if there is no 4795bd8deadSopenharmony_ci valid hyperpipe configuration bound to the current context, or if 4805bd8deadSopenharmony_ci <size> is too small for the amount of data implied by <timeSlice> 4815bd8deadSopenharmony_ci and <attrib>. 4825bd8deadSopenharmony_ci 4835bd8deadSopenharmony_ci glXHypepipeAttribSGIX returns GLX_BAD_VALUE if <attrib> is not one 4845bd8deadSopenharmony_ci of GLX_PIPE_RECT_SGIX, GLX_HYPERPIPE_STEREO_SGIX, or 4855bd8deadSopenharmony_ci GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX. 4865bd8deadSopenharmony_ci 4875bd8deadSopenharmony_ci 4885bd8deadSopenharmony_ci To query hyperpipe attribute values, call 4895bd8deadSopenharmony_ci 4905bd8deadSopenharmony_ci int glXQueryHyperpipeAttribSGIX(Display *dpy, int timeSlice, 4915bd8deadSopenharmony_ci int attrib, int size, void *returnAttribList); 4925bd8deadSopenharmony_ci 4935bd8deadSopenharmony_ci <timeSlice>, <attrib>, and <size> have the same meaning as the 4945bd8deadSopenharmony_ci corresponding attributes of glXHyperpipeAttribSGIX. 4955bd8deadSopenharmony_ci 4965bd8deadSopenharmony_ci If <attrib> is GLX_PIPE_RECT_SGIX, <attribList> must point to an 4975bd8deadSopenharmony_ci array of <n> GLXPipeRect structures, one for each pipe contributing 4985bd8deadSopenharmony_ci to the specified <timeSlice> of the currently bound hyperpipe. The 4995bd8deadSopenharmony_ci subrectangles corresponding to each pipe are returned in 5005bd8deadSopenharmony_ci <attribList>. In this case <size> must be <n> * sizeof(GLXPipeRect). 5015bd8deadSopenharmony_ci 5025bd8deadSopenharmony_ci If <attrib> is GLX_PIPE_RECT_LIMITS_SGIX, <attribList> must point to 5035bd8deadSopenharmony_ci an array of <n> GLXPipeRectLimits structures, one for each pipe 5045bd8deadSopenharmony_ci contributing to the specified <timeSlice> of the currently bound 5055bd8deadSopenharmony_ci hyperpipe. The maximum width and height of the subrectangles 5065bd8deadSopenharmony_ci corresponding to each pipe are returned in <attribList>. In this 5075bd8deadSopenharmony_ci case <size> must be <n> * sizeof(GLXPipeRectLimits). 5085bd8deadSopenharmony_ci 5095bd8deadSopenharmony_ci If <attrib> is GLX_HYPERPIPE_STEREO_SGIX, <attribList> must point to 5105bd8deadSopenharmony_ci an integer. A return value of 1 indicates that stereo is enabled 5115bd8deadSopenharmony_ci while a return value of 0 indicates that stereo is disabled. In this 5125bd8deadSopenharmony_ci case <size> = sizeof(int). 5135bd8deadSopenharmony_ci 5145bd8deadSopenharmony_ci If <attrib> is GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX, <attribList> must 5155bd8deadSopenharmony_ci point to an integer. A return value of 1 indicates that pixel 5165bd8deadSopenharmony_ci averaging is enabled, while a return value of 0 indicates that pixel 5175bd8deadSopenharmony_ci averaging is disabled. In this case <size> = sizeof(int). 5185bd8deadSopenharmony_ci 5195bd8deadSopenharmony_ci glXQueryHyperpipeAttribSGIX returns GLX_BAD_HYPERPIPE_SGIX if there 5205bd8deadSopenharmony_ci is no valid hyperpipe configuration bound to the current context, or 5215bd8deadSopenharmony_ci if <size> is too small for the amount of data implied by <timeSlice> 5225bd8deadSopenharmony_ci and <attrib>. 5235bd8deadSopenharmony_ci 5245bd8deadSopenharmony_ci glXQueryHypepipeAttribSGIX returns GLX_BAD_VALUE if <attrib> is not 5255bd8deadSopenharmony_ci one of GLX_PIPE_RECT_SGIX, GLX_PIPE_RECT_LIMITS_SGIX, 5265bd8deadSopenharmony_ci GLX_HYPERPIPE_STEREO_SGIX, or GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX. 5275bd8deadSopenharmony_ci 5285bd8deadSopenharmony_ci 5295bd8deadSopenharmony_ci 5305bd8deadSopenharmony_ci Add to section 3.2.6, Double Buffering: 5315bd8deadSopenharmony_ci 5325bd8deadSopenharmony_ci When a hyperpipe is bound to the current context, all pipes 5335bd8deadSopenharmony_ci participating in a single time slice will swap together. 5345bd8deadSopenharmony_ci glXSwapBuffers may be called even for a single-buffered visual when 5355bd8deadSopenharmony_ci a hyperpipe is bound, to cause the hyperpipe to switch to the next 5365bd8deadSopenharmony_ci time slice. 5375bd8deadSopenharmony_ci 5385bd8deadSopenharmony_ci When a pipe in a hyperpipe configuration completes rendering of its 5395bd8deadSopenharmony_ci portion of the framebuffer, completion is indicated by via a call to 5405bd8deadSopenharmony_ci glXSwapBuffers. After all the pipes contributing to a particular 5415bd8deadSopenharmony_ci time slice indicate completion, the hyperpipe requests for this time 5425bd8deadSopenharmony_ci slice may begin. 5435bd8deadSopenharmony_ci 5445bd8deadSopenharmony_ci 5455bd8deadSopenharmony_ci [Add to table listing GLX context attributes for glXQueryContextInfoEXT] 5465bd8deadSopenharmony_ci 5475bd8deadSopenharmony_ci GLX context attribute type context information 5485bd8deadSopenharmony_ci --------------------- ---- ------------------- 5495bd8deadSopenharmony_ci GLX_HYPERPIPE_ID_SGIX XID hyperpipe id, if the rendering context 5505bd8deadSopenharmony_ci is associated with a hyperpipe 5515bd8deadSopenharmony_ci 5525bd8deadSopenharmony_ci 5535bd8deadSopenharmony_ciErrors 5545bd8deadSopenharmony_ci 5555bd8deadSopenharmony_ci Errors specific to hyperpipes are defined in the specification 5565bd8deadSopenharmony_ci language. GLX_BAD_CONTEXT may be returned by any hyperpipe call if 5575bd8deadSopenharmony_ci there is no valid current context. 5585bd8deadSopenharmony_ci 5595bd8deadSopenharmony_ci 5605bd8deadSopenharmony_ciImplementation Notes 5615bd8deadSopenharmony_ci 5625bd8deadSopenharmony_ci glXQueryHyperpipeBestAttribSGIX and glXHyperpipeAttribSGIX are 5635bd8deadSopenharmony_ci currently supported only on InfinitePerformance systems. 5645bd8deadSopenharmony_ci 5655bd8deadSopenharmony_ci On InfinitePerformance systems, GLX_PIPE_RECT_SGIX requires that X 5665bd8deadSopenharmony_ci origins and sizes be aligned on 4 pixel boundaries. 5675bd8deadSopenharmony_ci 5685bd8deadSopenharmony_ci 5695bd8deadSopenharmony_ci The hyperpipe context ensures that resize parameters may be 5705bd8deadSopenharmony_ci synchronized across a hyperpipe. The details of this synchronization 5715bd8deadSopenharmony_ci are system-dependent, and may for example use the /dev/gfx device on 5725bd8deadSopenharmony_ci SGI IRIX systems. 5735bd8deadSopenharmony_ci 5745bd8deadSopenharmony_ci 5755bd8deadSopenharmony_ci In SGI implementations using external compositors (e.g. SG2), the 5765bd8deadSopenharmony_ci distinction between display and render pipes in the 5775bd8deadSopenharmony_ci <participationType> bitfield is ignored. In principle both bits 5785bd8deadSopenharmony_ci could be set for a single pipe, but no implementations in which this 5795bd8deadSopenharmony_ci mode is supported, or makes sense, have yet been developed. 5805bd8deadSopenharmony_ci 5815bd8deadSopenharmony_ci 5825bd8deadSopenharmony_ci In SGI implementations, the pixel averaging mode controlled by 5835bd8deadSopenharmony_ci GLX_HYPERPIPE_PIXEL_AVERAGE_SGIX is meant to be used for full-screen 5845bd8deadSopenharmony_ci antialiasing, with each pipe in a time slice contributing jittered 5855bd8deadSopenharmony_ci samples for each pixel in the output image. 5865bd8deadSopenharmony_ci 5875bd8deadSopenharmony_ci 5885bd8deadSopenharmony_ci The SGI implementation uses an internal constant 5895bd8deadSopenharmony_ci GLX_HYPERPIPE_PIPE_NPIPES_SGIX = 32. This token is not exposed in 5905bd8deadSopenharmony_ci the external API, and has not been placed in the public glxext.h 5915bd8deadSopenharmony_ci header file. 5925bd8deadSopenharmony_ci 5935bd8deadSopenharmony_ciRevision History 5945bd8deadSopenharmony_ci 5955bd8deadSopenharmony_ci Revision 14, 2004/07/22 - closed out some open issues based on the 5965bd8deadSopenharmony_ci SGI implementation details. 5975bd8deadSopenharmony_ci 5985bd8deadSopenharmony_ci Revision 13, 2004/07/21 - completely rewrote specification based on 5995bd8deadSopenharmony_ci the IRIX man pages. This should be substantially more complete than 6005bd8deadSopenharmony_ci the previous (1999) revision, and better correspond to what's 6015bd8deadSopenharmony_ci actually being shipped. 602