You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.
When using mbgl::Map::cameraForLatLngs(const std::vector<LatLng>& latLngs, const Transform& transform, const EdgeInsets& padding) we are calculating the bounds width without taking IDL into account, or in other words, not by the shortest possible path.
Also noticed, that when creating mbgl::LatLngBounds object with mbgl::LatLngBounds::hull, we are always getting a bound that doesn't cross the antimeridian because of the implementation of mbgl::LatLngBounds::extend, unless the values are unwrapped.
#11265 fixed a similar issue for iOS and macOS. mbgl::LatLngBounds has methods like unwrapForShortestPath() to account for ambiguity when spanning the antimeridian. Note that fixing this issue may reveal latent issues in other methods that deal with cameras.
When using
mbgl::Map::cameraForLatLngs(const std::vector<LatLng>& latLngs, const Transform& transform, const EdgeInsets& padding)
we are calculating the bounds width without taking IDL into account, or in other words, not by the shortest possible path.It's reproducible with below Android code:
which gives us this results:
The text was updated successfully, but these errors were encountered: