pub unsafe extern "C" fn JxlEncoderSetFrameLossless(
    frame_settings: *mut JxlEncoderFrameSettings,
    lossless: c_int
) -> JxlEncoderStatus
Expand description

Enables lossless encoding.

This is not an option like the others on itself, but rather while enabled it overrides a set of existing options (such as distance, modular mode and color transform) that enables bit-for-bit lossless encoding.

When disabled, those options are not overridden, but since those options could still have been manually set to a combination that operates losslessly, using this function with lossless set to JXL_DEC_FALSE does not guarantee lossy encoding, though the default set of options is lossy.

@param frame_settings set of options and metadata for this frame. Also includes reference to the encoder object. @param lossless whether to override options for lossless mode @return JXL_ENC_SUCCESS if the operation was successful, JXL_ENC_ERROR otherwise.