Struct luminance::vertex::VertexComponentFormat [] [src]

pub struct VertexComponentFormat {
    pub comp_type: Type,
    pub dim: Dim,
    pub unit_size: usize,
    pub align: usize,
}

Vertex component format. It gives information on how vertices should be passed to the GPU and optimized in buffers.

Fields

Type of the component. See Type for further details.

Dimension of the component. It should be in 1–4. See Dim for further details.

Size in bytes that a single element of the component takes. That is, if your component has a dimension set to 2, then the unit size should be the size of a single element (not two).

Alignment of the component. The best advice is to respect what Rust does, so it’s highly recommended to use ::std::mem::align_of to let it does the job for you.

Trait Implementations

impl Clone for VertexComponentFormat
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Copy for VertexComponentFormat
[src]

impl Debug for VertexComponentFormat
[src]

Formats the value using the given formatter.

impl Eq for VertexComponentFormat
[src]

impl PartialEq for VertexComponentFormat
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.