Struct libavif_sys::avifIO[][src]

#[repr(C)]pub struct avifIO {
    pub destroy: extern "C" fn(io: *mut avifIO),
    pub read: extern "C" fn(io: *mut avifIO, readFlags: u32, offset: u64, size: size_t, out: *mut avifROData) -> avifResult,
    pub write: extern "C" fn(io: *mut avifIO, writeFlags: u32, offset: u64, size: size_t, data: *const u8, size: size_t) -> avifResult,
    pub sizeHint: u64,
    pub persistent: avifBool,
    pub data: *mut c_void,
}

Fields

destroy: extern "C" fn(io: *mut avifIO)read: extern "C" fn(io: *mut avifIO, readFlags: u32, offset: u64, size: size_t, out: *mut avifROData) -> avifResultwrite: extern "C" fn(io: *mut avifIO, writeFlags: u32, offset: u64, size: size_t, data: *const u8, size: size_t) -> avifResult

This is reserved for future use - but currently ignored. Set it to a null pointer.

sizeHint: u64

If non-zero, this is a hint to internal structures of the max size offered by the content this avifIO structure is reading. If it is a static memory source, it should be the size of the memory buffer; if it is a file, it should be the file’s size. If this information cannot be known (as it is streamed-in), set a reasonable upper boundary here (larger than the file can possibly be for your environment, but within your environment’s memory constraints). This is used for sanity checks when allocating internal buffers to protect against malformed/malicious files.

persistent: avifBooldata: *mut c_void

Trait Implementations

impl Debug for avifIO[src]

Auto Trait Implementations

impl RefUnwindSafe for avifIO

impl !Send for avifIO

impl !Sync for avifIO

impl Unpin for avifIO

impl UnwindSafe for avifIO

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, 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.