#[repr(C)]pub struct JxlMemoryManager {
pub opaque: *mut c_void,
pub alloc: Option<JpegxlAllocFunc>,
pub free: Option<JpegxlFreeFunc>,
}Expand description
Memory Manager struct. These functions, when provided by the caller, will be used to handle memory allocations.
Fields§
§opaque: *mut c_voidThe opaque pointer that will be passed as the first parameter to all the functions in this struct.
alloc: Option<JpegxlAllocFunc>Memory allocation function. This can be NULL if and only if also the
Self::free member in this class is NULL. All dynamic memory will be allocated
and freed with these functions if they are not NULL, otherwise with the
standard malloc/free.
free: Option<JpegxlFreeFunc>Free function matching the Self::alloc member.
Trait Implementations§
Source§impl Clone for JxlMemoryManager
impl Clone for JxlMemoryManager
Source§fn clone(&self) -> JxlMemoryManager
fn clone(&self) -> JxlMemoryManager
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for JxlMemoryManager
impl RefUnwindSafe for JxlMemoryManager
impl !Send for JxlMemoryManager
impl !Sync for JxlMemoryManager
impl Unpin for JxlMemoryManager
impl UnwindSafe for JxlMemoryManager
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more