pub struct DecodeOutcome {
pub decoded: Rect,
pub warnings: Vec<Warning>,
}Expand description
Non-fatal outcome of a successful decode. See spec Section 2.
DecodeOutcome lives on decoder.rs rather than info.rs because it
carries Warning values from error.rs, and moving it into info would
create a info → error cycle (see info.rs header note).
Fields§
§decoded: RectThe source-coordinate rectangle represented by the output buffer.
Full-image decodes return Rect::full(info.dimensions) even when the
requested output is downscaled; region decodes return their source ROI.
warnings: Vec<Warning>Warnings emitted during parse or decode. Empty when the stream is syntactically clean and every capability was exercised without fallback.
Trait Implementations§
Source§impl Clone for DecodeOutcome
impl Clone for DecodeOutcome
Source§fn clone(&self) -> DecodeOutcome
fn clone(&self) -> DecodeOutcome
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 moreSource§impl Debug for DecodeOutcome
impl Debug for DecodeOutcome
impl Eq for DecodeOutcome
Source§impl From<DecodeOutcome> for DecodeOutcome<Warning>
impl From<DecodeOutcome> for DecodeOutcome<Warning>
Source§fn from(outcome: DecodeOutcome) -> Self
fn from(outcome: DecodeOutcome) -> Self
Converts to this type from the input type.
Source§impl PartialEq for DecodeOutcome
impl PartialEq for DecodeOutcome
impl StructuralPartialEq for DecodeOutcome
Auto Trait Implementations§
impl Freeze for DecodeOutcome
impl RefUnwindSafe for DecodeOutcome
impl Send for DecodeOutcome
impl Sync for DecodeOutcome
impl Unpin for DecodeOutcome
impl UnsafeUnpin for DecodeOutcome
impl UnwindSafe for DecodeOutcome
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