private static void test(double lat, double lon) { double radius = 6371.0; VerticalPerspectiveView a = new VerticalPerspectiveView(0, 0, radius, 5.62 * radius); ProjectionPointImpl p = a.latLonToProj(lat, lon); System.out.println("-----\nproj point = " + p); System.out.println("x/r = " + p.getX() / radius); // see snyder p 174 System.out.println("y/r = " + p.getY() / radius); LatLonPoint ll = a.projToLatLon(p); System.out.println(" lat = " + ll.getLatitude() + " should be= " + lat); System.out.println(" lon = " + ll.getLongitude() + " should be= " + lon); }
private static void test(double lat, double lon) { double radius = 6371.0; VerticalPerspectiveView a = new VerticalPerspectiveView(0, 0, radius, 5.62 * radius); ProjectionPoint p = a.latLonToProj(lat, lon); System.out.println("-----\nproj point = " + p); System.out.println("x/r = " + p.getX() / radius); // see snyder p 174 System.out.println("y/r = " + p.getY() / radius); LatLonPoint ll = a.projToLatLon(p); System.out.println(" lat = " + ll.getLatitude() + " should be= " + lat); System.out.println(" lon = " + ll.getLongitude() + " should be= " + lon); }
private static void test(double lat, double lon) { double radius = 6371.0; VerticalPerspectiveView a = new VerticalPerspectiveView(0, 0, radius, 5.62*radius); ProjectionPointImpl p = a.latLonToProj(lat, lon); System.out.println("-----\nproj point = " + p); System.out.println("x/r = " + p.getX()/radius); // see snyder p 174 System.out.println("y/r = " + p.getY()/radius); LatLonPoint ll = a.projToLatLon(p); System.out.println(" lat = "+ll.getLatitude()+ " should be= " + lat); System.out.println(" lon = "+ll.getLongitude()+ " should be= " + lon); }
private static void test(double lat, double lon) { double radius = 6371.0; VerticalPerspectiveView a = new VerticalPerspectiveView(0, 0, radius, 5.62 * radius); ProjectionPoint p = a.latLonToProj(lat, lon); System.out.println("-----\nproj point = " + p); System.out.println("x/r = " + p.getX() / radius); // see snyder p 174 System.out.println("y/r = " + p.getY() / radius); LatLonPoint ll = a.projToLatLon(p); System.out.println(" lat = " + ll.getLatitude() + " should be= " + lat); System.out.println(" lon = " + ll.getLongitude() + " should be= " + lon); }