Changing zoom value when using 3D terrain leads to layers jittering
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 12.4k
- Forks
- 2.4k
- PR merge metrics
- No merged PRs in 30d
Description
mapbox-gl-js version: Version used in studio.mapbox.com
browser: Google Chrome (newest version)
Steps to Trigger Behavior
- Create map style in Mapbox Studio with 3D terrain enabled (
- Zoom map to some mountains (with a zoom value where some layers change their properties)
- Drag the map away form the mountain and back to the mountain
- Notice the zoom level changing just by dragging the map
- Notice the layer presentation change between lower and higher detail
Link to Demonstration
https://media.giphy.com/media/Mr224WIgAEzS4XYgX9/giphy-downsized-large.gif
Expected Behavior
When dragging the map the layer appearance should not change.
Wouldn't it make sense that the zoom level is not affected by the terrain height at the current viewpoiont? The zoom level could be calculated on sea level or at least from a very basic height information where all "sudden" height changes like mountains are averaged out.
This way the layers would not jump between their lower and higher detail views. This would lead to a clean presentation without jitter.
Actual Behavior
When dragging the map the layers are affected by the zoom value change and therefore change their appearance. This leads to jitter when dragging the map over the threshold multiple times.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with a Mapbox Studio style using 3D terrain, then drag the map away from and back toward mountains while watching the zoom and layer detail changes. Compare the observed jitter with the expected stable layer appearance; done means dragging no longer causes layers to cross detail thresholds unexpectedly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript
- Domain
- frontend, web-dev
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100