[][src]Enum png::FilterType

#[repr(u8)]
pub enum FilterType {
    NoFilter,
    Sub,
    Up,
    Avg,
    Paeth,
}

The byte level filter applied to scanlines to prepare them for compression.

Compression in general benefits from repetitive data. The filter is a content-aware method of compressing the range of occurring byte values to help the compression algorithm. Note that this does not operate on pixels but on raw bytes of a scanline.

Variants

NoFilter
Sub
Up
Avg
Paeth

Methods

impl FilterType[src]

pub fn from_u8(n: u8) -> Option<FilterType>[src]

u8 -> Self. Temporary solution until Rust provides a canonical one.

Trait Implementations

impl Clone for FilterType[src]

impl Copy for FilterType[src]

impl Debug for FilterType[src]

impl Eq for FilterType[src]

impl PartialEq<FilterType> for FilterType[src]

impl StructuralEq for FilterType[src]

impl StructuralPartialEq for FilterType[src]

Auto Trait Implementations

Blanket Implementations

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

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

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

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.