pub enum Type {
U8,
U16,
U32,
U64,
I8,
I16,
I32,
I64,
F32,
F64,
}Expand description
Type format for a property.
Variants§
U8
Unsigned 8 bit integer.
U16
Unsigned 16 bit integer.
U32
Unsigned 32 bit integer.
U64
Unsigned 64 bit integer.
I8
Signed 8 bit integer.
I16
Signed 16 bit integer.
I32
Signed 32 bit integer.
I64
Signed 64 bit integer.
F32
32 bit float.
F64
64 bit float.
Implementations§
Source§impl Type
impl Type
Sourcepub fn matrix(&self, rows: u8, cols: u8) -> Option<(u16, u64)>
pub fn matrix(&self, rows: u8, cols: u8) -> Option<(u16, u64)>
Returns the type format and size in bytes for a matrix.
Notice that this method uses rows and columns, not width and height.
Returns None if the matrix exceed dimensions 80x80.
Returns None if the width or height is zero.
Sourcepub fn vector(&self, dim: u8) -> Option<(u16, u64)>
pub fn vector(&self, dim: u8) -> Option<(u16, u64)>
Returns the type format and size in bytes for a vector.
Returns None if the vector exceed dimension 80.
Returns None if the vector has dimension zero.
Sourcepub fn offset_custom_format() -> u16
pub fn offset_custom_format() -> u16
Returns the offset for specifying a custom format.
Sourcepub fn custom_formats() -> u16
pub fn custom_formats() -> u16
Returns the number of available custom formats.
Trait Implementations§
impl Copy for Type
impl Eq for Type
impl StructuralPartialEq for Type
Auto Trait Implementations§
impl Freeze for Type
impl RefUnwindSafe for Type
impl Send for Type
impl Sync for Type
impl Unpin for Type
impl UnwindSafe for Type
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more