zune-ppm
A Portable Pixel Format (PPM) and Portable FloatMap Format (PFM) decoder and encoder
This crate contains a decoder and encoder that understands the ppm specification and hence can parse those formats.
| Format | Decoder | Encoder |
|---|---|---|
| P1-P3 | No | No |
| P5 | Yes | Yes |
| P6 | Yes | Yes |
| P7 | Yes | Yes |
| PFM | Yes | No |
Usage
A simple decoding looks like
use PPMDecoder;
use PPMDecodeErrors;
use DecodingResult;
Note that all routes have to be handled since PPMs come in many flavours.
Speed
PPM isn't really a format where speed matters, hence benchmarks have been skipped. Nonetheless the library is still as efficient as they come
Security
The crate is continuously fuzzed in CI to ensure that untrusted input does not cause panics
The library also has #!forbid[(unsafe_code)] to help prevent any future unsafe creep.