#[non_exhaustive]#[repr(u8)]pub enum SampleBits {
Show 38 variants
Int8 = 0,
UInt8 = 1,
UInt1x8 = 2,
UInt2x4 = 3,
UInt332 = 4,
UInt233 = 5,
Int16 = 6,
UInt16 = 7,
UInt4x2 = 8,
UInt4x4 = 9,
UInt4x6 = 10,
UInt_444 = 11,
UInt444_ = 12,
UInt565 = 13,
UInt8x2 = 14,
UInt8x3 = 15,
UInt8x4 = 16,
UInt8x6 = 17,
Int8x2 = 18,
Int8x3 = 19,
Int8x4 = 20,
UInt16x2 = 21,
UInt16x3 = 22,
UInt16x4 = 23,
Int16x2 = 24,
Int16x3 = 25,
Int16x4 = 26,
UInt16x6 = 27,
UInt1010102 = 28,
UInt2101010 = 29,
UInt101010_ = 30,
UInt_101010 = 31,
Float16x4 = 32,
Float32 = 33,
Float32x2 = 34,
Float32x3 = 35,
Float32x4 = 36,
Float32x6 = 37,
}
Expand description
The bit-placement of samples within a texel.
We start with low-order bits in a little-endian representation of the surrounding numbers. So, for example, Int332 has the first sample in the three lowest bits of a u8 (byte-order independent) and a Int565 has its first channel in the first 5 low-order bits of a u16 little endian interpretation of the bytes.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Int8 = 0
A single 8-bit signed integer.
UInt8 = 1
A single 8-bit integer.
UInt1x8 = 2
Eight 1-bit integer.
UInt2x4 = 3
Four 2-bit integer.
UInt332 = 4
Three packed integer.
UInt233 = 5
Three packed integer.
Int16 = 6
A single 8-bit signed integer.
UInt16 = 7
A single 16-bit integer.
UInt4x2 = 8
Two packed integer.
UInt4x4 = 9
Four packed integer.
UInt4x6 = 10
Six packed integer.
UInt_444 = 11
Four packed integer, one component ignored.
UInt444_ = 12
Four packed integer, one component ignored.
UInt565 = 13
Three packed integer.
UInt8x2 = 14
Two 8-bit integers.
UInt8x3 = 15
Three 8-bit integer.
UInt8x4 = 16
Four 8-bit integer.
UInt8x6 = 17
Six 8-bit integer.
Int8x2 = 18
Two 8-bit integers.
Int8x3 = 19
Three 8-bit integer.
Int8x4 = 20
Four 8-bit integer.
UInt16x2 = 21
Two 16-bit integers.
UInt16x3 = 22
Three 16-bit integer.
UInt16x4 = 23
Four 16-bit integer.
Int16x2 = 24
Two 16-bit signed integers.
Int16x3 = 25
Three 16-bit integer.
Int16x4 = 26
Four 16-bit integer.
UInt16x6 = 27
Six 16-bit integer.
UInt1010102 = 28
Four packed integer.
UInt2101010 = 29
Four packed integer.
UInt101010_ = 30
Three packed integer, one component ignored.
UInt_101010 = 31
Three packed integer, one component ignored.
Float16x4 = 32
Four half-floats.
Float32 = 33
A single floating-point channel.
Float32x2 = 34
Two float channels.
Float32x3 = 35
Three float channels.
Float32x4 = 36
Four floats.
Float32x6 = 37
Six floats.
Implementations§
Trait Implementations§
Source§impl Clone for SampleBits
impl Clone for SampleBits
Source§fn clone(&self) -> SampleBits
fn clone(&self) -> SampleBits
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source
. Read more