[Geoserver-devel] [jira] Created: (GEOS-2260) Wrong Envelope / CRS loaded from Catalog reader for Coverages

Wrong Envelope / CRS loaded from Catalog reader for Coverages
-------------------------------------------------------------

                 Key: GEOS-2260
                 URL: http://jira.codehaus.org/browse/GEOS-2260
             Project: GeoServer
          Issue Type: Bug
          Components: Configuration
            Reporter: Alessio Fabiani
            Assignee: Alessio Fabiani
            Priority: Critical
             Fix For: 1.7.x, 2.0.x

As can be seen from the snippet below:

        String userDefinedCrsIdentifier = (String)envelope.get( "srsName" );
        String nativeCrsWkt = (String)envelope.get("crs");

        coverage.setSRS(userDefinedCrsIdentifier);
        CoordinateReferenceSystem crs = CRS.parseWKT(nativeCrsWkt);
        coverage.setNativeCRS( crs );
        
        ReferencedEnvelope bounds = new ReferencedEnvelope(
            (Double) envelope.get( "x1" ), (Double) envelope.get( "x2" ),
            (Double) envelope.get( "y1" ), (Double) envelope.get( "y2" ),
            crs
        );
        coverage.setNativeBoundingBox(bounds);

The catalog importer reads the bounds projected in the user defined CRS and associates to them the native CRS, so resulting on a final Coverage Envelope which has wrong coordinates against its CRS.

Of course this error can cuse unexpected GeoServer behavior when threating Rasters.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira