Skip to main content

decode

Function decode 

Source
pub fn decode(
    bytes: &[u8],
    format: Format,
    bounds: (u32, u32),
    limits: Limits,
    cancel: &AtomicBool,
) -> Result<Raster, Error>
Expand description

Decode a fitted, orientation-corrected still image to straight RGBA. No upscaling. Run off the UI thread. Cancellation is checked around codec calls, not inside them; allocation and source limits are enforced before full decoding.