[Geotiff] deskewing

Frank Warmerdam warmerdam at pobox.com
Wed Jan 17 11:17:36 EST 2007


Zoltan Szecsei wrote:
> Hi Frank (and All),
> I have version GDAL 1.2.6.0, released 2005/03/13 of gdalwarp so I 
> haven't downloaded from the pointer above. (I loaded gdal some time back 
> but have not had the time to investigate it yet, which is why I didn't 
> realise I had the tools already)
> 
> My problem is that my images are 1-bit and the output image is 8-bit. 
> How can I keep it as 1-bit and which of the interpolation methods should 
> I use in order to have minimum"damage" to the resampled pixels? (which 
> represent 1:10000 scanned contours)
> 
> I also need a TFW file - but I could probably create my own using 
> tiffinfo and a bit of parsing, so it is not a train-smash.
> 
> I've been trying to find help-docs on writing 1-bit tiffs, but no luck 
> yet. Maybe you could provide some pointers, please?

Zoltan,

GDAL's GeoTIFF driver is currently incapable of producing 1bit files.

You can include the "-co TFW=YES" option on the gdalwarp commandline to
produce a worldfile with the output.

If you use the default nearest neighbour resampling, there will be no
strange mixing of values.  This is generally necessary if you have a
colormapped image as presumably is the case for your 1bit image.

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | President OSGeo, http://osgeo.org



More information about the Geotiff mailing list