[gdal-dev] gdal_translate -a_srs
Frank Warmerdam
warmerdam at pobox.com
Sat Jul 3 10:10:18 EDT 2010
Greg Coats wrote:
> gdal_translate -a_srs provides for the output file to be in a different projection than the input file.
> What is the syntax for telling gdal_translate -a_srs to use the projection shown by gdalinfo to be used in the GeoTiff below, which is NAD 1983, UTM Zone 18N?
Greg,
One approach is to just copy the coordinate system portion, as
below into a text file, perhaps "desired.wkt" and then
do:
gdal_translate -a_srs desired.wkt in.tif out.tif
PROJCS["NAD83 / UTM zone 18N",
GEOGCS["NAD83",
DATUM["North_American_Datum_1983",
SPHEROID["GRS 1980",6378137,298.2572221010002,
AUTHORITY["EPSG","7019"]],
AUTHORITY["EPSG","6269"]],
PRIMEM["Greenwich",0],
UNIT["degree",0.0174532925199433],
AUTHORITY["EPSG","4269"]],
PROJECTION["Transverse_Mercator"],
PARAMETER["latitude_of_origin",0],
PARAMETER["central_meridian",-75],
PARAMETER["scale_factor",0.9996],
PARAMETER["false_easting",500000],
PARAMETER["false_northing",0],
UNIT["metre",1,
AUTHORITY["EPSG","9001"]],
AUTHORITY["EPSG","26918"]]
You can also pass the entire WKT string on the commandline but that tends to
be difficult to quote and to remove the newlines.
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 | Geospatial Programmer for Rent
More information about the gdal-dev
mailing list