pub enum WordRepresentation {
BigEndian,
LittleEndian,
}
Expand description
The different ways the u8 color values are encoded into a u32 value.
A successfull reading from OpenSlide’s read_region()
will result in a buffer of u32
with
height * width
elements, where height
and width
is the shape (in pixels) of the read
region. This u32
value consist of four u8
values which are the red, green, blue, and alpha
value of a certain pixel. This enum determines in which order to arange these channels within
one element.
Variants§
BigEndian
From most significant bit to least significant bit: [alpha, red, green, blue]
LittleEndian
From most significant bit to least significant bit: [blue, green, red, alpha]
Trait Implementations§
Source§impl Clone for WordRepresentation
impl Clone for WordRepresentation
Source§fn clone(&self) -> WordRepresentation
fn clone(&self) -> WordRepresentation
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for WordRepresentation
impl RefUnwindSafe for WordRepresentation
impl Send for WordRepresentation
impl Sync for WordRepresentation
impl Unpin for WordRepresentation
impl UnwindSafe for WordRepresentation
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more