Strand hair: no bare patches when a groom is drawn at a distance #467
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!467
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-467"
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-27 06:03 UTC · original
holdmysocks:claude/people-strand-order→master· +64 −5 · 2 files · 1 commits · merged 2026-11-27 06:30 UTCStrand hair: a groom drawn at a distance no longer loses whole areas. Jason's caesar cut (cs_jason looks 4, 8, 9 and 10) showed a bare reddish patch on the crown once the camera was a few metres away.
Cause: past a short distance the viewer draws only the first part of a piece's strands (the game's strand count rule; at about 3 m roughly a sixth). The ray-traced passes also keep the first n. The scattered strands are grown in random order, but the clump members are grown root triangle by root triangle and come after them. So a cut list kept the scattered strands and the first triangles' clumps, and dropped the rest of the scalp. Short scalp pieces such as
103669010(caesar top) are mostly clump members, so the crown went bare and the head skin showed.Change (groom.rs,
Groom::coat_with): the finished coat's strands are put in a fixed shuffled order (a hash of the strand index), with their points, guides, normals, variants and clump numbers moved together. Any first share of them is then spread over the whole piece. The order is the same on every build. The glTF hair export writes the strands in the new order too; their content is unchanged.Verified:
cargo test --release --locked -p sixng-core -p sixng-gui --lib --binspasses. New testa_cut_coat_keeps_every_area: the first fifth of a strip of clumped strands reaches at least 18 of its 20 triangles (in the old order, 4). The hair export test now counts the scattered and clumped strands instead of expecting them in order.#look=4from about 3 m: the bare crown patch is gone and the close-up is unchanged. Before/after renders compared.