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
The icon rotation stays in sync with the map (ie. always pointing north). The icon isn't transformed/compressed to 'fit' the pitch.
Actual Behavior
The icon rotation aligns with the map, until any pitch > 0 is introduced, at which point it seems to rotate to ~90 degrees, until pitch is returned to 0. Interestingly, the 'random' rotation (magnitude and direction) seems to be based on the latitude of the center of the map.
Use Case
My use case for this is displaying a location arrow on the map (replay of user paths). The arrow shows recorded bearing information, so needs to point to the correct heading. I'm currently only using the icon-rotation-alignment: map setting, which gives me the expected behaviour, but at high 'cinematic' pitches it can be hard to see as it gets transformed.
The docs don't have any notes about this behaviour as far as I can tell: https://docs.mapbox.com/style-spec/reference/layers/#layout-symbol-icon-pitch-alignment
The text was updated successfully, but these errors were encountered:
mapbox-gl-js version: 3.7.0
browser: Google Chrome
Steps to Trigger Behavior
Link to Demonstration
https://codepen.io/dlbs0/pen/YzmrWyq
Expected Behavior
The icon rotation stays in sync with the map (ie. always pointing north). The icon isn't transformed/compressed to 'fit' the pitch.
Actual Behavior
The icon rotation aligns with the map, until any pitch > 0 is introduced, at which point it seems to rotate to ~90 degrees, until pitch is returned to 0. Interestingly, the 'random' rotation (magnitude and direction) seems to be based on the latitude of the center of the map.
Use Case
My use case for this is displaying a location arrow on the map (replay of user paths). The arrow shows recorded bearing information, so needs to point to the correct heading. I'm currently only using the
icon-rotation-alignment: map
setting, which gives me the expected behaviour, but at high 'cinematic' pitches it can be hard to see as it gets transformed.The docs don't have any notes about this behaviour as far as I can tell: https://docs.mapbox.com/style-spec/reference/layers/#layout-symbol-icon-pitch-alignment
The text was updated successfully, but these errors were encountered: