mapbox / mapbox/mapbox-gl-js

Gaps in terrain when foreground is close to camera

Open
#10,505 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

3d :triangular_ruler: bug :lady_beetle:
Dominant language
TypeScript
Stars
12.4k
Forks
2.4k
PR merge metrics
No merged PRs in 30d

Description

**mapbox-gl-js version**: v2.1.1 (also observed in `main`)

**browser**: Chrome 89.0.4389.90

### Steps to Trigger Behavior

1. Load 3D terrain and position close foreground hills in the center of the frame, e.g. `#16.58/36.531884/-118.455046/9.6/72`, http://localhost:9966/debug/3d-playground.html#16.58/36.531884/-118.455046/9.6/72

### Link to Demonstration

https://codepen.io/rsreusser/pen/KKadvKP

![Screen Shot 2021-03-24 at 5 40 06 PM](https://user-images.githubusercontent.com/572717/112402114-26ab2e80-8cc9-11eb-98db-16f54ab209dd.jpg)

### Expected Behavior

Gaps, if present, don't exceed the skirt size.

### Actual Behavior

Gaps are sometimes quite large and obvious. Seems persistent across different aspect ratios.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the 3D terrain playground URL in the reproduction steps and compare it with the linked CodePen, using the stated camera position and foreground hills. Investigate the terrain rendering behavior near the camera and verify the result across aspect ratios. Done means visible gaps do not exceed the skirt size.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
computer-graphics, frontend, web-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.