Struct gfx_hal::format::FormatDesc [−][src]
Description of a format.
Fields
bits: u16Total number of bits.
- Depth/Stencil formats are opaque formats, where the total number of bits is unknown. A dummy value is used for these formats instead (sum of depth and stencil bits). For copy operations, the number of bits of the corresponding aspect should be used.
- The total number can be larger than the sum of individual format bits
(
color,alpha,depthandstencil) for packed formats. - For compressed formats, this denotes the number of bits per block.
dim: (u8, u8)Dimensions (width, height) of the texel blocks.
packed: boolThe format representation depends on the endianness of the platform.
- On little-endian systems, the actual oreder of components is reverse of what a surface type specifies.
aspects: AspectsFormat aspects
Implementations
impl FormatDesc[src]
impl FormatDesc[src]pub fn is_compressed(&self) -> bool[src]
Check if the format is compressed.
Trait Implementations
impl Clone for FormatDesc[src]
impl Clone for FormatDesc[src]fn clone(&self) -> FormatDesc[src]
pub fn clone_from(&mut self, source: &Self)1.0.0[src]
impl Copy for FormatDesc[src]
impl Copy for FormatDesc[src]impl Eq for FormatDesc[src]
impl Eq for FormatDesc[src]impl Hash for FormatDesc[src]
impl Hash for FormatDesc[src]impl Ord for FormatDesc[src]
impl Ord for FormatDesc[src]impl PartialEq<FormatDesc> for FormatDesc[src]
impl PartialEq<FormatDesc> for FormatDesc[src]fn eq(&self, other: &FormatDesc) -> bool[src]
fn ne(&self, other: &FormatDesc) -> bool[src]
impl PartialOrd<FormatDesc> for FormatDesc[src]
impl PartialOrd<FormatDesc> for FormatDesc[src]impl StructuralEq for FormatDesc[src]
impl StructuralEq for FormatDesc[src]impl StructuralPartialEq for FormatDesc[src]
impl StructuralPartialEq for FormatDesc[src]Auto Trait Implementations
impl RefUnwindSafe for FormatDesc
impl RefUnwindSafe for FormatDescimpl Send for FormatDesc
impl Send for FormatDescimpl Sync for FormatDesc
impl Sync for FormatDescimpl Unpin for FormatDesc
impl Unpin for FormatDescimpl UnwindSafe for FormatDesc
impl UnwindSafe for FormatDesc