• 10
• 12
• 12
• 14
• 17

LZH Compression

This topic is 4965 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

Recommended Posts

I've just finished up a huffman compression file packer and am rather disappointed with the level of compression when dealing with binary data. LZH seems like the next logical step as it would offer better compression and uses a familar technique (the h stands for huffman.) I can't seem to find any good articles on how this compression works and would appreciate it if I could get pointed in the right direction.

This might help.

Share on other sites
Yes I've looked there already :/

The problem with those links is that none offer an explanation of what the algorithm is. I'd rather have an explanation than a code example. That said, I can deal with a code example if it is commented (I'd rather understand that just perform a copy paste.) Some of those links have code examples but none are commented and are also in pascal. I don't understand a alot of the syntax that I see there.

So what I'm looking for is a link to an explanation, a code example in C++, or an explanation from one of the forums members if they would be so gracious :D

                               currently encoding                                          |data:   0 1 2 3 1 2 3 1 2 3 0 0 0 1 0 0 2 0                    |<----window----->|