Crate zipng

Source
Expand description

zipng is a polyglot encoder for ZIP-and/or-PNG files.

Modules§

fonts
Built-in bitmap fonts
palettes
Built-in color palettes

Structs§

Font
A bitmap font that can be used to render text onto a Png image.
Png
In-memory representation of a PNG file’s essential image contents.
Zip
In-memory representation of a ZIP file’s essential archive contents.
ZipConfiguration
Configuration determining how the Zip archive is serialized.
ZipEntry
A reference to an entry in a Zip archive.

Enums§

BitDepth
The bit depth of an image, as defined in the PNG specification.
ColorType
The color type of an image, as defined in the PNG specification.
never
An uninhabited !-like “never” type, with trait implementations as needed for convenience within this crate’s types.
panic
An uninhabited !-like “never” type that provides a panicking implementation of From for any Display + Debug error type, with trait implementations as needed for convenience within this crate’s.

Statics§

PIN_MIMETYPE
Pins the mimetype magic header file used by EPUB and OpenDocument.
SORT_BY_BODY
Sorts files lexicographically based on their content, then applies SORT_BY_NAME.
SORT_BY_NAME
Sort file by name, first based on the number of slash / path separator characters, then lexicographically.

Traits§

ToPng
A Png or input that can be converted to one.
ToZip
A Zip or input that can be converted to one.

Functions§

adler32
Compute the Adler-32 checksum of a byte slice
crc32
Compute the CRC-32 checksum of a byte slice as per ISO 3309
png_from_slice
Reads the image data from a PNG file.
png_to_vec
Creates a PNG file with the given image data.
zip_from_slice
Reads the archive contents of a ZIP file.
zip_to_vec
Creates a ZIP archive.

Type Aliases§

ZipEntryComparison
Comparison function used for ordering entries in a Zip archive.
ZipEntryPredicate
Predicate function used for selecting entries in a Zip archive.