Class GlUtil.Attribute
- java.lang.Object
-
- com.google.android.exoplayer2.util.GlUtil.Attribute
-
- Enclosing class:
- GlUtil
public static final class GlUtil.Attribute extends Object
GL attribute, which can be attached to a buffer withsetBuffer(float[], int).
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidbind()Sets the vertex attribute to whatever was attached viasetBuffer(float[], int).voidsetBuffer(float[] buffer, int size)Configuresbind()to attach vertices inbuffer(each of sizesizeelements) to thisGlUtil.Attribute.
-
-
-
Field Detail
-
name
public final String name
The name of the attribute in the GLSL sources.
-
-
Constructor Detail
-
Attribute
public Attribute(String name, int index, int location)
-
-
Method Detail
-
setBuffer
public void setBuffer(float[] buffer, int size)Configuresbind()to attach vertices inbuffer(each of sizesizeelements) to thisGlUtil.Attribute.- Parameters:
buffer- Buffer to bind to this attribute.size- Number of elements per vertex.
-
bind
public void bind()
Sets the vertex attribute to whatever was attached viasetBuffer(float[], int).Should be called before each drawing call.
-
-