Enum miniquad::graphics::VertexFormat
source · pub enum VertexFormat {
Show 17 variants
Float1,
Float2,
Float3,
Float4,
Byte1,
Byte2,
Byte3,
Byte4,
Short1,
Short2,
Short3,
Short4,
Int1,
Int2,
Int3,
Int4,
Mat4,
}
Variants§
Float1
One 32-bit wide float (equivalent to f32
)
Float2
Two 32-bit wide floats (equivalent to [f32; 2]
)
Float3
Three 32-bit wide floats (equivalent to [f32; 3]
)
Float4
Four 32-bit wide floats (equivalent to [f32; 4]
)
Byte1
One unsigned 8-bit integer (equivalent to u8
)
Byte2
Two unsigned 8-bit integers (equivalent to [u8; 2]
)
Byte3
Three unsigned 8-bit integers (equivalent to [u8; 3]
)
Byte4
Four unsigned 8-bit integers (equivalent to [u8; 4]
)
Short1
One unsigned 16-bit integer (equivalent to u16
)
Short2
Two unsigned 16-bit integers (equivalent to [u16; 2]
)
Short3
Tree unsigned 16-bit integers (equivalent to [u16; 3]
)
Short4
Four unsigned 16-bit integers (equivalent to [u16; 4]
)
Int1
One unsigned 32-bit integers (equivalent to [u32; 1]
)
Int2
Two unsigned 32-bit integers (equivalent to [u32; 2]
)
Int3
Three unsigned 32-bit integers (equivalent to [u32; 3]
)
Int4
Four unsigned 32-bit integers (equivalent to [u32; 4]
)
Mat4
Four by four matrix of 32-bit floats
Implementations§
source§impl VertexFormat
impl VertexFormat
sourcepub fn components(&self) -> i32
pub fn components(&self) -> i32
Number of components in this VertexFormat it is called size in OpenGl, but do not confuse this with bytes size basically, its an N from FloatN/IntN
sourcepub fn size_bytes(&self) -> i32
pub fn size_bytes(&self) -> i32
Size in bytes
Trait Implementations§
source§impl Clone for VertexFormat
impl Clone for VertexFormat
source§fn clone(&self) -> VertexFormat
fn clone(&self) -> VertexFormat
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for VertexFormat
impl Debug for VertexFormat
source§impl PartialEq for VertexFormat
impl PartialEq for VertexFormat
source§fn eq(&self, other: &VertexFormat) -> bool
fn eq(&self, other: &VertexFormat) -> bool
self
and other
values to be equal, and is used
by ==
.