mirror of
https://github.com/Ryujinx/Opentk.git
synced 2024-12-26 13:05:34 +00:00
87 lines
4 KiB
XML
87 lines
4 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook MathML Module V1.1b1//EN"
|
|
"http://www.oasis-open.org/docbook/xml/mathml/1.1CR1/dbmathml.dtd">
|
|
<refentry id="glVertexAttribDivisor">
|
|
<refmeta>
|
|
<refmetainfo>
|
|
<copyright>
|
|
<year>2010</year>
|
|
<holder>Khronos Group</holder>
|
|
</copyright>
|
|
</refmetainfo>
|
|
<refentrytitle>glVertexAttribDivisor</refentrytitle>
|
|
<manvolnum>3G</manvolnum>
|
|
</refmeta>
|
|
<refnamediv>
|
|
<refname>glVertexAttribDivisor</refname>
|
|
<refpurpose>modify the rate at which generic vertex attributes advance during instanced rendering</refpurpose>
|
|
</refnamediv>
|
|
<refsynopsisdiv><title>C Specification</title>
|
|
<funcsynopsis>
|
|
<funcprototype>
|
|
<funcdef>void <function>glVertexAttribDivisor</function></funcdef>
|
|
<paramdef>GLuint <parameter>index</parameter></paramdef>
|
|
<paramdef>GLuint <parameter>divisor</parameter></paramdef>
|
|
</funcprototype>
|
|
</funcsynopsis>
|
|
</refsynopsisdiv>
|
|
<refsect1 id="parameters"><title>Parameters</title>
|
|
<variablelist>
|
|
<varlistentry>
|
|
<term><parameter>index</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
Specify the index of the generic vertex attribute.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
<varlistentry>
|
|
<term><parameter>divisor</parameter></term>
|
|
<listitem>
|
|
<para>
|
|
Specify the number of instances that will pass between updates of the generic attribute at slot <parameter>index</parameter>.
|
|
</para>
|
|
</listitem>
|
|
</varlistentry>
|
|
</variablelist>
|
|
</refsect1>
|
|
<refsect1 id="description"><title>Description</title>
|
|
<para>
|
|
<function>glVertexAttribDivisor</function> modifies the rate at which generic vertex attributes advance when rendering
|
|
multiple instances of primitives in a single draw call. If <parameter>divisor</parameter> is zero, the attribute at slot
|
|
<parameter>index</parameter> advances once per vertex. If <parameter>divisor</parameter> is non-zero, the attribute advances
|
|
once per <parameter>divisor</parameter> instances of the set(s) of vertices being rendered. An attribute
|
|
is referred to as instanced if its <constant>GL_VERTEX_ATTRIB_ARRAY_DIVISOR</constant> value is non-zero.
|
|
</para>
|
|
<para>
|
|
<parameter>index</parameter> must be less than the value of <constant>GL_MAX_VERTEX_ATTRIBS</constant>.
|
|
</para>
|
|
</refsect1>
|
|
<refsect1 id="notes"><title>Notes</title>
|
|
<para>
|
|
<function>glVertexAttribDivisor</function> is available only if the GL version is 3.3 or higher.
|
|
</para>
|
|
</refsect1>
|
|
<refsect1 id="errors"><title>Errors</title>
|
|
<para>
|
|
<constant>GL_INVALID_VALUE</constant> is generated if <parameter>index</parameter> is greater
|
|
than or equal to the value of <constant>GL_MAX_VERTEX_ATTRIBS</constant>.
|
|
</para>
|
|
</refsect1>
|
|
<refsect1 id="seealso"><title>See Also</title>
|
|
<para>
|
|
<citerefentry><refentrytitle>glVertexAttribPointer</refentrytitle></citerefentry>,
|
|
<citerefentry><refentrytitle>glEnableVertexAttribArray</refentrytitle></citerefentry>,
|
|
<citerefentry><refentrytitle>glDisableVertexAttribArray</refentrytitle></citerefentry>
|
|
</para>
|
|
</refsect1>
|
|
<refsect1 id="Copyright"><title>Copyright</title>
|
|
<para>
|
|
Copyright <trademark class="copyright"></trademark> 2010 Khronos Group.
|
|
This material may be distributed subject to the terms and conditions set forth in
|
|
the Open Publication License, v 1.0, 8 June 1999.
|
|
<ulink url="http://opencontent.org/openpub/">http://opencontent.org/openpub/</ulink>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|