#[non_exhaustive]pub enum PaintedKind {
Rgba,
Indexed,
OneBit,
}Expand description
What a Painted picture’s bytes are.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Rgba
Four bytes a pixel, red, green, blue and alpha, row after row.
Indexed
A byte a pixel, an index into the picture’s palette of
PALETTE_LEN colours, row after row. Every pixel is opaque.
OneBit
A bit a pixel: rows of ceil(width / 8) bytes, a byte’s highest
bit its leftmost pixel, a set bit white, as
onebit::Image has them; with an
optional mask of the same shape, a set bit drawn.
Implementations§
Trait Implementations§
Source§impl Clone for PaintedKind
impl Clone for PaintedKind
Source§fn clone(&self) -> PaintedKind
fn clone(&self) -> PaintedKind
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for PaintedKind
Source§impl Debug for PaintedKind
impl Debug for PaintedKind
impl Eq for PaintedKind
Source§impl Hash for PaintedKind
impl Hash for PaintedKind
Source§impl PartialEq for PaintedKind
impl PartialEq for PaintedKind
impl StructuralPartialEq for PaintedKind
Auto Trait Implementations§
impl Freeze for PaintedKind
impl RefUnwindSafe for PaintedKind
impl Send for PaintedKind
impl Sync for PaintedKind
impl Unpin for PaintedKind
impl UnsafeUnpin for PaintedKind
impl UnwindSafe for PaintedKind
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