John C Cartwright a écrit :
I'm getting a

NoSuchIdentifierException: No transform for classification "Equirectangular"

exception in trying to create a Plate Carree or Equirectangular projected coordinate system. I thought "Plate_Carree" was a valid EPSG identifier, but I'm certain that "Equirectangular" is. Can anyone tell me what I'm doing wrong in the code below. Full stack trace at the end of the message.

The formulas for "Equirectangular" are not yet implemented in Geotools (the transformation formulas need to be implemented in Java, they can't be inferred automatically from the EPSG database). Currently implemented projections can be listed from SVN:

http://svn.geotools.org/geotools/trunk/gt/module/referencing/src/org/geotools/referencing/operation/projection/

On the bright side, adding a new projetion is not really hard. Developpers can copy-and-paste the Mercator.java class in the above-cited link, and replace the transformNormalized(...) and inverseTransformNormalized(...) method body by the new projection code (ported for example from the Proj4 C library). The most tedious (but very important) part is to test the projection.

If there is a volunter on geotools mailing list whiling to send me a Equirectangular.java class with correct transformNormalized(...) methods, and whiling to test it, I would be happy to make the integration in Geotools.

-------------------------------------------------------------------

Note: (to be more accurate)

For building CRS, Geotools take most of its informations in the EPSG database. The most important exception (by far) is the table OperationMethod. Informations that appears in the EPSG OperationMethods table are used, but are not suffisient. The actual method must also be hard coded in Java, since it is about numerical computation. Supported OperationMethods can be listed by the following command line:

java org.geotools.referencing.operation.DefaultMathTransformFactory

Windows users may need to provide an "-encoding 850" argument in order to get a proper output, where "850" is the number displayed by the "chcp" DOS command.

        Martin.


-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to