2007.07.03 18:37 "[Tiff] BigTIFF extension?", by Phil Harvey

2007.07.06 01:46 "Re: [Tiff] 16-Bit-Per-Channel Lossless Compression", by Chris Cox

(sorry this took a while, I've been redoing my compression test code for readability)

processing IMG_2948.Flowers1.pbm width: 3888, height: 2592, channels: 3, 16 bits per sample uncompressed size: 60466176 bytes

RGB, no predictor, interleaved, LZW: 72067928 bytes

RGB, no predictor, interleaved, ZIP: 55539057 bytes

RGB, no predictor, planar, LZW: 68826695 bytes

RGB, no predictor, planar, ZIP: 53133761 bytes YCC1, upLeftMinusMedian diff, bytesplit, planar, ZIP: 27850499 bytes YCC1, MED diff, bytesplit, planar, ZIP: 27852858 bytes

YCC1, paeth2 diff, bytesplit, planar, ZIP: 27981334 bytes

YCC1, paeth diff, bytesplit, planar, ZIP: 28005222 bytes YCC1, avgUpLeft diff, bytesplit, planar, ZIP: 28054460 bytes

All lossless, and I think I can still do better.

Theoretically, because the image is an interpolated result from a Bayer pattern sensor, I should be able to get close to 33% of the uncompressed size, and maybe a little smaller since it's only 14 bits/sample.


On 7/5/07 10:58 AM, "Stephen Carlsen" <sc42business@mac.com> wrote:

Separating 16-bit data into byte planes before compressing seems to be very effective. I get 40,882,548 bytes using the simple approach of applying LZW (with predictor) to the high byte plane and no compression on the low one.

-rw-r--r--   1 sc  sc  60483984 Feb 15 09:20 IMG_2948.Flowers1.tif
-rw-r--r--   1 sc  sc  40882548 Feb 28 14:25 Flowers1.Zap0.BP.LZW+NONE.tif

I am usually have good results with Defalate.

For your file I have:

$ tiffcp -c zip:2 -r 2592 IMG_2948.Flowers1.tif IMG_2948.Flowers1-zip2.tif
$ ls -l IMG_2948.Flowers1*
-rw-r--r-- 1 dron dron 60483984 2007-07-04 22:31 IMG_2948.Flowers1.tif
-rw-r--r-- 1 dron dron 48096986 2007-07-05 14:38 IMG_2948.Flowers1-zip2.tif

So we got 25% here, that is quite good result I think.