compressing image data

Kent Paul Dolan xanthian at zorch.SF-Bay.ORG
Fri Sep 7 09:43:12 AEST 1990


Just a quick single data point for the discussion.  I just compressed the
ASCII picture description data "StPauls.dat" that came as part of the
DBKtrace raytracing package recently posted in comp.{sources,binaries}.amiga.
It is highly repetitive data of the kind typical of images (lots of "0000"s).

The original file size was 863,908 bytes.  Compressed with zoo (which uses
Lempel-Ziv compression, I understand, probably 12 bits, considering the
target machines on which it has to unpack), the file compressed to 131,184
bytes (no header, inode, etc. overhead counted before or after); using the
Amiga version of "compress" (almost certainly 14 bits), the output file was
121,048 bytes, while using the recently distributed lharc (in
comp.sources.misc, though I'm using the Amiga version) archiver, which
combines adaptive (I think) Huffman encoding with LZ compression, the same
file compressed to 49,974 bytes!

That is big bucks savings for the net, and the improvement in compressing
general text data (i.e., news) with lharc is almost as incredible.

If that kind of savings hold for a wider range of test data, and for real
raw image pixel data (I have none for a test), that is so spectacular an
improvement that I urge someone to write a utility to take a GIF file,
yank out (decompress) the raw image data, compress it with the algorithm
from lharc and stuff it back in the rest of the GIF wrapper to make a
GIFLZH file (and vice versa) and that that become the net image data
publication and storage format while we look for something even better.

The reason for doing it as a GIF <-> GIFLZH rather than raw <-> GIFLZH
utility is to avoid (for now) invalidating all the GIF viewers in the
universe.  End users with lots of disk space can choose to convert to
GIF for storage and speed of display, while the net and BBSs get the
distribution and storage savings of GIFLZH.

To see if this is worthwhile, I urge anyone with lharc, compress, and a
bunch of raw image data files to do a more comprehensive test and report
back to the net.

Thanks!

Kent, the man from xanth.
<xanthian at Zorch.SF-Bay.ORG> <xanthian at well.sf.ca.us>



More information about the Alt.sources.d mailing list