pub enum BitmapError {
NullReference,
PixelBufferSizeMismatch {
got: usize,
required: usize,
},
UnsupportedOperationForPixelFormat,
FailedPngWrite,
EmptyBitmap,
}Expand description
Errors can occure when creating Bitmaps
Variants§
NullReference
The Ultralight library returned a null pointer.
PixelBufferSizeMismatch
The pixels passed to create the Bitmap does not match the required size.
UnsupportedOperationForPixelFormat
Tried to swap red and blue channels on an unsupported format.
FailedPngWrite
Could not write bitmap to PNG successfully.
EmptyBitmap
Could not create bitmap because its empty
Trait Implementations§
Source§impl Debug for BitmapError
impl Debug for BitmapError
Source§impl Display for BitmapError
impl Display for BitmapError
Source§impl Error for BitmapError
impl Error for BitmapError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for BitmapError
impl RefUnwindSafe for BitmapError
impl Send for BitmapError
impl Sync for BitmapError
impl Unpin for BitmapError
impl UnwindSafe for BitmapError
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