[email protected]
[Top] [All Lists]

[Image-SIG] Image-SIG - Convert Tif to PNG

Subject: [Image-SIG] Image-SIG - Convert Tif to PNG
From: "Jeff van Aswegen"
Date: Fri, 3 Aug 2007 13:19:11 +0200
Hi there

I've written a script which converts around 20000 TIFF images to PNG images everyday. The PIL module takes to long and I'm therefore using Imagemagick to perform the conversion. My problem is I need to compress the tiff as much as possible. The best I can do is get a 60kb TIFF Image to around a 100kb PNG image. I can get it down an extra kb or 2 by running it through PNGCrush but this takes way too long. The best command I can come up with is

convert img.tif -monochrome +matte -depth 8 -quality 100 img.png

-rw-r--r-- 1 jeffreyva jeffreyva 59328 2007-08-02 12:09 img.tif
[email protected]:$ time convert img.tif -monochrome +matte -depth 8 -quality 100 img.png

real    0m7.041s
user    0m6.664s
sys     0m0.160s

-rw-r--r-- 1 jeffreyva jeffreyva 99340 2007-08-02 12:10 img.png

Has anyone worked with any utilities or has been successful in converting a TIFF image to a PNG which is almost the same size as the original TIFF?
Look forward to hearing from anyone.


Jeffrey van Aswegen
Image-SIG maillist  -  [email protected]
<Prev in Thread] Current Thread [Next in Thread>
  • [Image-SIG] Image-SIG - Convert Tif to PNG, Jeff van Aswegen <=