Canvas content shift after transform and size changed
Open
Nobody has claimed this yet.
bug :lady_beetle:
- Dominant language
- TypeScript
- Stars
- 12.4k
- Forks
- 2.4k
- PR merge metrics
- No merged PRs in 30d
Description
Environment
- mapbox-gl-js version:
2.14.1and3.2.0 - Browser: Google Chrome 121.0.6167.160
- System: Ubuntu 23.04
Description
Canvas not longer display correctly, when changing size and transform scale to big size (8000px in this case), but DOM based items (Marker) still work fine.
Link to Demonstration
- Minimal Reproduction
- Conrole Group
- I also create a control group which render in same condition but without resize.
- Required run in dev mode.
Expected Behavior
Actual Behavior
Extra information
Looks bug only happen on Blink, those browser work fine:
- Mozilla Firefox 123.0.1
- Epiphany 44.1
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
Start with the linked minimal reproduction and its source repository, then compare the resized and transformed canvas in Chrome with Firefox and Epiphany. The fix is complete when canvas content remains correctly positioned at the reported 8000px size and transform scale in Blink, while DOM markers continue to align.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- computer-graphics, frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100