3D map: the material-table shader without the sticker part #520
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/holdmysocks--SixNG!520
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-520"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@holdmysocks on GitHub · 2026-11-28 01:45 UTC · original
holdmysocks:claude/livery-flat-cost→master· +6 −1 · 1 files · 1 commits · merged 2026-11-28 01:56 UTCWhat
The 3D map's main pass took about 0.5 ms a frame longer since PR 509 (stickers laid on flat). This takes most of it back.
The map's material-table shader is made from the shared mesh shader by text replacements. One more replacement leaves the sticker part of the pixel program out there (
st_nbecomes the constant 0). The map has no stickers, so nothing drawn changes. The shared shader itself is unchanged, so the vehicle viewer draws stickers as before.Where the time goes was measured before choosing this (same view, RTX 4080, 2560x1440, GPU time of the main pass from the map's own tick lines, each figure steady to about 0.05 ms over two or more runs):
So what the vertex program writes costs nothing by itself. The cost comes with the extra code in the sticker part of the pixel program, in every form tried, although the sticker list is empty on the map and that part never runs there. Gating it does not help; leaving it out of the program does.
Checked
cargo test -p sixng-gui: 66 pass, 2 ignored.Not decoded / not done
SIXNG_MAP_GPU_DRAWS=0, or where it is not available) nothing changes: 5.39 ms on master against 4.69 to 4.84 ms before PR 509 on that path. Taking it back there needs a second set of mesh pipelines without stickers, or with them only for models that have some.