Struct glitter::vertex_data::VertexAttribute [] [src]

pub struct VertexAttribute {
    pub ty: VertexAttributeType,
    pub name: String,
    pub offset: usize,
    pub stride: usize,
}

Specifies the type, name, and memory layout of a vertex attribute. Generally, a "vertex attribute" corresponds to a field in a VertexData struct.

Fields

The type of the vertex attribute. This also specifies the number of bytes that make up a vertex attribute.

The name of the vertex attribute. This value is used as the $field_name when binding vertex attribute pointers with the attrib_pointers! macro.

The number of bytes to "move" from the start of the vertex data to reach this vertex attribute.

The number of bytes between consecutive vertex attributes. 0 indicates that the vertex data is tightly packed.

Trait Implementations

impl Clone for VertexAttribute
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more