15bd8deadSopenharmony_ciName 25bd8deadSopenharmony_ci 35bd8deadSopenharmony_ci ATI_render_texture_rectangle 45bd8deadSopenharmony_ci 55bd8deadSopenharmony_ciName Strings 65bd8deadSopenharmony_ci 75bd8deadSopenharmony_ci WGL_ATI_render_texture_rectangle 85bd8deadSopenharmony_ci 95bd8deadSopenharmony_ciContact 105bd8deadSopenharmony_ci 115bd8deadSopenharmony_ci Rob Mace, ATI Research (mace 'at' ati.com) 125bd8deadSopenharmony_ci 135bd8deadSopenharmony_ciStatus 145bd8deadSopenharmony_ci 155bd8deadSopenharmony_ci Complete. 165bd8deadSopenharmony_ci 175bd8deadSopenharmony_ciVersion 185bd8deadSopenharmony_ci 195bd8deadSopenharmony_ci Last Modified Date: September 27, 2018 205bd8deadSopenharmony_ci Revision: 3 215bd8deadSopenharmony_ci 225bd8deadSopenharmony_ciNumber 235bd8deadSopenharmony_ci 245bd8deadSopenharmony_ci OpenGL Extension #532 255bd8deadSopenharmony_ci 265bd8deadSopenharmony_ciDependencies 275bd8deadSopenharmony_ci 285bd8deadSopenharmony_ci OpenGL 1.1 is required. 295bd8deadSopenharmony_ci WGL_ARB_render_texture is required. 305bd8deadSopenharmony_ci GL_ARB_texture_rectangle or GL_EXT_texture_rectangle is required. 315bd8deadSopenharmony_ci 325bd8deadSopenharmony_ci The extension is written against the OpenGL 1.5 Specification 335bd8deadSopenharmony_ci and the WGL_ARB_render_texture 7/16/01 Specification. 345bd8deadSopenharmony_ci 355bd8deadSopenharmony_ciOverview 365bd8deadSopenharmony_ci 375bd8deadSopenharmony_ci This extension builds upon WGL_ARB_render_texture and allows a 385bd8deadSopenharmony_ci pbuffer to be bound to a texture rectangle target. 395bd8deadSopenharmony_ci 405bd8deadSopenharmony_ci 415bd8deadSopenharmony_ciIssues 425bd8deadSopenharmony_ci 435bd8deadSopenharmony_ci 1. Are separate BIND_TO_TEXTURE_RECTANGLE enums needed, or are the 445bd8deadSopenharmony_ci BIND_TO_TEXTURE enums defined in WGL_ARB_render_texture 455bd8deadSopenharmony_ci sufficient? 465bd8deadSopenharmony_ci 475bd8deadSopenharmony_ci RESOLUTION: The BIND_TO_TEXTURE enums defined in 485bd8deadSopenharmony_ci WGL_ARB_render_texture are sufficient. WGL_ARB_render_texture 495bd8deadSopenharmony_ci does not have BIND_TO_TEXTURE_2D, BIND_TO_TEXTURE_CUBE_MAP, etc. 505bd8deadSopenharmony_ci enums. It just has the BIND_TO_TEXTURE enums. 515bd8deadSopenharmony_ci 525bd8deadSopenharmony_ci 535bd8deadSopenharmony_ciNew Procedures and Functions 545bd8deadSopenharmony_ci 555bd8deadSopenharmony_ci None 565bd8deadSopenharmony_ci 575bd8deadSopenharmony_ci 585bd8deadSopenharmony_ciNew Tokens 595bd8deadSopenharmony_ci 605bd8deadSopenharmony_ci Accepted as a value in the <piAttribList> parameter of 615bd8deadSopenharmony_ci wglCreatePbufferARB and returned in the value parameter of 625bd8deadSopenharmony_ci wglQueryPbufferARB when <iAttribute> is WGL_TEXTURE_TARGET_ARB: 635bd8deadSopenharmony_ci 645bd8deadSopenharmony_ci WGL_TEXTURE_RECTANGLE_ATI 0x21A5 655bd8deadSopenharmony_ci 665bd8deadSopenharmony_ci 675bd8deadSopenharmony_ciAdditions to Chapter 2 of the OpenGL 1.5 Specification (OpenGL 685bd8deadSopenharmony_ciOperation) 695bd8deadSopenharmony_ci 705bd8deadSopenharmony_ci None 715bd8deadSopenharmony_ci 725bd8deadSopenharmony_ci 735bd8deadSopenharmony_ciAdditions to Chapter 3 of the OpenGL 1.5 Specification (Rasterization) 745bd8deadSopenharmony_ci 755bd8deadSopenharmony_ci None 765bd8deadSopenharmony_ci 775bd8deadSopenharmony_ci 785bd8deadSopenharmony_ciAdditions to Chapter 4 of the OpenGL 1.5 Specification (Per-Fragment 795bd8deadSopenharmony_ciOperations and the Frame Buffer) 805bd8deadSopenharmony_ci 815bd8deadSopenharmony_ci None 825bd8deadSopenharmony_ci 835bd8deadSopenharmony_ci 845bd8deadSopenharmony_ciAdditions to Chapter 5 of the OpenGL 1.5 Specification (Special 855bd8deadSopenharmony_ciFunctions) 865bd8deadSopenharmony_ci 875bd8deadSopenharmony_ci None 885bd8deadSopenharmony_ci 895bd8deadSopenharmony_ci 905bd8deadSopenharmony_ciAdditions to Chapter 6 of the OpenGL 1.5 Specification (State and 915bd8deadSopenharmony_ciState Requests) 925bd8deadSopenharmony_ci 935bd8deadSopenharmony_ci None 945bd8deadSopenharmony_ci 955bd8deadSopenharmony_ci 965bd8deadSopenharmony_ciAdditions to the WGL Specification 975bd8deadSopenharmony_ci 985bd8deadSopenharmony_ci Modify wglCreatePbufferARB: 995bd8deadSopenharmony_ci 1005bd8deadSopenharmony_ci HPBUFFERARB wglCreatePbufferARB (HDC hDC, int iPixelFormat, 1015bd8deadSopenharmony_ci int iWidth, int iHeight, const int *piAttribList); 1025bd8deadSopenharmony_ci 1035bd8deadSopenharmony_ci ... 1045bd8deadSopenharmony_ci 1055bd8deadSopenharmony_ci WGL_TEXTURE_TARGET_ARB 1065bd8deadSopenharmony_ci 1075bd8deadSopenharmony_ci This attribute indicates the target for the texture that will be 1085bd8deadSopenharmony_ci created when the pbuffer is created with a texture format of 1095bd8deadSopenharmony_ci WGL_TEXTURE_RGB_ARB or WGL_TEXTURE_RGBA_ARB. This attribute can 1105bd8deadSopenharmony_ci be set to WGL_NO_TEXTURE_ARB, WGL_TEXTURE_1D_ARB, 1115bd8deadSopenharmony_ci WGL_TEXTURE_2D_ARB, WGL_TEXTURE_CUBE_MAP_ARB, or 1125bd8deadSopenharmony_ci WGL_TEXTURE_RECTANGLE_ATI. The default value is 1135bd8deadSopenharmony_ci WGL_NO_TEXTURE_ARB. 1145bd8deadSopenharmony_ci 1155bd8deadSopenharmony_ci ... 1165bd8deadSopenharmony_ci 1175bd8deadSopenharmony_ci WGL_PBUFFER_LARGEST_ARB 1185bd8deadSopenharmony_ci 1195bd8deadSopenharmony_ci If this attribute is set to a non-zero value, the largest 1205bd8deadSopenharmony_ci available pbuffer is allocated when the allocation of the 1215bd8deadSopenharmony_ci pbuffer would otherwise fail due to insufficient resources. The 1225bd8deadSopenharmony_ci width or height of the allocated pbuffer never exceeds <iWidth> 1235bd8deadSopenharmony_ci and <iHeight>, respectively. Also, if the pbuffer will be used 1245bd8deadSopenharmony_ci as a texture (i.e., the value of the WGL_TEXTURE_TARGET_ARB 1255bd8deadSopenharmony_ci attribute is WGL_TEXTURE_1D_ARB, WGL_TEXTURE_2D_ARB, 1265bd8deadSopenharmony_ci WGL_TEXTURE_CUBE_MAP_ARB, or WGL_TEXTURE_RECTANGLE_ATI and 1275bd8deadSopenharmony_ci texture format is WGL_TEXTURE_RGB_ARB or WGL_TEXTURE_RGBA_ARB), 1285bd8deadSopenharmony_ci then the aspect ratio will be preserved and the new width and 1295bd8deadSopenharmony_ci height will be valid sizes for the corresponding texture target. 1305bd8deadSopenharmony_ci (e.g. Both the width and height will be a power of 2 if the 1315bd8deadSopenharmony_ci implementation only supports power of 2 textures. Similarly, 1325bd8deadSopenharmony_ci the width and height will be equal for a cube map texture). Use 1335bd8deadSopenharmony_ci wglQueryPbufferARB to retrieve the dimensions of the allocated 1345bd8deadSopenharmony_ci pbuffer. The default value for this attribute is FALSE. 1355bd8deadSopenharmony_ci 1365bd8deadSopenharmony_ci ... 1375bd8deadSopenharmony_ci 1385bd8deadSopenharmony_ci ERROR_INVALID_DATA The pixel format attribute 1395bd8deadSopenharmony_ci WGL_TEXTURE_FORMAT_ARB is 1405bd8deadSopenharmony_ci WGL_TEXTURE_RGB_ARB or 1415bd8deadSopenharmony_ci WGL_TEXTURE_RGBA_ARB 1425bd8deadSopenharmony_ci and WGL_PBUFFER_WIDTH and/or 1435bd8deadSopenharmony_ci WGL_PBUFFER_HEIGHT specify an 1445bd8deadSopenharmony_ci invalid size for the implementation 1455bd8deadSopenharmony_ci (e.g., the texture size is not a 1465bd8deadSopenharmony_ci power of 2 and 1475bd8deadSopenharmony_ci WGL_TEXTURE_TARGET_ARB is 1485bd8deadSopenharmony_ci WGL_TEXTURE_1D_ARB, 1495bd8deadSopenharmony_ci WGL_TEXTURE_2D_ARB, or 1505bd8deadSopenharmony_ci WGL_TEXTURE_CUBE_MAP_ARB). 1515bd8deadSopenharmony_ci 1525bd8deadSopenharmony_ci ERROR_INVALID_DATA WGL_TEXTURE_TARGET_ARB is 1535bd8deadSopenharmony_ci WGL_TEXTURE_RECTANGLE_ATI 1545bd8deadSopenharmony_ci and WGL_MIPMAP_TEXTURE_ARB is 1555bd8deadSopenharmony_ci non-zero. 1565bd8deadSopenharmony_ci 1575bd8deadSopenharmony_ci .... 1585bd8deadSopenharmony_ci 1595bd8deadSopenharmony_ci Modify wglBindTexImageARB 1605bd8deadSopenharmony_ci 1615bd8deadSopenharmony_ci The command 1625bd8deadSopenharmony_ci 1635bd8deadSopenharmony_ci BOOL wglBindTexImageARB (HPBUFFERARB hPbuffer, int iBuffer) 1645bd8deadSopenharmony_ci 1655bd8deadSopenharmony_ci defines a one-dimensional texture image, two-dimensional 1665bd8deadSopenharmony_ci texture image, rectangle texture image, or a set of 1675bd8deadSopenharmony_ci two-dimensional cube map texture images. The texture image or 1685bd8deadSopenharmony_ci images consist of the image data in <iBuffer> for the specified 1695bd8deadSopenharmony_ci pbuffer, <hPbuffer>, and need not be copied. The texture 1705bd8deadSopenharmony_ci target, the texture format and the size of the texture 1715bd8deadSopenharmony_ci components are derived from attributes of pbuffer specified by 1725bd8deadSopenharmony_ci <hPbuffer>. 1735bd8deadSopenharmony_ci 1745bd8deadSopenharmony_ci ... 1755bd8deadSopenharmony_ci 1765bd8deadSopenharmony_ci The texture targets are derived from the WGL_TEXTURE_TARGET_ARB 1775bd8deadSopenharmony_ci attribute of <hPbuffer>. If the texture target for the pbuffer 1785bd8deadSopenharmony_ci is WGL_TEXTURE_CUBE_MAP_ARB then <iBuffer> defines a set of 1795bd8deadSopenharmony_ci cubemap images for the cube map texture objects which are bound 1805bd8deadSopenharmony_ci to the current context (hereafter referred to as the current 1815bd8deadSopenharmony_ci texture object). Note that when the texture target is 1825bd8deadSopenharmony_ci WGL_TEXTURE_CUBE_MAP_ARB, all cube map texture targets are 1835bd8deadSopenharmony_ci defined by a single call to wglBindTexImageARB. If the texture 1845bd8deadSopenharmony_ci target is WGL_TEXTURE_2D_ARB, then <iBuffer> defines a 2D 1855bd8deadSopenharmony_ci texture for the current 2D texture object. If the texture 1865bd8deadSopenharmony_ci target is WGL_TEXTURE_1D_ARB, then <iBuffer> defines a 1D 1875bd8deadSopenharmony_ci texture for the current 1D texture object. If the texture 1885bd8deadSopenharmony_ci target is WGL_TEXTURE_RECTANGLE_ATI, then <iBuffer> defines a 1895bd8deadSopenharmony_ci rectangle texture for the current rectangle texture object. 1905bd8deadSopenharmony_ci 1915bd8deadSopenharmony_ci .... 1925bd8deadSopenharmony_ci 1935bd8deadSopenharmony_ci 1945bd8deadSopenharmony_ciErrors 1955bd8deadSopenharmony_ci 1965bd8deadSopenharmony_ci None 1975bd8deadSopenharmony_ci 1985bd8deadSopenharmony_ci 1995bd8deadSopenharmony_ciNew State 2005bd8deadSopenharmony_ci 2015bd8deadSopenharmony_ci None 2025bd8deadSopenharmony_ci 2035bd8deadSopenharmony_ci 2045bd8deadSopenharmony_ciNew Implementation Dependent State 2055bd8deadSopenharmony_ci 2065bd8deadSopenharmony_ci None 2075bd8deadSopenharmony_ci 2085bd8deadSopenharmony_ci 2095bd8deadSopenharmony_ciRevision History 2105bd8deadSopenharmony_ci 2115bd8deadSopenharmony_ci Date: 09/27/2018 2125bd8deadSopenharmony_ci Revision: 3 2135bd8deadSopenharmony_ci - Assigned extension number & registered the spec (see 2145bd8deadSopenharmony_ci github.com/KhronosGroup/OpenGL-Registry/issues/192) 2155bd8deadSopenharmony_ci - For reasons lost to history, the enum value 0x21A5 duplicates the 2165bd8deadSopenharmony_ci entirely unrelated WGL_GPU_NUM_PIPES_AMD. 2175bd8deadSopenharmony_ci - This will probably set the alltime record for the time between an 2185bd8deadSopenharmony_ci extension being created and being registered. 2195bd8deadSopenharmony_ci 2205bd8deadSopenharmony_ci Date: 10/11/2004 2215bd8deadSopenharmony_ci Revision: 2 2225bd8deadSopenharmony_ci - Minor cleanup. 2235bd8deadSopenharmony_ci - Changed status to Complete. 2245bd8deadSopenharmony_ci 2255bd8deadSopenharmony_ci Date: 8/16/2004 2265bd8deadSopenharmony_ci Revision: 1 2275bd8deadSopenharmony_ci - First draft. 228