AWARE SYSTEMS
TIFF and LibTiff Mail List Archive

Thread

2003.03.26 12:02 "LZW and 4bit tiffs", by Carter John-jcarte01
2003.03.26 23:30 "Re: LZW and 4bit tiffs", by Michael Still
2003.03.27 16:38 "RE: LZW and 4bit tiffs", by Carter John-jcarte01
2003.04.04 10:50 "RE: 8bit to 12bit", by Carter John-jcarte01
2003.04.03 13:03 "8bit to 12bit", by NTC Alpha
2003.04.04 10:33 "Re: 8bit to 12bit", by Michael Still

2003.03.26 23:30 "Re: LZW and 4bit tiffs", by Michael Still

I'm having great fun here trying to write a LZW decompression function.

There is one case in decompression (I think it was) where a code can be used which doesn't exist yet. Have you googled yet? There's a really good Dr Dobbs article from ages ago about this.

I use the following code for LZW decompression:

http://www.stillhq.com/extracted/pandaedit/lzw.cpp
http://www.stillhq.com/extracted/pandaedit/lzw.h

(the rest of the code in that directory uses this if you need calling examples)

Note that it's in C++, but once you've ditched the use of STL templates for vectors etc that shouldn't be too bad. A couple of things to note:

Cheers,

Mikal

--

Michael Still (mikal@stillhq.com) | Stage 1: Steal underpants
http://www.stillhq.com            | Stage 2: ????
UTC + 11                          | Stage 3: Profit