Opened 12 years ago
Closed 12 years ago
#4296 closed defect (invalid)
gdalwarp assumes usage of WGS84 elipsoid when WGS84 datum is used.
Reported by: | zekonja | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | default | Version: | unspecified |
Severity: | normal | Keywords: | |
Cc: |
Description
- Add coordinate system information into tiff file
gdalwarp -t_srs "+proj=tmerc +lat_0=0 +lon_0=45 +k=1 +x_0=8500000 +y_0=0 +ellps=krass +datum=WGS84 +units=m +no_defs " -of GTIFF -co TILED=YES -co COMPRESS=LZW -co TFW=YES -co PROFILE=GeoTIFF 11-38-125-1-2-2.tif 11-38-125-1-2-2_GT.tif
Output:
Creating output file that is 13086P x 11481L. Processing input file 11-38-125-1-2-2.tif. 0...10...20...30...40...50...60...70...80...90...100 - done. 2. Get information about output file gdalinfo 11-38-125-1-2-2_GT.tif Driver: GTiff/GeoTIFF Files: 11-38-125-1-2-2_GT.tif 11-38-125-1-2-2_GT.tfw Size is 13086, 11481 Coordinate System is: PROJCS["unnamed", GEOGCS["WGS 84", DATUM["WGS_1984", SPHEROID["WGS 84",6378137,298.257223563, AUTHORITY["EPSG","7030"]], AUTHORITY["EPSG","6326"]], PRIMEM["Greenwich",0], UNIT["degree",0.0174532925199433], AUTHORITY["EPSG","4326"]], PROJECTION["Transverse_Mercator"], PARAMETER["latitude_of_origin",0], PARAMETER["central_meridian",45], PARAMETER["scale_factor",1], PARAMETER["false_easting",8500000], PARAMETER["false_northing",0], UNIT["metre",1, AUTHORITY["EPSG","9001"]]] Origin = (8431150.320000000298023,4503947.389999999664724) Pixel Size = (0.407170801000005,-0.407170801000005) Metadata: AREA_OR_POINT=Area Image Structure Metadata: COMPRESSION=LZW INTERLEAVE=BAND Corner Coordinates: Upper Left ( 8431150.320, 4503947.390) ( 44d11' 8.74"E, 40d40' 2.34"N) Lower Left ( 8431150.320, 4499272.662) ( 44d11'10.59"E, 40d37'30.81"N) Upper Right ( 8436478.557, 4503947.390) ( 44d14'55.57"E, 40d40' 3.88"N) Lower Right ( 8436478.557, 4499272.662) ( 44d14'57.27"E, 40d37'32.34"N) Center ( 8433814.439, 4501610.026) ( 44d13' 3.04"E, 40d38'47.36"N) Band 1 Block=256x256 Type=Int16, ColorInterp=Gray
As it can be seen from output coordinate system isn't written properly. Insted of elipsoid Krasowsky elipsoid WGS84 is written. It seems that gdal assumes usage of WGS84 elipsoid when WGS84 datum is used.
Additional info:
gdalwarp --version
Output:
GDAL 1.8.0, released 2011/01/12
Tiff file is not attached since it has 147 MB. I believe you can reproduce it on any tiff file.
Please fix the bug.
Note:
See TracTickets
for help on using tickets.
It is not a bug. Look at your -t_srs option : "+ellps=krass +datum=WGS84". The +datum will override the +ellps. And when you set a datum, it also imposes the ellipsoid used. You cannot ask for WGS84 datum and krass ellipsoid at the same time.