mapbox / mapbox/mapbox-gl-js

Batched models visualisation error

Open
#13,108 4 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

When using custom batched models (I know it's not really supported yet, but anyway...) in Mapbox GL JS v3.2.0 I *sometimes* observe wrong triangle visualization.

![image](https://github.com/mapbox/mapbox-gl-js/assets/538812/a672bbe7-58be-4c1f-85e4-9a2d433c1f46)

Demo: https://bertt.github.io/mapbox_issues/triangles_wrong/issue/

I've got the feeling it's related to Draco compression in some geometry (couldn't isolate it more yet).

The used glTF model is visualized well in for example 3D Viewer: https://3dviewer.net/#model=https://bertt.github.io/mapbox_issues/triangles_wrong/issue/content/15-16914-10992.glb

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 linked demo and the provided 15-16914-10992.glb model, then compare the batched-model rendering with the 3D Viewer result. Investigate whether Draco-compressed geometry produces the incorrect triangles; done means the supplied model renders with correct triangle geometry in Mapbox GL JS.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.