Module exr::compression::piz::huffman
source Β· Expand description
16-bit Huffman compression and decompression. Huffman compression and decompression routines written by Christian Rouet for his PIZ image file format.
Structs§
- ShortCode π
Enums§
- Code π
Constants§
- DECODE_BITS π
- DECODE_MASK π
- DECODING_TABLE_SIZE π
- ENCODE_BITS π
- ENCODING_TABLE_SIZE π
- INVALID_BIT_COUNT π
- INVALID_CODE π
- INVALID_TABLE_ENTRY π
- INVALID_TABLE_SIZE π
- LONGEST_LONG_RUN π
- LONG_ZEROCODE_RUN π
- NOT_ENOUGH_DATA π
- SHORTEST_LONG_RUN π
- SHORT_ZEROCODE_RUN π
- TABLE_TOO_LONG π
- TOO_MUCH_DATA π
Functions§
- Build a βcanonicalβ Huffman code table:
- build_decoding_table πBuild a decoding hash table based on the encoding table code:
- build_encoding_table πCompute Huffman codes (based on frq input) and store them in frq:
- code π
- count_frequencies π
- decode_with_tables πDecode (uncompress) n bits based on encoding & decoding tables:
- length π
- pack_encoding_table πPack an encoding table:
- read_bits π
- read_byte π
- read_code_into_vec π
- read_encoding_table πRun-length-decompresses all zero runs from the packed table to the encoding table
- send_code π
- write_bits π
- write_code π