Opened 18 years ago

Last modified 18 years ago

#1280 closed defect (fixed)

ECW Projection Translation - linear parameters wrong units

Reported by: warmerdam Owned by: warmerdam
Priority: highest Milestone:
Component: GDAL_Raster Version: unspecified
Severity: normal Keywords:
Cc:

Description

From: Hong Xu


Here is the problem. If the projection's linear unit is in feet, the projection parameter (false easting and false northing) will be wrong. Below is the comparison between ArcGIS 9.1 (with ECW plug-in) and ArcGIS 9.2, the result is the ECW images that have same projection with other data (such as shape file) does not line up with other data in 9.2. Since this breaks the existing application, it would be good to have a fix.

 

 

Same ECW file, read in 9.1

> Projection: Lambert_Conformal_Conic

> Parameters:

>   False_Easting: 6561666.666667

>   False_Northing: 1640416.666667

>   Central_Meridian: -116.250000

>   Standard_Parallel_1: 32.783333

>   Standard_Parallel_2: 33.883333

>   Latitude_Of_Origin: 32.166667

> Linear Unit: Foot_US (0.304801)

> Geographic Coordinate System:

> Name: GCS_North_American_1983

>

>

Read in 9.2 it is

> Projection: Lambert_Conformal_Conic

> false_easting: 2000000.002109

> false_northing: 500000.000451

> central_meridian: -116.250000

> standard_parallel_1: 33.883333

> standard_parallel_2: 32.783333

> latitude_of_origin: 32.166667

> Linear Unit: Foot_US (0.304801)

>

> Geographic Coordinate System: GCS_North_American_1983

Change History (3)

comment:1 by warmerdam, 18 years ago

Hong Xu, 

This is a frequent area of problem in different translators.  It would be
helpful if you could download the FWTools tools from:

  http://fwtools.maptools.org/

And run the "gdalinfo" command against the ecw file, including the
"--debug on" commandline switch. 

If this works properly, there should be a line in the output looking 
something like:

ECW: projection=LOCAL, datum=WGS84

Based on that, I should be able to work out some of the details. 

ECW projection names are turned into OGR style WKT strings using the file
ecw_cs.dat, normally distributed in gdal_data.  I suspect I will need to 
regenerate this file with a corrected understanding of the units of 
projection parameters.  

comment:2 by warmerdam, 18 years ago

Hong gets the following:

ECW: projection=L2CAL6F83, datum=NAD83

comment:3 by warmerdam, 18 years ago

I have altered lookup.py to *not* try and convert the false easting and northings
to meters.  ecw_cs.dat regenerated.  All committed in CVS.

Note: See TracTickets for help on using tickets.