[][src]Struct spng::Decoder

pub struct Decoder<R> { /* fields omitted */ }

PNG decoder


impl<R> Decoder<R>[src]

pub fn new(reader: R) -> Decoder<R>[src]

Create a new png decoder with the default limits

pub fn with_limits(self, limits: Limits) -> Decoder<R>[src]

pub fn with_context_flags(self, context_flags: ContextFlags) -> Decoder<R>[src]

pub fn with_decode_flags(self, decode_flags: DecodeFlags) -> Decoder<R>[src]

pub fn with_output_format(self, output_format: Format) -> Decoder<R>[src]

pub fn set_limits(&mut self, limits: Limits)[src]

Set the limits

pub fn set_decode_flags(&mut self, decode_flags: DecodeFlags)[src]

Set the decoding flags

pub fn set_output_format(&mut self, output_format: Format)[src]

Set the output image format

pub fn set_context_flags(&mut self, context_flags: ContextFlags)[src]

pub fn read_info(self) -> Result<(OutputInfo, Reader<R>), Error> where
    R: Read

Read the png header and initialize decoding.

Trait Implementations

impl<R: Debug> Debug for Decoder<R>[src]

Auto Trait Implementations

impl<R> RefUnwindSafe for Decoder<R> where
    R: RefUnwindSafe

impl<R> Send for Decoder<R> where
    R: Send

impl<R> Sync for Decoder<R> where
    R: Sync

impl<R> Unpin for Decoder<R> where
    R: Unpin

impl<R> UnwindSafe for Decoder<R> where
    R: UnwindSafe

Blanket Implementations

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

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

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

impl<T> From<T> for T[src]

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

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

type Error = Infallible

The type returned in the event of a conversion error.

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

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.