I have a tif image file, and a .tfw world file (created from OSM data with Mapertive). How can I (using linux command line) convert that to a GeoTIFF file? (i.e. I want to have one file, not 2). I'm sure it's possible with gdal or something.
2 Answers
So you want a geotiff instead of a tiff with a world file (.tfw). This should be the default in GDAL (http://www.gdal.org/frmt_gtiff.html) so:
gdal_translate -of GTiff input.tif ouput.tif
It will default to geotiff.
-
5You also need to ensure that a coordinate system is set with -a_srs otherwise it is kind of a malformed GeoTIFF.– mdsumnerFeb 25, 2014 at 20:29
-
i don't understand, where in your command do you input the .tfw file? Mar 20 at 14:51
-
GDAL will automatically use a .tfw file. So it is in the same folder as input.tif and called input.tfw. Mar 20 at 17:15
Or you can use geotifcp (http://geotiff.maptools.org/geotifcp.html).
To dump the data from a GeoTiff to a world file try listgeo (http://geotiff.maptools.org/listgeo.html).