3 <ratified href="OES_vertex_array_object/">
4 <name>OES_vertex_array_object</name>
6 <a href="https://www.khronos.org/webgl/public-mailing-list/">WebGL working group</a> (public_webgl 'at' khronos.org)
9 <contributor>Members of the WebGL working group</contributor>
14 <core version="2.0" />
17 <mirrors href="http://www.khronos.org/registry/gles/extensions/OES/OES_vertex_array_object.txt" name="OES_vertex_array_object" />
19 <idl xml:space="preserve">
21 interface WebGLVertexArrayObjectOES : WebGLObject {
25 interface OES_vertex_array_object {
26 const GLenum VERTEX_ARRAY_BINDING_OES = 0x85B5;
28 WebGLVertexArrayObjectOES? createVertexArrayOES();
29 void deleteVertexArrayOES(WebGLVertexArrayObjectOES? arrayObject);
30 [WebGLHandlesContextLoss] GLboolean isVertexArrayOES(WebGLVertexArrayObjectOES? arrayObject);
31 void bindVertexArrayOES(WebGLVertexArrayObjectOES? arrayObject);
36 <function name="createVertexArrayOES" type="WebGLVertexArrayObjectOES?">
41 <function name="deleteVertexArrayOES" type="void">
42 <param name="arrayObject" type="WebGLVertexArrayObjectOES?"/>
47 <function name="isVertexArrayOES" type="GLboolean">
48 <param name="arrayObject" type="WebGLVertexArrayObjectOES?"/>
49 Returns false if the vertex array object's <a
50 href="../../specs/1.0/#webgl-object-invalidated-flag">invalidated
56 <function name="bindVertexArrayOES" type="void">
57 <param name="arrayObject" type="WebGLVertexArrayObjectOES?"/>
62 <p>The OES_vertex_array_object spec does not make it clear
63 what happens to buffers that are deleted when they are referenced
64 by vertex array objects. It is inferred that all buffers are
67 <p>Before OES_vertex_array_object there was no way to use a deleted
68 buffer in a single context as the spec states it would be unbound
69 from all bind points. After OES_vertex_array_object it is now
70 possible to use deleted buffers.
72 <p>Furthermore, the OpenGL ES 2.0 spec specifies that using a
73 deleted buffer has undefined results including possibly
74 corrupt rendering and generating GL errors. Undefined behavior
75 is unacceptable for WebGL.
79 <p>RESOLVED: Buffers should be reference counted when attached to
80 a vertex array object. This is consistent with the OpenGL ES 3.0
81 spec's implementation of Vertex Array Objects and matches the
82 behavior of other WebGL objects, such as textures that are attached
85 <p>This will require that most implementations do not call
86 glDeleteBuffer when the user calls deleteBuffer on the WebGL context.
87 Instead the implementation must wait for all references to be released
88 before calling glDeleteBuffer to prevent undefined behavior.
90 <p>If a buffer object is deleted while it is attached to the currently
91 bound vertex array object, then it is as if BindBuffer had been called,
92 with a buffer of 0, for each target to which this buffer was attached
93 in the currently bound vertex array object. In other words, this buffer
94 is first detached from all attachment points in the currently bound
95 vertex array object. Note that the buffer is specifically not detached
96 from any other vertex array object. Detaching the buffer from any other
97 vertex array objects is the responsibility of the application.
103 <revision date="2011/01/27">
104 <change>Initial revision.</change>
106 <revision date="2011/11/12">
107 <change>Demotion to draft.</change>
109 <revision date="2011/12/06">
110 <change>Added vendor-specific name strings for draft extension per discussion on WebGL mailing list.</change>
112 <revision date="2011/12/07">
113 <change>Renamed "Name Strings" section to "Alias Name Strings".</change>
114 <change>Sorted Revision History in ascending order.</change>
116 <revision date="2012/01/03">
117 <change>Removed webgl module per changes to Web IDL spec.</change>
119 <revision date="2012/09/24">
120 <change>Added resolution to deleted buffer issue</change>
122 <revision date="2012/10/16">
123 <change>Based on feedback on public_webgl, moved from draft to community approved, and removed aliases.</change>
125 <revision date="2013/05/08">
126 <change>Made WebGLVertexArrayObjectOES return values and arguments nullable on feedback from Benoit Jacob.</change>
128 <revision date="2013/05/14">
129 <change>Based on pull request from J Kenneth King, added WebGLHandlesContextLoss extended attribute to isVertexArrayOES and added markup for new functions.</change>
131 <revision date="2013/05/15">
132 <change>Ratified by Khronos Board of Promoters.</change>
134 <revision date="2014/07/15">
135 <change>Added NoInterfaceObject extended attribute to extension and WebGLVertexArrayObjectOES interface.</change>