Expand description
Portable image decoding on the CPU, the fallback behind any native decoder.
Formats are compiled in by Cargo feature (png, jpeg, gif, webp, bmp). Every frame
comes out oriented, resized to the request’s max_size, and converted to 8-bit sRGB: embedded
ICC profiles, PNG gamma/chromaticity and CICP metadata are all applied rather than ignored.
Animations are composited frame by frame; only the current composition is held in memory.
Structs§
- Software
Decoder - SoftwareDecoder reads the formats this crate was built with, entirely on the CPU.
Enums§
- Encode
Error EncodeErroris why pixels could not be encoded.- Encoding
Encodingis the fileencodewrites, with its format’s settings.
Functions§
- encode
encodewritespixelsas a file inencoding. Pixels of any layout are taken, turned into packed rows of straight RGBA first when they aren’t already.