public static void main(String[] args) { AlbersEqualAreaEllipse a = new AlbersEqualAreaEllipse(23.0, -96.0, 29.5, 45.5, 0, 0, new Earth(6378137.0, 0.0, 298.257222101)); System.out.printf("proj = %s %s%n%n", a.getName(), a.paramsToString()); //fromProj(a, 1730.692593817677, 1970.917991173046); //toProj(a, 39.089117, -75.649278); fromProj(a, 5747, 13470); }
public static void main(String[] args) { AlbersEqualAreaEllipse a = new AlbersEqualAreaEllipse(23.0, -96.0, 29.5, 45.5, 0, 0, new Earth(6378137.0, 0.0, 298.257222101)); System.out.printf("proj = %s %s%n%n", a.getName(), a.paramsToString()); //fromProj(a, 1730.692593817677, 1970.917991173046); //toProj(a, 39.089117, -75.649278); fromProj(a, 5747, 13470); }
public static void main(String[] args) { AlbersEqualAreaEllipse a = new AlbersEqualAreaEllipse(23.0, -96.0, 29.5, 45.5, 0, 0, new Earth(6378137.0, 0.0, 298.257222101)); System.out.printf("proj = %s %s%n%n", a.getName(), a.paramsToString()); //fromProj(a, 1730.692593817677, 1970.917991173046); //toProj(a, 39.089117, -75.649278); fromProj(a, 5747, 13470); }
public static void main(String[] args) { AlbersEqualAreaEllipse a = new AlbersEqualAreaEllipse(23.0, -96.0, 29.5, 45.5, 0, 0, new Earth(6378137.0, 0.0, 298.257222101)); System.out.printf("proj = %s %s%n%n", a.getName(), a.paramsToString()); //fromProj(a, 1730.692593817677, 1970.917991173046); //toProj(a, 39.089117, -75.649278); fromProj(a, 5747, 13470); }
public void utestAEAE() { testProjectionLonMax(new AlbersEqualAreaEllipse(), 180, 80); AlbersEqualAreaEllipse p = new AlbersEqualAreaEllipse(); AlbersEqualAreaEllipse p2 = (AlbersEqualAreaEllipse) p.constructCopy(); assert p.equals(p2); }
public CoordinateTransform makeCoordinateTransform(NetcdfDataset ds, Variable ctv) { double[] pars = readAttributeDouble2(ctv.findAttribute(CF.STANDARD_PARALLEL)); if (pars == null) return null; readStandardParams(ds, ctv); ucar.unidata.geoloc.ProjectionImpl proj; if (earth != null) { proj = new AlbersEqualAreaEllipse(lat0, lon0, pars[0], pars[1], false_easting, false_northing, earth); } else { proj = new ucar.unidata.geoloc.projection.AlbersEqualArea(lat0, lon0, pars[0], pars[1], false_easting, false_northing, earth_radius); } return new ProjectionCT(ctv.getShortName(), "FGDC", proj); } }
public CoordinateTransform makeCoordinateTransform(NetcdfDataset ds, Variable ctv) { double[] pars = readAttributeDouble2(ctv.findAttribute(CF.STANDARD_PARALLEL)); if (pars == null) return null; readStandardParams(ds, ctv); ucar.unidata.geoloc.ProjectionImpl proj; if (earth != null) { proj = new AlbersEqualAreaEllipse(lat0, lon0, pars[0], pars[1], false_easting, false_northing, earth); } else { proj = new ucar.unidata.geoloc.projection.AlbersEqualArea(lat0, lon0, pars[0], pars[1], false_easting, false_northing, earth_radius); } return new ProjectionCT(ctv.getShortName(), "FGDC", proj); } }
public ProjectionCT makeCoordinateTransform(AttributeContainer ctv, String geoCoordinateUnits) { double[] pars = readAttributeDouble2(ctv.findAttribute(CF.STANDARD_PARALLEL)); if (pars == null) return null; readStandardParams(ctv, geoCoordinateUnits); ucar.unidata.geoloc.ProjectionImpl proj; if (earth != null) { proj = new AlbersEqualAreaEllipse(lat0, lon0, pars[0], pars[1], false_easting, false_northing, earth); } else { proj = new ucar.unidata.geoloc.projection.AlbersEqualArea(lat0, lon0, pars[0], pars[1], false_easting, false_northing, earth_radius); } return new ProjectionCT(ctv.getName(), "FGDC", proj); } }
/** * copy constructor - avoid clone !! */ public ProjectionImpl constructCopy() { return new AlbersEqualAreaEllipse(getOriginLat(), getOriginLon(), getParallelOne(), getParallelTwo(), getFalseEasting(), getFalseNorthing(), getEarth()); }
@Override public ProjectionImpl constructCopy() { ProjectionImpl result = new AlbersEqualAreaEllipse(getOriginLat(), getOriginLon(), getParallelOne(), getParallelTwo(), getFalseEasting(), getFalseNorthing(), getEarth()); result.setDefaultMapArea(defaultMapArea); result.setName(name); return result; }
@Override public ProjectionImpl constructCopy() { ProjectionImpl result = new AlbersEqualAreaEllipse(getOriginLat(), getOriginLon(), getParallelOne(), getParallelTwo(), getFalseEasting(), getFalseNorthing(), getEarth()); result.setDefaultMapArea(defaultMapArea); result.setName(name); return result; }
@Override public ProjectionImpl constructCopy() { ProjectionImpl result = new AlbersEqualAreaEllipse(getOriginLat(), getOriginLon(), getParallelOne(), getParallelTwo(), getFalseEasting(), getFalseNorthing(), getEarth()); result.setDefaultMapArea(defaultMapArea); result.setName(name); return result; }
public GdsHorizCoordSys makeHorizCoordSys() { ProjectionImpl proj; Earth earth = getEarth(); if (earth.isSpherical()) { proj = new ucar.unidata.geoloc.projection.AlbersEqualArea(latin1, lov, latin1, latin2, 0.0, 0.0, earth.getEquatorRadius() * .001); } else { proj = new ucar.unidata.geoloc.projection.proj4.AlbersEqualAreaEllipse( latin1, lov, latin1, latin2, 0.0, 0.0, earth); } LatLonPointImpl startLL = new LatLonPointImpl(la1, lo1); ProjectionPointImpl start = (ProjectionPointImpl) proj.latLonToProj(startLL); return new GdsHorizCoordSys(getNameShort(), template, getOctet4(7), scanMode, proj, start.getX(), dX, start.getY(), dY, getNxRaw(), getNyRaw(), getNptsInLine()); }