Fix blotchy weather wetness on low-poly meshes/umbrellas #1124

Open
TheSlowly wants to merge 1 commit from TheSlowly/Slipstream:avatar-weather-large-triangles into main
Contributor

Cause: the rest-pose accumulation pass (clean_weather_accum.comp, WX_AC_ACCUM)
sampled one corner per triangle. A canopy panel spans many ~4 cm grid cells, so the
cells between its vertices stayed empty. weatherAvatarAccum fell back to the
per-avatar wetness wherever the filtered occupancy was under kAcOccMin, so the
canopy showed the grid's value around its vertices and the fallback's in between.

Fix: triangles larger than ~0.75 cell now sample an evenly spaced grid of points
over their area (at most 0.75 cells apart, capped at 24 divisions per edge = 325
samples per triangle). Smaller triangles keep the rotating single-corner sample,
so dense meshes like avatar bodies cost about the same; some 2–4 cm body
triangles now get 6 samples instead of 1. The rest box is unaffected (the extra
points lie inside each triangle).

Cause: the rest-pose accumulation pass (clean_weather_accum.comp, WX_AC_ACCUM) sampled one corner per triangle. A canopy panel spans many ~4 cm grid cells, so the cells between its vertices stayed empty. weatherAvatarAccum fell back to the per-avatar wetness wherever the filtered occupancy was under kAcOccMin, so the canopy showed the grid's value around its vertices and the fallback's in between. Fix: triangles larger than ~0.75 cell now sample an evenly spaced grid of points over their area (at most 0.75 cells apart, capped at 24 divisions per edge = 325 samples per triangle). Smaller triangles keep the rotating single-corner sample, so dense meshes like avatar bodies cost about the same; some 2–4 cm body triangles now get 6 samples instead of 1. The rest box is unaffected (the extra points lie inside each triangle).
A worn low-poly umbrella's canopy panels span many ~4 cm grid cells, but
the accumulation pass sampled one corner per triangle, leaving the cells
between the vertices empty. The fragment shader fell back to the
per-avatar wetness there, so the canopy showed the grid's wetness as
soft square blobs around its vertices. Triangles larger than ~0.75 cell
now sample a barycentric lattice over their area (up to 24 divisions per
edge); smaller ones keep the rotating single corner.
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u avatar-weather-large-triangles:TheSlowly-avatar-weather-large-triangles
git switch TheSlowly-avatar-weather-large-triangles

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch main
git merge --no-ff TheSlowly-avatar-weather-large-triangles
git switch TheSlowly-avatar-weather-large-triangles
git rebase main
git switch main
git merge --ff-only TheSlowly-avatar-weather-large-triangles
git switch TheSlowly-avatar-weather-large-triangles
git rebase main
git switch main
git merge --no-ff TheSlowly-avatar-weather-large-triangles
git switch main
git merge --squash TheSlowly-avatar-weather-large-triangles
git switch main
git merge --ff-only TheSlowly-avatar-weather-large-triangles
git switch main
git merge TheSlowly-avatar-weather-large-triangles
git push origin main
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
sky_line/Slipstream!1124
No description provided.