mapbox / mapbox-gl-js

Interactive, thoroughly customizable maps in the browser, powered by vector tiles and WebGL
https://docs.mapbox.com/mapbox-gl-js/
Other
11.19k stars 2.22k forks source link

Markers on globes in zoomlevels between 5 and 6 loose their position map edges #13099

Closed tobias-r closed 1 month ago

tobias-r commented 8 months ago

mapbox-gl-js version: 3.1.2 and 3.2.0 beta

browser: Chrome on Mac

Steps to Trigger Behavior

  1. Place a marker on a Mapbox globe (not Mercator) new mapboxgl.Marker({}).
  2. Ideally do it on a map, that is very wide and not too high.
  3. Zoom the map until the zoom level reaches a fractional number between 5 and 6. It occasionally happens, that the zoom levels are fractional, so not rounded to 5 or 6, the bug only occurs on zoomlevels in that range, like 5.3723568348.
  4. When moving the globe map now (by mouse drag), the markers move away from their position at the left and right edge of the map.

Thanks for such a great API.

allencoded commented 5 months ago

Here is a share of this occurring https://jsfiddle.net/6e81ofwr/6/ ... Is there any update on this bug? @tobias-r were you able to bypass this in any fashion?

vbilki commented 1 month ago

Between zoom level 5 and 6, map transit from globe projection to mercator, but markers' positions still calculated for the globe projection. Is there any update on this bug?

found more described issue: https://github.com/mapbox/mapbox-gl-js/issues/13065

stepankuzmin commented 1 month ago

Hi everyone. This is a known issue: https://github.com/mapbox/mapbox-gl-js/issues/13065. I will close this issue so we can track it in one place.