[gdal-dev] SetUTM - how to say how far north Python
Chris English
sglish at hotmail.com
Wed Jun 15 12:24:27 EDT 2011
Hi,
Assuming the following:
>>> src_ds = gdal.Open('test_3.ter')>>> dst_ds = driver.CreateCopy('test_6.hf2', src_ds, 0)>>> dst_ds.SetGeoTransform([582495,1,0.5,4512717,0.5,-1])0>>> srs = osr.SpatialReference()>>> srs.SetUTM(18,1)0>>> srs.SetWellKnownGeogCS('WGS84')0>>> dst_ds.SetProjection( srs.ExportToWkt())0>>> dst_ds = None>>> src_ds = None>>> gdalinfo.main(['foo','test_6.hf2'])Driver: HF2/HF2/HFZ heightfield rasterFiles: test_6.hf2 test_6.hf2.aux.xmlSize is 4, 4Coordinate System is:PROJCS["UTM Zone 18, Northern Hemisphere", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS 84",6378137,298.257223563, AUTHORITY["EPSG","7030"]], TOWGS84[0,0,0,0,0,0,0], AUTHORITY["EPSG","6326"]], PRIMEM["Greenwich",0, AUTHORITY["EPSG","8901"]], UNIT["degree",0.0174532925199433, AUTHORITY["EPSG","9108"]], AUTHORITY["EPSG","4326"]], 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["Meter",1]]Origin = (0.000000000000000,0.000000000000000)Pixel Size = (1.000000000000000,1.000000000000000)Metadata: VERTICAL_PRECISION=1.000000Corner Coordinates:Upper Left ( 0.0000000, 0.0000000) ( 79d29'19.48"W, 0d 0' 0.01"N)Lower Left ( 0.0000000, 4.0000000) ( 79d29'19.48"W, 0d 0' 0.13"N)Upper Right ( 4.0000000, 0.0000000) ( 79d29'19.35"W, 0d 0' 0.01"N)Lower Right ( 4.0000000, 4.0000000) ( 79d29'19.35"W, 0d 0' 0.13"N)Center ( 2.0000000, 2.0000000) ( 79d29'19.41"W, 0d 0' 0.06"N)Band 1 Block=256x1 Type=Float32, ColorInterp=Undefined Unit Type: m0>>>
and assuming I wanted to be nearly in New York rather than La Concordia Peru,how to say 'how far north'?
Thanks in advance,
Chris
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20110615/167d9689/attachment-0001.html
More information about the gdal-dev
mailing list