Commit | Line | Data |
---|---|---|
7faf1d71 AW |
1 | <?xml version="1.0" encoding="UTF-8"?>\r |
2 | <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook MathML Module V1.1b1//EN"\r | |
3 | "http://www.oasis-open.org/docbook/xml/mathml/1.1CR1/dbmathml.dtd">\r | |
4 | <refentry id="glBindVertexBuffer">\r | |
5 | <refmeta>\r | |
6 | <refmetainfo>\r | |
7 | <copyright>\r | |
8 | <year>2012</year>\r | |
9 | <holder>Khronos Group</holder>\r | |
10 | </copyright>\r | |
11 | </refmetainfo>\r | |
12 | <refentrytitle>glBindVertexBuffer</refentrytitle>\r | |
13 | <manvolnum>3G</manvolnum>\r | |
14 | </refmeta>\r | |
15 | <refnamediv>\r | |
16 | <refname>glBindVertexBuffer</refname>\r | |
17 | <refpurpose>bind a buffer to a vertex buffer bind point</refpurpose>\r | |
18 | </refnamediv>\r | |
19 | <refsynopsisdiv><title>C Specification</title>\r | |
20 | <funcsynopsis>\r | |
21 | <funcprototype>\r | |
22 | <funcdef>void <function>glBindVertexBuffer</function></funcdef>\r | |
23 | <paramdef>GLuint <parameter>bindingindex</parameter></paramdef>\r | |
24 | <paramdef>GLuint <parameter>buffer</parameter></paramdef>\r | |
25 | <paramdef>GLintptr <parameter>offset</parameter></paramdef>\r | |
26 | <paramdef>GLintptr <parameter>stride</parameter></paramdef>\r | |
27 | </funcprototype>\r | |
28 | </funcsynopsis>\r | |
29 | </refsynopsisdiv>\r | |
30 | <refsect1 id="parameters"><title>Parameters</title>\r | |
31 | <variablelist>\r | |
32 | <varlistentry>\r | |
33 | <term><parameter>bindingindex</parameter></term>\r | |
34 | <listitem>\r | |
35 | <para>\r | |
36 | The index of the vertex buffer binding point to which to bind the buffer.\r | |
37 | </para>\r | |
38 | </listitem>\r | |
39 | </varlistentry>\r | |
40 | <varlistentry>\r | |
41 | <term><parameter>buffer</parameter></term>\r | |
42 | <listitem>\r | |
43 | <para>\r | |
44 | The name of an existing buffer to bind to the vertex buffer binding point.\r | |
45 | </para>\r | |
46 | </listitem>\r | |
47 | </varlistentry>\r | |
48 | <varlistentry>\r | |
49 | <term><parameter>offset</parameter></term>\r | |
50 | <listitem>\r | |
51 | <para>\r | |
52 | The offset of the first element of the buffer.\r | |
53 | </para>\r | |
54 | </listitem>\r | |
55 | </varlistentry>\r | |
56 | <varlistentry>\r | |
57 | <term><parameter>stride</parameter></term>\r | |
58 | <listitem>\r | |
59 | <para>\r | |
60 | The distance between elements within the buffer.\r | |
61 | </para>\r | |
62 | </listitem>\r | |
63 | </varlistentry>\r | |
64 | </variablelist>\r | |
65 | </refsect1>\r | |
66 | <refsect1 id="description"><title>Description</title>\r | |
67 | <para>\r | |
68 | <function>glBindVertexBuffer</function> binds the buffer named <parameter>buffer</parameter>\r | |
69 | to the vertex buffer binding point whose index is given by <parameter>bindingindex</parameter>.\r | |
70 | <parameter>offset</parameter> and <parameter>stride</parameter> specify the offset of the first\r | |
71 | element within the buffer and the distance between elements within the buffer, respectively, and\r | |
72 | are both measured in basic machine units. <parameter>bindingindex</parameter> must be less than\r | |
73 | the value of <constant>GL_MAX_VERTEX_ATTRIB_BINDINGS</constant>. <parameter>offset</parameter>\r | |
74 | and <parameter>stride</parameter> must be greater than or equal to zero. If <parameter>buffer</parameter>\r | |
75 | is zero, then any buffer currently bound to the specified binding point is unbound.\r | |
76 | </para>\r | |
77 | </refsect1>\r | |
78 | <refsect1 id="errors"><title>Errors</title>\r | |
79 | <para>\r | |
80 | <constant>GL_INVAILD_VALUE</constant> is generated if <parameter>bindingindex</parameter> is greater than\r | |
81 | or equal to the value of <constant>GL_MAX_VERTEX_ATTRIB_BINDINGS</constant>.\r | |
82 | </para>\r | |
83 | <para>\r | |
84 | <constant>GL_INVALID_VALUE</constant> is generated if <parameter>offset</parameter> or <parameter>stride</parameter>\r | |
85 | is less than zero.\r | |
86 | </para>\r | |
87 | <para>\r | |
88 | <constant>GL_INVALID_VALUE</constant> is generated if <parameter>buffer</parameter> is not the name of an\r | |
89 | existing buffer object.\r | |
90 | </para>\r | |
91 | <para>\r | |
92 | <constant>GL_INVALID_OPERATION</constant> is generated if no vertex array object is bound.\r | |
93 | </para>\r | |
94 | </refsect1>\r | |
95 | <refsect1 id="associatedgets"><title>Associated Gets</title>\r | |
96 | <para>\r | |
97 | <citerefentry><refentrytitle>glGet</refentrytitle></citerefentry> with argument <constant>GL_MAX_VERTEX_ATTRIB_BINDINGS</constant>.\r | |
98 | </para>\r | |
99 | </refsect1>\r | |
100 | <refsect1 id="seealso"><title>See Also</title>\r | |
101 | <para>\r | |
102 | <citerefentry><refentrytitle>glVertexAttribBinding</refentrytitle></citerefentry>,\r | |
103 | <citerefentry><refentrytitle>glVertexAttribFormat</refentrytitle></citerefentry>,\r | |
104 | <citerefentry><refentrytitle>glVertexAttribPointer</refentrytitle></citerefentry>,\r | |
105 | <citerefentry><refentrytitle>glVertexBindingDivisor</refentrytitle></citerefentry>.\r | |
106 | </para>\r | |
107 | </refsect1>\r | |
108 | <refsect1 id="Copyright"><title>Copyright</title>\r | |
109 | <para>\r | |
110 | Copyright <trademark class="copyright"></trademark> 2012 Khronos Group. \r | |
111 | This material may be distributed subject to the terms and conditions set forth in \r | |
112 | the Open Publication License, v 1.0, 8 June 1999.\r | |
113 | <ulink url="http://opencontent.org/openpub/">http://opencontent.org/openpub/</ulink>.\r | |
114 | </para>\r | |
115 | </refsect1>\r | |
116 | </refentry>\r |