Version 5.0: Separated map projection and view transform.

This commit is contained in:
ClemensF 2020-03-26 19:08:20 +01:00
parent 53723844a0
commit c7cb2efcdb
47 changed files with 401 additions and 382 deletions

View file

@ -37,13 +37,13 @@ namespace MapControl.Projections
"AUTHORITY[\"EPSG\",\"3395\"]]";
}
public override Vector GetMapScale(Location location)
public override Vector GetRelativeScale(Location location)
{
var lat = location.Latitude * Math.PI / 180d;
var eSinLat = Wgs84Eccentricity * Math.Sin(lat);
var k = Math.Sqrt(1d - eSinLat * eSinLat) / Math.Cos(lat); // p.44 (7-8)
return new Vector(ViewportScale * k, ViewportScale * k);
return new Vector(k, k);
}
}
}