Hi.
I don't know why, but we have some kind of esoteric logic in our own
code to simplify a circle on the Earth to a bounding box, clearly
something to do with computing geo queries.
double lonMin = -180.0, lonMax = 180.0;
if (!closeToPole(latMin, latMax)) {
double D = SloppyMath.earthDiameter(lat);
double d = D * Math.sin((90.0 - lat) * Math.PI / 180.0); //
diameter of a disk formed by parallel at latitude = lat
double kmPerLonDeg = Math.PI * d / 360.0;
double distanceInLonDeg = distanceKm / kmPerLonDeg;
lonMin = lon - distanceInLonDeg;
lonMax = lon + distanceInLonDeg;
}
This SloppyMath.earthDiameter(latitude) method appears to be gone in
v6.3.0 but I don't see any mention of a replacement in the changelog.
Is there a replacement? Do I just slot in a constant and hope that
nobody notices? I mean, if the maths are supposed to be "sloppy"... :D
TX
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]