[−][src]Function compu_brotli_sys::BrotliDecoderCreateInstance
pub unsafe extern "C" fn BrotliDecoderCreateInstance(
alloc_func: brotli_alloc_func,
free_func: brotli_free_func,
opaque: *mut c_void
) -> *mut BrotliDecoderState
Creates an instance of ::BrotliDecoderState and initializes it.
The instance can be used once for decoding and should then be destroyed with ::BrotliDecoderDestroyInstance, it cannot be reused for a new decoding session.
@p alloc_func and @p free_func @b MUST be both zero or both non-zero. In the case they are both zero, default memory allocators are used. @p opaque is passed to @p alloc_func and @p free_func when they are called. @p free_func has to return without doing anything when asked to free a NULL pointer.
@param alloc_func custom memory allocation function @param free_func custom memory free function @param opaque custom memory manager handle @returns @c 0 if instance can not be allocated or initialized @returns pointer to initialized ::BrotliDecoderState otherwise