Equirectangular projection jumps when `render-world-copies` is false.
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**: main
**browser**: Chrome and Firefox
### Steps to Trigger Behavior
1. Make a map with `projection:'equirectangular'`
2. setRenderWorldCopies(false)`
2 Pan off left edge of map.
https://user-images.githubusercontent.com/14878684/201788289-6b51b01e-d28e-4f23-bcd2-8d63df155135.mov
### Expected Behavior
Map should stop moving on the left side, as does Mercator
### Actual Behavior
Map jumps to the right.
This is probably caused by `equirectangular `using the same code paths as non-rectangular projections to determine where to snap. Using the same behavior as Mercator should solve this issue.
Maybe related to https://github.com/mapbox/mapbox-gl-js/issues/11406
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 in Chrome or Firefox with an equirectangular map, render-world-copies disabled, and a pan past the left edge. Inspect the projection snapping paths and compare equirectangular behavior with Mercator and the related issue #11406; done means the map stops at the left edge instead of jumping right.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100