Support user-specified feature z-indexing / sorting across layers
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 12.4k
- Forks
- 2.4k
- PR merge metrics
- No merged PRs in 30d
Description
In Mapnik, [group rendering](https://github.com/mapnik/mapnik/wiki/Grouped-Rendering) is used to render roads in the correct z-order. For background: [@kkaefer's PR](https://github.com/mapnik/mapnik/pull/916). This grouping is declared in Mapbox Studio projects in the yml:
``` yml
_properties:
bridge:
"group-by": layer
```
We are currently ignoring the z-ordering, which is affecting mainly the bridges layers:

What would it take to implement something like this in GL? What would be the performance implications? I'm assuming this also requires a style-spec change. A `group-by` property would need to be defined by data layer, though, not by style layer.
/cc @kkaefer @ansis @1ec5 @jfirebaugh @mourner @ajashton
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 Mapnik grouped-rendering documentation and PR #916, then compare the Mapbox Studio YAML example with the proposed style-spec change. Define the required data-layer `group-by` behavior, cross-layer rendering order, and performance criteria before implementation; the issue is done only when these requirements are specified and validated.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, typescript
- Domain
- computer-graphics, web-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100