Struct OutputInfo

pub struct OutputInfo { pub width: u32, pub height: u32, pub color_type: ColorType, pub bit_depth: BitDepth, pub line_size: usize }

Output info.

This describes one particular frame of the image that was written into the output buffer.

Fields

width: u32

The pixel width of this frame.

height: u32

The pixel height of this frame.

color_type: ColorType

The chosen output color type.

bit_depth: BitDepth

The chosen output bit depth.

line_size: usize

The byte count of each scan line in the image.

Implementations

impl OutputInfo

fn buffer_size(&self) -> usize

Returns the size needed to hold a decoded frame If the output buffer was larger then bytes after this count should be ignored. They may still have been changed.

Trait Implementations

impl Debug for OutputInfo

fn fmt(&self, f: &mut Formatter<'_>) -> Result

impl Eq for OutputInfo

impl PartialEq for OutputInfo

fn eq(&self, other: &Self) -> bool

impl StructuralPartialEq for OutputInfo

Auto Trait Implementations

impl Freeze for OutputInfo

impl RefUnwindSafe for OutputInfo

impl Send for OutputInfo

impl Sync for OutputInfo

impl Unpin for OutputInfo

impl UnsafeUnpin for OutputInfo

impl UnwindSafe for OutputInfo

Blanket Implementations

impl<T> Any for OutputInfo where T: 'static + ?Sized,

fn type_id(&self) -> TypeId

impl<T> Borrow<T> for OutputInfo where T: ?Sized,

fn borrow(&self) -> &T

impl<T> BorrowMut<T> for OutputInfo where T: ?Sized,

fn borrow_mut(&mut self) -> &mut T

impl<T> From<T> for OutputInfo

fn from(t: T) -> T

Returns the argument unchanged.

impl<T, U> Into<U> for OutputInfo where U: From<T>,

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom<U> for OutputInfo where U: Into<T>,

type Error = never;
fn try_from(value: U) -> Result<T, never>

impl<T, U> TryInto<U> for OutputInfo where U: TryFrom<T>,

type Error = <U as TryFrom<T>>::Error;
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>