Struct exr::meta::MetaData[][src]

pub struct MetaData {
    pub requirements: Requirements,
    pub headers: Headers,
}

Contains the complete meta data of an exr image. Defines how the image is split up in the file, the number and type of images and channels, and various other attributes. The usage of custom attributes is encouraged.

Fields

requirements: Requirements

Some flags summarizing the features that must be supported to decode the file.

headers: Headers

One header to describe each layer in this file.

Implementations

impl MetaData[src]

#[must_use]pub fn read_from_file(path: impl AsRef<Path>, pedantic: bool) -> Result<Self>[src]

Read the exr meta data from a file. Use read_from_unbuffered instead if you do not have a file. Does not validate the meta data.

#[must_use]pub fn read_from_unbuffered(
    unbuffered: impl Read,
    pedantic: bool
) -> Result<Self>
[src]

Buffer the reader and then read the exr meta data from it. Use read_from_buffered if your reader is an in-memory reader. Use read_from_file if you have a file path. Does not validate the meta data.

#[must_use]pub fn read_from_buffered(buffered: impl Read, pedantic: bool) -> Result<Self>[src]

Read the exr meta data from a reader. Use read_from_file if you have a file path. Use read_from_unbuffered if this is not an in-memory reader. Does not validate the meta data.

pub fn read_offset_tables(
    read: &mut PeekRead<impl Read>,
    headers: &Headers
) -> Result<OffsetTables>
[src]

Read one offset table from the reader for each header.

pub fn skip_offset_tables(
    read: &mut PeekRead<impl Read>,
    headers: &Headers
) -> Result<usize>
[src]

Skip the offset tables by advancing the reader by the required byte count.

pub fn validate(headers: &[Header], pedantic: bool) -> Result<Requirements>[src]

Validates this meta data. Returns the minimal possible requirements.

Trait Implementations

impl Clone for MetaData[src]

impl Debug for MetaData[src]

impl PartialEq<MetaData> for MetaData[src]

impl StructuralPartialEq for MetaData[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.