Package org.opengis.referencing.cs

Examples of org.opengis.referencing.cs.CoordinateSystem


            //
            final Object rx = kvp.get("resx");
            final Object ry = kvp.get("resy");
            if (rx != null && ry != null) {
                // get resx e resy but correct also the sign for them taking into account
              final CoordinateSystem cs=crs.getCoordinateSystem();
              final AxisDirection northingDirection=cs.getAxis(1).getDirection();
              final int yAxisCorrection=AxisDirection.NORTH.equals(northingDirection)?-1:1;
              final AxisDirection eastingDirection=cs.getAxis(0).getDirection();
              final int xAxisCorrection=AxisDirection.EAST.equals(eastingDirection)?1:-1;
                final double resX = Double.parseDouble((String) rx)*xAxisCorrection;
                final double resY = Double.parseDouble((String) ry)*yAxisCorrection;
               
                // basic check, the resolution cannot be larger than any of the two spans
View Full Code Here


            upper = upper + geometry.getGridRange().getHigh(i) + " ";
        }
        writer.write("<grid dimension = \"" + dimensions + "\">\n");
        writer.write("<low>" + lower + "</low>\n");
        writer.write("<high>" + upper + "</high>\n");
        final CoordinateSystem cs = crs.getCoordinateSystem();
        for (int i=0; i < cs.getDimension(); i++) {
            writer.write("<axisName>" + cs.getAxis(i).getName().getCode() + "</axisName>\n");
        }
        if(geometry.getGridToCRS() instanceof AffineTransform) {
            AffineTransform aTX = (AffineTransform) geometry.getGridToCRS();
            writer.write("<geoTransform>");
                writer.write("<scaleX>" + aTX.getScaleX() + "</scaleX>\n");
View Full Code Here

TOP

Related Classes of org.opengis.referencing.cs.CoordinateSystem

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.