[gdal-dev] gdalwarp creates a bloated file

Cicconetti, Bob BCicconetti at dnr.state.md.us
Fri Dec 21 09:52:32 EST 2007


You'll need either an old version of gdal, or one based on the 1.5.0RC2
binary; the version distributed with QGIS 0.9 works for me.

Adding the following two options to your gdalwarp call should result in
a much smaller TIFF file, but if you are using bilinear or better
resampling, you may want to consider using 2 bits and LZW compression.

-co NBITS=1 -co COMPRESSION=CCITTFAX4

R C

> -----Original Message-----
> From: gdal-dev-bounces at lists.osgeo.org [mailto:gdal-dev-
> bounces at lists.osgeo.org] On Behalf Of Craig Leat
> 
> Hi
> 
> I have a series of georeferenced Tiff images and I need to warp these
> to a north-up orientation. The images are scans of some old sepia
> plans. The files created by gdalwarp are in the order of 200 times
> larger than the original files. Is there anything I can do to limit
> the file size? Maybe limit the colour table to black and white only?
[...]
> Image Structure Metadata:
>   COMPRESSION=CCITTFAX4
> Band 1 Block=13628x512 Type=Byte, ColorInterp=Palette
>   Metadata:
>     NBITS=1


More information about the gdal-dev mailing list