Use center latitude for getLonLatToMeters calls
This commit is contained in:
parent
34f5258f5e
commit
e0259e4cde
1 changed files with 1 additions and 1 deletions
|
@ -346,7 +346,7 @@ abstract class OsmPath implements OsmLinkHolder
|
|||
if ( rc.startDirectionValid )
|
||||
{
|
||||
double dir = rc.startDirection.intValue() / CheapRulerSingleton.DEG_TO_RAD;
|
||||
double[] lonlat2m = CheapRulerSingleton.getLonLatToMeterScales( lat1 );
|
||||
double[] lonlat2m = CheapRulerSingleton.getLonLatToMeterScales( (lon0 + lat1) >> 1 );
|
||||
lon0 = lon1 - (int) ( 1000. * Math.sin( dir ) / lonlat2m[0] );
|
||||
lat0 = lat1 - (int) ( 1000. * Math.cos( dir ) / lonlat2m[1] );
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue