Skip to main content

decode_rgba8

Function decode_rgba8 

pub fn decode_rgba8(bytes: &[u8]) -> Result<Rgba8, ImageError>
Expand description

Decode a PNG of any colour type and bit depth into 8-bit RGBA.

§Errors

Fails when bytes is not a complete PNG or exceeds the codec’s default allocation limit.