15bd8deadSopenharmony_ciXXX - Not complete yet!!! 25bd8deadSopenharmony_ci 35bd8deadSopenharmony_ciName 45bd8deadSopenharmony_ci 55bd8deadSopenharmony_ci EXT_compiled_vertex_array 65bd8deadSopenharmony_ci 75bd8deadSopenharmony_ciName Strings 85bd8deadSopenharmony_ci 95bd8deadSopenharmony_ci GL_EXT_compiled_vertex_array 105bd8deadSopenharmony_ci 115bd8deadSopenharmony_ciVersion 125bd8deadSopenharmony_ci 135bd8deadSopenharmony_ci $Date: 1996/11/21 00:52:19 $ $Revision: 1.3 $ 145bd8deadSopenharmony_ci 155bd8deadSopenharmony_ciNumber 165bd8deadSopenharmony_ci 175bd8deadSopenharmony_ci 97 185bd8deadSopenharmony_ci 195bd8deadSopenharmony_ciDependencies 205bd8deadSopenharmony_ci 215bd8deadSopenharmony_ci None 225bd8deadSopenharmony_ci 235bd8deadSopenharmony_ciOverview 245bd8deadSopenharmony_ci 255bd8deadSopenharmony_ci This extension defines an interface which allows static vertex array 265bd8deadSopenharmony_ci data to be cached or pre-compiled for more efficient rendering. This 275bd8deadSopenharmony_ci is useful for implementations which can cache the transformed results 285bd8deadSopenharmony_ci of array data for reuse by several DrawArrays, ArrayElement, or 295bd8deadSopenharmony_ci DrawElements commands. It is also useful for implementations which 305bd8deadSopenharmony_ci can transfer array data to fast memory for more efficient processing. 315bd8deadSopenharmony_ci 325bd8deadSopenharmony_ci For example, rendering an M by N mesh of quadrilaterals can be 335bd8deadSopenharmony_ci accomplished by setting up vertex arrays containing all of the 345bd8deadSopenharmony_ci vertexes in the mesh and issuing M DrawElements commands each of 355bd8deadSopenharmony_ci which operate on 2 * N vertexes. Each DrawElements command after 365bd8deadSopenharmony_ci the first will share N vertexes with the preceding DrawElements 375bd8deadSopenharmony_ci command. If the vertex array data is locked while the DrawElements 385bd8deadSopenharmony_ci commands are executed, then OpenGL may be able to transform each 395bd8deadSopenharmony_ci of these shared vertexes just once. 405bd8deadSopenharmony_ci 415bd8deadSopenharmony_ciIssues 425bd8deadSopenharmony_ci 435bd8deadSopenharmony_ci * Is compiled_vertex_array the right name for this extension? 445bd8deadSopenharmony_ci 455bd8deadSopenharmony_ci * Should there be an implementation defined maximum number of array 465bd8deadSopenharmony_ci elements which can be locked at a time (i.e. MAX_LOCKED_ARRAY_SIZE)? 475bd8deadSopenharmony_ci 485bd8deadSopenharmony_ci Probably not, the lock request can always be ignored with no resulting 495bd8deadSopenharmony_ci change in functionality if there are insufficent resources, and allowing 505bd8deadSopenharmony_ci the GL to define this limit can make things difficult for applications. 515bd8deadSopenharmony_ci 525bd8deadSopenharmony_ci * Should there be any restrictions on what state can be changed while 535bd8deadSopenharmony_ci the vertex array data is locked? 545bd8deadSopenharmony_ci 555bd8deadSopenharmony_ci Probably not. The GL can check for state changes and invalidate 565bd8deadSopenharmony_ci any cached vertex state that may be affected. This is likely to 575bd8deadSopenharmony_ci cause a performance hit, so the preferred use will be to not change 585bd8deadSopenharmony_ci state while the vertex array data is locked. 595bd8deadSopenharmony_ci 605bd8deadSopenharmony_ciNew Procedures and Functions 615bd8deadSopenharmony_ci 625bd8deadSopenharmony_ci void LockArraysEXT (int first, sizei count) 635bd8deadSopenharmony_ci void UnlockArraysEXT (void) 645bd8deadSopenharmony_ci 655bd8deadSopenharmony_ciNew Tokens 665bd8deadSopenharmony_ci 675bd8deadSopenharmony_ci Accepted by the <pname> parameter of GetBooleanv, GetIntegerv, 685bd8deadSopenharmony_ci GetFloatv, and GetDoublev: 695bd8deadSopenharmony_ci 705bd8deadSopenharmony_ci ARRAY_ELEMENT_LOCK_FIRST_EXT 0x81A8 715bd8deadSopenharmony_ci ARRAY_ELEMENT_LOCK_COUNT_EXT 0x81A9 725bd8deadSopenharmony_ci 735bd8deadSopenharmony_ciAdditions to Chapter 2 of the 1.1 Specification (OpenGL Operation) 745bd8deadSopenharmony_ci 755bd8deadSopenharmony_ci After the discussion of InterleavedArrays, add a description of 765bd8deadSopenharmony_ci array compiling/locking. 775bd8deadSopenharmony_ci 785bd8deadSopenharmony_ci The currently enabled vertex arrays can be locked with the command 795bd8deadSopenharmony_ci LockArraysEXT. When the vertex arrays are locked, the GL 805bd8deadSopenharmony_ci can compile the array data or the transformed results of array 815bd8deadSopenharmony_ci data associated with the currently enabled vertex arrays. The 825bd8deadSopenharmony_ci vertex arrays are unlocked by the command UnlockArraysEXT. 835bd8deadSopenharmony_ci 845bd8deadSopenharmony_ci Between LockArraysEXT and UnlockArraysEXT the application 855bd8deadSopenharmony_ci should ensure that none of the array data in the range of 865bd8deadSopenharmony_ci elements specified by <first> and <count> are changed. 875bd8deadSopenharmony_ci Changes to the array data between the execution of LockArraysEXT 885bd8deadSopenharmony_ci and UnlockArraysEXT commands may affect calls may affect DrawArrays, 895bd8deadSopenharmony_ci ArrayElement, or DrawElements commands in non-sequential ways. 905bd8deadSopenharmony_ci 915bd8deadSopenharmony_ci While using a compiled vertex array, references to array elements 925bd8deadSopenharmony_ci by the commands DrawArrays, ArrayElement, or DrawElements which are 935bd8deadSopenharmony_ci outside of the range specified by <first> and <count> are undefined. 945bd8deadSopenharmony_ci 955bd8deadSopenharmony_ciAdditions to Chapter 3 of the 1.1 Specification (Rasterization) 965bd8deadSopenharmony_ci 975bd8deadSopenharmony_ci None 985bd8deadSopenharmony_ci 995bd8deadSopenharmony_ciAdditions to Chapter 4 of the 1.1 Specification (Per-Fragment Operations 1005bd8deadSopenharmony_ciand the Frame Buffer) 1015bd8deadSopenharmony_ci 1025bd8deadSopenharmony_ci None 1035bd8deadSopenharmony_ci 1045bd8deadSopenharmony_ciAdditions to Chapter 5 of the 1.1 Specification (Special Functions) 1055bd8deadSopenharmony_ci 1065bd8deadSopenharmony_ci LockArraysEXT and UnlockArraysEXT are not complied into display lists 1075bd8deadSopenharmony_ci but are executed immediately. 1085bd8deadSopenharmony_ci 1095bd8deadSopenharmony_ciAdditions to Chapter 6 of the 1.1 Specification (State and State Requests) 1105bd8deadSopenharmony_ci 1115bd8deadSopenharmony_ci None 1125bd8deadSopenharmony_ci 1135bd8deadSopenharmony_ciAdditions to the GLX Specification 1145bd8deadSopenharmony_ci 1155bd8deadSopenharmony_ci XXX - Not complete yet!!! 1165bd8deadSopenharmony_ci 1175bd8deadSopenharmony_ciGLX Protocol 1185bd8deadSopenharmony_ci 1195bd8deadSopenharmony_ci XXX - Not complete yet!!! 1205bd8deadSopenharmony_ci 1215bd8deadSopenharmony_ciErrors 1225bd8deadSopenharmony_ci 1235bd8deadSopenharmony_ci INVALID_VALUE is generated if LockArrarysEXT parameter <first> is less 1245bd8deadSopenharmony_ci than zero. 1255bd8deadSopenharmony_ci 1265bd8deadSopenharmony_ci INVALID_VALUE is generated if LockArraysEXT parameter <count> is less than 1275bd8deadSopenharmony_ci or equal to zero. 1285bd8deadSopenharmony_ci 1295bd8deadSopenharmony_ci INVALID_OPERATION is generated if LockArraysEXT is called between execution 1305bd8deadSopenharmony_ci of LockArraysEXT and corresponding execution of UnlockArraysEXT. 1315bd8deadSopenharmony_ci 1325bd8deadSopenharmony_ci INVALID_OPERATION is generated if UnlockArraysEXT is called without a 1335bd8deadSopenharmony_ci corresponding previous execution of LockArraysEXT. 1345bd8deadSopenharmony_ci 1355bd8deadSopenharmony_ci INVALID_OPERATION is generated if LockArraysEXT or UnlockArraysEXT is called 1365bd8deadSopenharmony_ci between execution of Begin and the corresponding execution of End. 1375bd8deadSopenharmony_ci 1385bd8deadSopenharmony_ciNew State 1395bd8deadSopenharmony_ci Initial 1405bd8deadSopenharmony_ci Get Value Get Command Type Value Attrib 1415bd8deadSopenharmony_ci --------- ----------- ---- ------- ------ 1425bd8deadSopenharmony_ci 1435bd8deadSopenharmony_ci ARRAY_ELEMENT_LOCK_FIRST_EXT GetIntegerv Z+ 0 client-vertex-array 1445bd8deadSopenharmony_ci ARRAY_ELEMENT_LOCK_COUNT_EXT GetIntegerv Z+ 0 client-vertex-array 1455bd8deadSopenharmony_ci 1465bd8deadSopenharmony_ciNew Implementation Dependent State 1475bd8deadSopenharmony_ci 1485bd8deadSopenharmony_ci None 149