#[non_exhaustive]pub struct JxlDecoderOptions {
pub adjust_orientation: bool,
pub render_spot_colors: bool,
pub coalescing: bool,
pub desired_intensity_target: Option<f32>,
pub skip_preview: bool,
pub progressive_mode: JxlProgressiveMode,
pub cms: Option<Box<dyn JxlCms>>,
pub high_precision: bool,
pub premultiply_output: bool,
pub limits: JxlDecoderLimits,
pub stop: Arc<dyn Stop>,
pub parallel: bool,
}Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.adjust_orientation: bool§render_spot_colors: bool§coalescing: bool§desired_intensity_target: Option<f32>§skip_preview: bool§progressive_mode: JxlProgressiveMode§cms: Option<Box<dyn JxlCms>>§high_precision: boolUse high precision mode for decoding. When false (default), uses lower precision settings that match libjxl’s default. When true, uses higher precision at the cost of performance.
This affects multiple decoder decisions including spline rendering precision and potentially intermediate buffer storage (e.g., using f32 vs f16).
premultiply_output: boolIf true, multiply RGB by alpha before writing to output buffer. This produces premultiplied alpha output, which is useful for compositing. Default: false (output straight alpha)
limits: JxlDecoderLimitsSecurity limits to prevent resource exhaustion attacks.
Use JxlDecoderLimits::restrictive() for untrusted input.
stop: Arc<dyn Stop>Cooperative cancellation / timeout handle.
Default: Arc::new(enough::Unstoppable) (no cancellation).
parallel: boolEnable parallel decoding and rendering using rayon.
When true (the default when the threads feature is enabled),
group decoding and rendering are parallelized across rayon’s global
thread pool. Control thread count via RAYON_NUM_THREADS or
rayon::ThreadPoolBuilder::build_global().
When false, all decoding is single-threaded.