mirror of
https://github.com/webmproject/libwebp.git
synced 2025-07-14 21:09:55 +02:00
Jump-lookup for Huffman coding
speeds up those codes that are not part of the main lookup. This gives a 10 % speedup for a photographic image. Change-Id: Ief54b0ad77db790a01314402ad351b40ac9a7be4
This commit is contained in:
@ -34,7 +34,8 @@ typedef struct HuffmanTree HuffmanTree;
|
||||
struct HuffmanTree {
|
||||
// Fast lookup for short bit lengths.
|
||||
uint8_t lut_bits_[HUFF_LUT];
|
||||
int lut_symbol_[HUFF_LUT];
|
||||
int16_t lut_symbol_[HUFF_LUT];
|
||||
int16_t lut_jump_[HUFF_LUT];
|
||||
// Complete tree for lookups.
|
||||
HuffmanTreeNode* root_; // all the nodes, starting at root.
|
||||
int max_nodes_; // max number of nodes
|
||||
|
Reference in New Issue
Block a user