#[repr(u8)]pub enum PixelFormat {
Argb8888 = 0,
Rgb888 = 1,
Rgb565 = 2,
Argb1555 = 3,
Argb4444 = 4,
L8 = 5,
AL44 = 6,
AL88 = 7,
L4 = 8,
A8 = 9,
A4 = 10,
YCbCr = 11,
}Expand description
DMA2D Pixel Format
Variants§
Argb8888 = 0
ARGB8888 24-bit color with alpha
Rgb888 = 1
RGB888 24-bit color
Rgb565 = 2
RGB565 16-bit color
Argb1555 = 3
ARGB1555
Argb4444 = 4
ARGB4444
L8 = 5
8 bit luminance
AL44 = 6
4-bit alpha, 4 bit luminance
AL88 = 7
8-bit alpha, 8 bit luminance
L4 = 8
4-bit luminance
A8 = 9
8-bit alpha
A4 = 10
4-bit alpha
YCbCr = 11
YCbCr YUV
Implementations§
Source§impl PixelFormat
impl PixelFormat
Sourcepub const fn nibbles_per_pixel(&self) -> usize
pub const fn nibbles_per_pixel(&self) -> usize
Number of 4 bit nibbles per pixel
Sourcepub const fn bytes_per_pixel(&self) -> Option<usize>
pub const fn bytes_per_pixel(&self) -> Option<usize>
Number of bytes per pixel. Panics if pixel format size is 4 bits
Trait Implementations§
Source§impl Clone for PixelFormat
impl Clone for PixelFormat
Source§fn clone(&self) -> PixelFormat
fn clone(&self) -> PixelFormat
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PixelFormat
impl Debug for PixelFormat
Source§impl Format for PixelFormat
impl Format for PixelFormat
Source§impl Into<BgpfccrCm> for PixelFormat
impl Into<BgpfccrCm> for PixelFormat
Source§impl Into<FgpfccrCm> for PixelFormat
impl Into<FgpfccrCm> for PixelFormat
Source§impl Into<OpfccrCm> for PixelFormat
impl Into<OpfccrCm> for PixelFormat
Source§impl PartialEq for PixelFormat
impl PartialEq for PixelFormat
impl Copy for PixelFormat
impl Eq for PixelFormat
impl StructuralPartialEq for PixelFormat
Auto Trait Implementations§
impl Freeze for PixelFormat
impl RefUnwindSafe for PixelFormat
impl Send for PixelFormat
impl Sync for PixelFormat
impl Unpin for PixelFormat
impl UnwindSafe for PixelFormat
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