Vehicles: palette rows from their own slice, surface blend from the material map #85
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!85
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/85/head"
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-23 22:20 UTC · original
holdmysocks:claude/palette-slices→master· +94 −46 · 2 files · 1 commits · merged 2026-11-23 22:31 UTCApplies the shader session's vehicle paint findings (its write-up sections 3, 5, 6, 8) to the export, so the viewer shows them.
What
19df25d7is an array of 8 slices of 128 x 256. A colour record's page (adb52ec3, until now read as a "mode": 1 = paint, 3 = fixed material) is the slice its row (c8313558) belongs to. The export decodes all slices and reads a part's row from the slice of its page. Until now rows were read from slice 0, which holds different ramps (and runs dark to bright where slices 1, 2, 3, 5 run bright to dark).metalLow/metalHigh/roughnessLow/roughnessHighof the surface's range record were already read; the blend between low and high is now the mean red / green of the model'slyr0materialatextextures instead of the midpoint.part_colours_version7, so the viewer exports vehicles again on first open.Checked
cargo test -p sixng-core -p sixng-gui: 156 passed.Not decoded / not done
lyr0diffusetex), not one per pixel, and the same value for the fitted wheels. With rows now running bright to dark this matters more than before.2cc72f7c,174770cc); which applies where is not known. The first is used.lyr0materialatextextures look like normal maps by their means (about 0.45, 0.55, 0.9), so the blend stays close to the midpoint; that it is the texture the shader blends by rests on the slot name.albedoSelection/albedoPage(slices 0, 4, 5), and what the game writes into the near-black rows at run time.