[][src]Struct blend2d::codec::ImageCodec

#[repr(transparent)]
pub struct ImageCodec { /* fields omitted */ }

Provides a unified interface for inspecting image data and creating image decoders & encoders.

Methods

impl ImageCodec[src]

pub fn create_decoder(&self) -> Option<ImageDecoder>[src]

Creates an ImageDecoder for this codec.

pub fn create_encoder(&self) -> Option<ImageEncoder>[src]

Creates an ImageEncoder for this codec.

pub fn inspect_data<R: AsRef<[u8]>>(&self, data: R) -> u32[src]

Inspects the given data blob and determines how likely it is that the file belongs to this codec.

Important traits for Array<u8>
pub fn built_in_codecs() -> Array<ImageCodec>[src]

Returns the blend2d builtin codecs.

pub fn add_to_built_in(codec: &ImageCodec)[src]

Adds a codec to the built in codecs list.

pub fn remove_from_built_in(codec: &ImageCodec)[src]

Removes the codec from the built in codecs list.

pub fn name(&self) -> &str[src]

The codec's name.

pub fn vendor(&self) -> &str[src]

The codec's vendor.

pub fn mime_type(&self) -> &str[src]

The codec's mime-type.

pub fn extensions(&self) -> impl Iterator<Item = &str>[src]

The codec's file extensions.

pub fn features(&self) -> ImageCodecFeatures[src]

The codec's features.

Trait Implementations

impl PartialEq<ImageCodec> for ImageCodec[src]

#[must_use] fn ne(&self, other: &Rhs) -> bool1.0.0[src]

This method tests for !=.

impl Clone for ImageCodec[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Drop for ImageCodec[src]

impl Debug for ImageCodec[src]

Auto Trait Implementations

Blanket Implementations

impl<T> ArrayType for T where
    T: WrappedBlCore, 
[src]

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

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

type Owned = T

The resulting type after obtaining ownership.

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

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.

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

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

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