Closed clarisma closed 8 months ago
Use a different calculation: convert y back to lat, then calculate 1 / cos(lat)
Partially responsible for #20.
Also affects Java.
No, not a bug.
1 / std::cos(latFromY(y) * M_PI / 180.0)
and
std::cosh(y * 2.0 * M_PI / MAP_WIDTH)
are equivalent up to the max mercator latitude (85.0511)
Use a different calculation: convert y back to lat, then calculate 1 / cos(lat)
Partially responsible for #20.
Also affects Java.