pub struct Bmp<'a, C> { /* private fields */ }
Expand description
A BMP-format bitmap.
See the crate-level documentation for more information.
Implementations§
source§impl<'a, C> Bmp<'a, C>
impl<'a, C> Bmp<'a, C>
sourcepub fn from_slice(bytes: &'a [u8]) -> Result<Self, ParseError>
pub fn from_slice(bytes: &'a [u8]) -> Result<Self, ParseError>
Creates a bitmap object from a byte slice.
The created object keeps a shared reference to the input and does not dynamically allocate memory.
Trait Implementations§
source§impl<C> ImageDrawable for Bmp<'_, C>
impl<C> ImageDrawable for Bmp<'_, C>
source§impl<'a, C: Ord> Ord for Bmp<'a, C>
impl<'a, C: Ord> Ord for Bmp<'a, C>
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl<C> OriginDimensions for Bmp<'_, C>where
C: PixelColor,
impl<C> OriginDimensions for Bmp<'_, C>where
C: PixelColor,
source§impl<'a, C: PartialEq> PartialEq for Bmp<'a, C>
impl<'a, C: PartialEq> PartialEq for Bmp<'a, C>
source§impl<'a, C: PartialOrd> PartialOrd for Bmp<'a, C>
impl<'a, C: PartialOrd> PartialOrd for Bmp<'a, C>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl<'a, C: Copy> Copy for Bmp<'a, C>
impl<'a, C: Eq> Eq for Bmp<'a, C>
impl<'a, C> StructuralPartialEq for Bmp<'a, C>
Auto Trait Implementations§
impl<'a, C> Freeze for Bmp<'a, C>
impl<'a, C> RefUnwindSafe for Bmp<'a, C>where
C: RefUnwindSafe,
impl<'a, C> Send for Bmp<'a, C>where
C: Send,
impl<'a, C> Sync for Bmp<'a, C>where
C: Sync,
impl<'a, C> Unpin for Bmp<'a, C>where
C: Unpin,
impl<'a, C> UnwindSafe for Bmp<'a, C>where
C: UnwindSafe,
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> CheckedAs for T
impl<T> CheckedAs for T
source§fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
fn checked_as<Dst>(self) -> Option<Dst>where
T: CheckedCast<Dst>,
Casts the value.
source§impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
impl<Src, Dst> CheckedCastFrom<Src> for Dstwhere
Src: CheckedCast<Dst>,
source§fn checked_cast_from(src: Src) -> Option<Dst>
fn checked_cast_from(src: Src) -> Option<Dst>
Casts the value.
source§impl<T> Dimensions for Twhere
T: OriginDimensions,
impl<T> Dimensions for Twhere
T: OriginDimensions,
source§fn bounding_box(&self) -> Rectangle
fn bounding_box(&self) -> Rectangle
Returns the bounding box.
source§impl<T> ImageDrawableExt for Twhere
T: ImageDrawable,
impl<T> ImageDrawableExt for Twhere
T: ImageDrawable,
source§impl<T> OverflowingAs for T
impl<T> OverflowingAs for T
source§fn overflowing_as<Dst>(self) -> (Dst, bool)where
T: OverflowingCast<Dst>,
fn overflowing_as<Dst>(self) -> (Dst, bool)where
T: OverflowingCast<Dst>,
Casts the value.
source§impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere
Src: OverflowingCast<Dst>,
impl<Src, Dst> OverflowingCastFrom<Src> for Dstwhere
Src: OverflowingCast<Dst>,
source§fn overflowing_cast_from(src: Src) -> (Dst, bool)
fn overflowing_cast_from(src: Src) -> (Dst, bool)
Casts the value.
source§impl<T> SaturatingAs for T
impl<T> SaturatingAs for T
source§fn saturating_as<Dst>(self) -> Dstwhere
T: SaturatingCast<Dst>,
fn saturating_as<Dst>(self) -> Dstwhere
T: SaturatingCast<Dst>,
Casts the value.
source§impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere
Src: SaturatingCast<Dst>,
impl<Src, Dst> SaturatingCastFrom<Src> for Dstwhere
Src: SaturatingCast<Dst>,
source§fn saturating_cast_from(src: Src) -> Dst
fn saturating_cast_from(src: Src) -> Dst
Casts the value.
source§impl<T> UnwrappedAs for T
impl<T> UnwrappedAs for T
source§fn unwrapped_as<Dst>(self) -> Dstwhere
T: UnwrappedCast<Dst>,
fn unwrapped_as<Dst>(self) -> Dstwhere
T: UnwrappedCast<Dst>,
Casts the value.
source§impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere
Src: UnwrappedCast<Dst>,
impl<Src, Dst> UnwrappedCastFrom<Src> for Dstwhere
Src: UnwrappedCast<Dst>,
source§fn unwrapped_cast_from(src: Src) -> Dst
fn unwrapped_cast_from(src: Src) -> Dst
Casts the value.
source§impl<T> WrappingAs for T
impl<T> WrappingAs for T
source§fn wrapping_as<Dst>(self) -> Dstwhere
T: WrappingCast<Dst>,
fn wrapping_as<Dst>(self) -> Dstwhere
T: WrappingCast<Dst>,
Casts the value.
source§impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere
Src: WrappingCast<Dst>,
impl<Src, Dst> WrappingCastFrom<Src> for Dstwhere
Src: WrappingCast<Dst>,
source§fn wrapping_cast_from(src: Src) -> Dst
fn wrapping_cast_from(src: Src) -> Dst
Casts the value.