Crate lzham

Source
Expand description

High-level Rust bindings over the lzham_codec.

lzham provides high level functions and structures to compress and decompress data based on the LZHAM codec.

The crate has not been tested enough yet and some functionality is still unimplemented.

§Examples

let data = String::from("This is a test.");

let mut comp = Vec::new();
let status = compress(&mut data.as_bytes(), &mut comp);

assert!(status.is_success());

let mut decomp = Vec::new();
let status = decompress(&mut comp.as_slice(), &mut decomp, data.len());

assert!(status.is_success());

Modules§

compress
Compression related items.
decompress
Decompression related items.

Structs§

CompressionOptions
Options to tweak compression.
DecompressionOptions
Options to tweak decompression.
TableUpdateInterval
The table update interval for compression/decompression.
TableUpdateRate
The table update rate for compression/decompression.

Functions§

compress
Compresses input data into the output buffer with default options.
compress_with_options
Compresses input data into the output buffer with provided options.
decompress
Decompresses input data into the output buffer with default options.
decompress_with_options
Decompresses input data into the output buffer with provided options.