DEFLATE Compresser

Add a reply

Posted by fuliculi 900 days ago:
http://www.gzip.org/zlib/rfc-deflate.html

In 3.2.7, it is written :
"The Huffman codes for the two alphabets appear in the block immediately after the header bits and before the actual compressed data, first the literal/length code and then the distance code. Each code is defined by a sequence of code lengths, as discussed in Paragraph 3.2.2, above. For even greater compactness, the code length sequences themselves are compressed using a Huffman code."

Yet I can't find any description about which Huffman code used to
compress the code length sequences.
Does somebody else is trying to pass the test the hard way?
Posted by hallvabo 899 days ago:
The encoding scheme for the code length sequences follows right after the text you quoted from section 3.2.7 :)
Posted by fuliculi 899 days ago:
I read the 3.2.7 section, but it's describing the alphabet rather than the huffman code isn't it?
I was expecting some length associated to each of the elements of this alphabet...
Posted by hallvabo 897 days ago:
How to generate the actual Huffman codes from the code length sequences is described in section 3.2.2. It's a three step process, and C-code for the algorithm is included.
Posted by fuliculi 897 days ago:
Thank you for your answer though it is not the point I had a problem on however.
I think the document from zlib answered my question. I'll give it a shot once more some day next week.

Add a reply