Function jpegxl_sys::JxlDecoderFlushImage[][src]

pub unsafe extern "C" fn JxlDecoderFlushImage(
    dec: *mut JxlDecoder
) -> JxlDecoderStatus

Outputs progressive step towards the decoded image so far when only partial input was received. If the flush was successful, the buffer set with JxlDecoderSetImageOutBuffer will contain partial image data.

Can be called when JxlDecoderProcessInput returns JXL_DEC_NEED_MORE_INPUT, after the JXL_DEC_FRAME event already occured and before the JXL_DEC_FULL_IMAGE event occured for a frame.

@param dec decoder object @return JXL_DEC_SUCCESS if image data was flushed to the output buffer, or JXL_DEC_ERROR when no flush was done, e.g. if not enough image data was available yet even for flush, or no output buffer was set yet. An error is not fatal, it only indicates no flushed image is available now, regular, decoding can still be performed.