render3d: the shadow array holds only the cascades a fog wall needs, and a thick fog takes the whole sky
A cascade that begins past the wall was fitted and cleared every frame for nothing: the array is now made with the ones that begin inside it (2 at 30 m, 3 at 175 m, 5 without a fog) and made again when the wall changes that count; shadow maps 80 -> 32 MB at 30 m, 48 MB at 175 m. A layer the array lacks clamps to its last, read only past the wall where everything is fogged. The sky: at walls of 110 m and nearer the whole sky is the fog's colour, overhead too, with a soft glow at the sun or moon and no stars or clouds through it, easing out by 175 m; from 175 m on the horizon band alone, and off as before. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
7024f42789
commit
4d485a1778
6 changed files with 40 additions and 3 deletions
|
|
@ -60,6 +60,7 @@ export function r3d_fog_wall(render3d_st: mut Render3dState, dist: float) -> voi
|
|||
render3d_st.sc_view_gen += 1
|
||||
cam_update(render3d_st)
|
||||
fog_impostors(render3d_st)
|
||||
shadow_fog(render3d_st)
|
||||
}
|
||||
# how far anything is drawn: the fog wall and a margin, or `far` (0: no limit of its own) without one
|
||||
function r3d_reach(render3d_st: Render3dState, far: float) -> float {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue