15bd8deadSopenharmony_ciName 25bd8deadSopenharmony_ci 35bd8deadSopenharmony_ci ARB_half_float_vertex 45bd8deadSopenharmony_ci 55bd8deadSopenharmony_ciName Strings 65bd8deadSopenharmony_ci 75bd8deadSopenharmony_ci GL_ARB_half_float_vertex 85bd8deadSopenharmony_ci 95bd8deadSopenharmony_ciContact 105bd8deadSopenharmony_ci 115bd8deadSopenharmony_ci Daniel Koch, TransGaming, Inc (daniel 'at' transgaming.com) 125bd8deadSopenharmony_ci 135bd8deadSopenharmony_ciNotice 145bd8deadSopenharmony_ci 155bd8deadSopenharmony_ci Copyright (c) 2008-2013 The Khronos Group Inc. Copyright terms at 165bd8deadSopenharmony_ci http://www.khronos.org/registry/speccopyright.html 175bd8deadSopenharmony_ci 185bd8deadSopenharmony_ciSpecification Update Policy 195bd8deadSopenharmony_ci 205bd8deadSopenharmony_ci Khronos-approved extension specifications are updated in response to 215bd8deadSopenharmony_ci issues and bugs prioritized by the Khronos OpenGL Working Group. For 225bd8deadSopenharmony_ci extensions which have been promoted to a core Specification, fixes will 235bd8deadSopenharmony_ci first appear in the latest version of that core Specification, and will 245bd8deadSopenharmony_ci eventually be backported to the extension document. This policy is 255bd8deadSopenharmony_ci described in more detail at 265bd8deadSopenharmony_ci https://www.khronos.org/registry/OpenGL/docs/update_policy.php 275bd8deadSopenharmony_ci 285bd8deadSopenharmony_ciStatus 295bd8deadSopenharmony_ci 305bd8deadSopenharmony_ci Approved by the ARB on July 11, 2008 315bd8deadSopenharmony_ci 325bd8deadSopenharmony_ciVersion 335bd8deadSopenharmony_ci 345bd8deadSopenharmony_ci Last Modified Date: August 7, 2008 355bd8deadSopenharmony_ci Version 5 365bd8deadSopenharmony_ci 375bd8deadSopenharmony_ciNumber 385bd8deadSopenharmony_ci 395bd8deadSopenharmony_ci ARB Extension #48 405bd8deadSopenharmony_ci 415bd8deadSopenharmony_ciDependencies 425bd8deadSopenharmony_ci 435bd8deadSopenharmony_ci This extension is written against the OpenGL 2.1 Specification 445bd8deadSopenharmony_ci 455bd8deadSopenharmony_ci Based on the NV_half_float and OES_vertex_half_float extensions. 465bd8deadSopenharmony_ci 475bd8deadSopenharmony_ciOverview 485bd8deadSopenharmony_ci 495bd8deadSopenharmony_ci This extension extends the usage of the half-precision (16-bit) floating- 505bd8deadSopenharmony_ci point quantities introduced in ARB_half_float_pixel for usage in specifying 515bd8deadSopenharmony_ci vertex array data. 525bd8deadSopenharmony_ci 535bd8deadSopenharmony_ci This extension allows applications to use half-precision floating point data 545bd8deadSopenharmony_ci when specifying vertices. This can allow applications to reduce their 555bd8deadSopenharmony_ci memory footprint, as well as the memory bandwidth required for vertex data. 565bd8deadSopenharmony_ci 575bd8deadSopenharmony_ci This extension extends the existing vertex array commands to accept the new 585bd8deadSopenharmony_ci data type. 595bd8deadSopenharmony_ci 605bd8deadSopenharmony_ci 615bd8deadSopenharmony_ciIssues 625bd8deadSopenharmony_ci 635bd8deadSopenharmony_ci 1. How is this extension different from NV_half_float or 645bd8deadSopenharmony_ci ARB_half_float_pixel? 655bd8deadSopenharmony_ci 665bd8deadSopenharmony_ci This extension adds the commands for specifying half-precision 675bd8deadSopenharmony_ci vertex data that were initially introduced in the NV_half_float 685bd8deadSopenharmony_ci extension but were specifically excluded from the 695bd8deadSopenharmony_ci ARB_half_float_pixel extension. The functionality added in this 705bd8deadSopenharmony_ci extension is a proper subset of the vertex functionality defined in 715bd8deadSopenharmony_ci the NV_half_float extension. 725bd8deadSopenharmony_ci 735bd8deadSopenharmony_ci 2. Should we provide immediate-mode entry points for half-precision 745bd8deadSopenharmony_ci vertex data? 755bd8deadSopenharmony_ci 765bd8deadSopenharmony_ci No. We expect the immediate-mode API to be deprecated in the near 775bd8deadSopenharmony_ci future and thus do not wish to encumber implementors with adding a 785bd8deadSopenharmony_ci significant number of additional entry points that would have 795bd8deadSopenharmony_ci limited usefulness. Additionaly, the half-precision floating point 805bd8deadSopenharmony_ci vertex data is only interesting when it is specified in array format 815bd8deadSopenharmony_ci (i.e., for saving storage space). If an application is using 825bd8deadSopenharmony_ci immediate mode APIs to load the vertex data, it does not seem overly 835bd8deadSopenharmony_ci onerous to require them to convert to one of the more standard data 845bd8deadSopenharmony_ci types. 855bd8deadSopenharmony_ci 865bd8deadSopenharmony_ci 3. What is the half-precision floating point format? 875bd8deadSopenharmony_ci 885bd8deadSopenharmony_ci This is the same 16-bit floating point format that is defined in 895bd8deadSopenharmony_ci Section 2.1.2 of the ARB_texture_float and ARB_half_float_pixel 905bd8deadSopenharmony_ci extensions. 915bd8deadSopenharmony_ci 925bd8deadSopenharmony_ci 4. How does this extension differ from OES_vertex_half_float? 935bd8deadSopenharmony_ci 945bd8deadSopenharmony_ci It is intended to have the same functionality, however there are a 955bd8deadSopenharmony_ci few minor changes spec-wise: 965bd8deadSopenharmony_ci 975bd8deadSopenharmony_ci a) this extension defines the additional GLX protocol, as was done 985bd8deadSopenharmony_ci in the NV_half_float extension. 995bd8deadSopenharmony_ci b) this extension uses the value of the HALF_FLOAT_ARB (0x140B) 1005bd8deadSopenharmony_ci token that is already defined in the desktop version of the 1015bd8deadSopenharmony_ci ARB_half_float_pixel extension (which is the same as the value 1025bd8deadSopenharmony_ci of the HALF_FLOAT_NV token from the NV_half_float extension). 1035bd8deadSopenharmony_ci The OES_vertex_half_float and OES_texture_half_float extensions 1045bd8deadSopenharmony_ci use the HALF_FLOAT_OES (0x8D61) token. 1055bd8deadSopenharmony_ci 1065bd8deadSopenharmony_ci The logical progression is to define this as an ARB extension which 1075bd8deadSopenharmony_ci is intended to supersede both the OES extension and the 1085bd8deadSopenharmony_ci functionality from NV_half_float. 1095bd8deadSopenharmony_ci 1105bd8deadSopenharmony_ci 5. Why don't the new tokens and entry points in this extension have 1115bd8deadSopenharmony_ci "ARB" suffixes like other ARB extensions? 1125bd8deadSopenharmony_ci 1135bd8deadSopenharmony_ci RESOLVED: Unlike a normal ARB extension, this is a strict subset of 1145bd8deadSopenharmony_ci functionality already approved in OpenGL 3.0. This extension exists 1155bd8deadSopenharmony_ci only to support that functionality on older hardware that cannot 1165bd8deadSopenharmony_ci implement a full OpenGL 3.0 driver. Since there are no possible 1175bd8deadSopenharmony_ci behavior changes between the ARB extension and core features, source 1185bd8deadSopenharmony_ci code compatibility is improved by not using suffixes on the 1195bd8deadSopenharmony_ci extension. 1205bd8deadSopenharmony_ci 1215bd8deadSopenharmony_ciNew Procedures and Functions 1225bd8deadSopenharmony_ci 1235bd8deadSopenharmony_ci None 1245bd8deadSopenharmony_ci 1255bd8deadSopenharmony_ciNew Tokens 1265bd8deadSopenharmony_ci 1275bd8deadSopenharmony_ci Accepted by the <type> argument of VertexPointer, NormalPointer, 1285bd8deadSopenharmony_ci ColorPointer, SecondaryColorPointer, FogCoordPointer, TexCoordPointer, 1295bd8deadSopenharmony_ci and VertexAttribPointer: 1305bd8deadSopenharmony_ci 1315bd8deadSopenharmony_ci HALF_FLOAT 0x140B 1325bd8deadSopenharmony_ci 1335bd8deadSopenharmony_ciAdditions to Chapter 2 of the OpenGL 2.1 Specification (OpenGL Operation) 1345bd8deadSopenharmony_ci 1355bd8deadSopenharmony_ci Modify Section 2.8, Vertex Arrays, p. 23 1365bd8deadSopenharmony_ci 1375bd8deadSopenharmony_ci (Modify 1st paragraph on p. 24) ... For <type>, the values BYTE, SHORT, 1385bd8deadSopenharmony_ci INT, FLOAT, HALF_FLOAT, and DOUBLE indicate types byte, short, int, 1395bd8deadSopenharmony_ci float, half, and double, respectively. ... 1405bd8deadSopenharmony_ci 1415bd8deadSopenharmony_ci (Modify Table 2.4, p. 25) 1425bd8deadSopenharmony_ci 1435bd8deadSopenharmony_ci Command Sizes Types 1445bd8deadSopenharmony_ci ------------------ ------- --------------------------------- 1455bd8deadSopenharmony_ci VertexPointer 2,3,4 short, int, float, half, double 1465bd8deadSopenharmony_ci NormalPointer 3 byte, short, int, float, half, 1475bd8deadSopenharmony_ci double 1485bd8deadSopenharmony_ci ColorPointer 3,4 byte, ubyte, short, ushort, int, 1495bd8deadSopenharmony_ci uint, float, half, double 1505bd8deadSopenharmony_ci SecondaryColorPointer 3 byte, ubyte, short, ushort, int, 1515bd8deadSopenharmony_ci uint, float, half, double 1525bd8deadSopenharmony_ci IndexPointer 1 ubyte, short, int, float, double 1535bd8deadSopenharmony_ci FogCoordPointer 1 float, half, double 1545bd8deadSopenharmony_ci TexCoordPointer 1,2,3,4 short, int, float, half, double 1555bd8deadSopenharmony_ci EdgeFlagPointer 1 boolean 1565bd8deadSopenharmony_ci VertexAttribPointer 1 byte, ubyte, short, ushort, int, 1575bd8deadSopenharmony_ci uint, float, half, double 1585bd8deadSopenharmony_ci 1595bd8deadSopenharmony_ci Table 2.4: Vertex array sizes (values per vertex) and data types. 1605bd8deadSopenharmony_ci 1615bd8deadSopenharmony_ci Modify Section 2.13, Colors and Coloring, p.44 1625bd8deadSopenharmony_ci 1635bd8deadSopenharmony_ci (Modify Table 2.6, p. 59) Add new row to the table: 1645bd8deadSopenharmony_ci 1655bd8deadSopenharmony_ci GL Type Conversion 1665bd8deadSopenharmony_ci ------- ---------- 1675bd8deadSopenharmony_ci half c 1685bd8deadSopenharmony_ci 1695bd8deadSopenharmony_ci 1705bd8deadSopenharmony_ciAdditions to Chapter 3 of the OpenGL 2.1 Specification (Rasterization) 1715bd8deadSopenharmony_ci 1725bd8deadSopenharmony_ci None. 1735bd8deadSopenharmony_ci 1745bd8deadSopenharmony_ci 1755bd8deadSopenharmony_ciAdditions to Chapter 4 of the OpenGL 2.1 Specification (Per-Fragment 1765bd8deadSopenharmony_ciOperations and the Framebuffer) 1775bd8deadSopenharmony_ci 1785bd8deadSopenharmony_ci None. 1795bd8deadSopenharmony_ci 1805bd8deadSopenharmony_ci 1815bd8deadSopenharmony_ciAdditions to Chapter 5 of the OpenGL 2.1 Specification (Special Functions) 1825bd8deadSopenharmony_ci 1835bd8deadSopenharmony_ci None. 1845bd8deadSopenharmony_ci 1855bd8deadSopenharmony_ciAdditions to Chapter 6 of the OpenGL 2.1 Specification (State and 1865bd8deadSopenharmony_ciState Requests) 1875bd8deadSopenharmony_ci 1885bd8deadSopenharmony_ci None. 1895bd8deadSopenharmony_ci 1905bd8deadSopenharmony_ciAdditions to the AGL/GLX/WGL Specifications 1915bd8deadSopenharmony_ci 1925bd8deadSopenharmony_ci None. 1935bd8deadSopenharmony_ci 1945bd8deadSopenharmony_ciGLX Protocol (Modification to the GLX 1.3 Protocol Encoding Specification) 1955bd8deadSopenharmony_ci 1965bd8deadSopenharmony_ci Add to Section 1.4 (p.2), Common Types 1975bd8deadSopenharmony_ci 1985bd8deadSopenharmony_ci FLOAT16 A 16-bit floating-point value in the format specified 1995bd8deadSopenharmony_ci in the ARB_half_float_pixel extension specification. 2005bd8deadSopenharmony_ci 2015bd8deadSopenharmony_ci Modify Section 2.3.4, GL Rendering Commands That May Be Large (p. 127) 2025bd8deadSopenharmony_ci 2035bd8deadSopenharmony_ci (Modify the ARRAY_INFO portion of the DrawArrays encoding (p.129) to 2045bd8deadSopenharmony_ci reflect the new data type supported by vertex arrays.) 2055bd8deadSopenharmony_ci 2065bd8deadSopenharmony_ci ARRAY_INFO 2075bd8deadSopenharmony_ci 2085bd8deadSopenharmony_ci 4 enum data type 2095bd8deadSopenharmony_ci 0x1400 i=1 BYTE 2105bd8deadSopenharmony_ci 0x1401 i=1 UNSIGNED_BYTE 2115bd8deadSopenharmony_ci 0x1402 i=2 SHORT 2125bd8deadSopenharmony_ci ... 2135bd8deadSopenharmony_ci 0x140B i=2 HALF_FLOAT 2145bd8deadSopenharmony_ci 4 INT32 j 2155bd8deadSopenharmony_ci 4 ENUM array type 2165bd8deadSopenharmony_ci ... 2175bd8deadSopenharmony_ci 2185bd8deadSopenharmony_ciErrors 2195bd8deadSopenharmony_ci 2205bd8deadSopenharmony_ci None 2215bd8deadSopenharmony_ci 2225bd8deadSopenharmony_ciNew State 2235bd8deadSopenharmony_ci 2245bd8deadSopenharmony_ci None 2255bd8deadSopenharmony_ci 2265bd8deadSopenharmony_ciNew Implementation Dependent State 2275bd8deadSopenharmony_ci 2285bd8deadSopenharmony_ci None 2295bd8deadSopenharmony_ci 2305bd8deadSopenharmony_ciRevision History 2315bd8deadSopenharmony_ci 2325bd8deadSopenharmony_ci Rev. Date Author Changes 2335bd8deadSopenharmony_ci ---- -------- --------- -------------------------------------------- 2345bd8deadSopenharmony_ci 1 1/22/08 dgkoch Initial version based on the NV_half_float 2355bd8deadSopenharmony_ci and ARB_half_float_pixel specification. Updated 2365bd8deadSopenharmony_ci to reference OpenGL 2.1 spec. 2375bd8deadSopenharmony_ci 2 1/22/08 dgkoch Made some grammatical clarifications. 2385bd8deadSopenharmony_ci 3 2/01/08 dgkoch Clarify dependencies and interactions with other 2395bd8deadSopenharmony_ci extensions. 2405bd8deadSopenharmony_ci 4 2/25/08 dgkoch Add issue #4. 2415bd8deadSopenharmony_ci 5 8/07/08 jleech Remove _ARB suffix. 2425bd8deadSopenharmony_ci 243