Ignore:
Timestamp:
2016-01-23T14:11:05+01:00 (4 years ago)
Author:
bastiK
Message:

fix bounds that are too large and make tests fail (see #12186)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/projection/proj/SwissObliqueMercator.java

    r9124 r9579  
    4343    private double b0;
    4444    private double k;
     45    private double phi0;
    4546
    4647    private static final double EPSILON = 1e-11;
     
    5556
    5657    private void initialize(double lat_0) {
    57         double phi0 = toRadians(lat_0);
     58        phi0 = toRadians(lat_0);
    5859        kR = sqrt(1 - ellps.e2) / (1 - (ellps.e2 * pow(sin(phi0), 2)));
    5960        alpha = sqrt(1 + (ellps.eb2 * pow(cos(phi0), 4)));
     
    118119    @Override
    119120    public Bounds getAlgorithmBounds() {
    120         return new Bounds(-85, -179, 85, 179, false);
     121        if (phi0 > 0) {
     122            return new Bounds(-10, -40, 85, 40, false);
     123        } else {
     124            return new Bounds(-85, -40, 10, 40, false);
     125        }
    121126    }
    122127}
Note: See TracChangeset for help on using the changeset viewer.