"Progressive-Shadows" a vanilla js implementation of r3F AccumulativeShadows

After many trials a vanilla three js implementation of r3f’s cool AccumulativeShadows is finally ready !

demo links
https://vis-prime.github.io/progressive-shadows/?scene=simple
https://vis-prime.github.io/progressive-shadows/?scene=rx7

github

Video

huge thanks to @drcmda for the help

11 Likes

Nice soft shadows. Look more natural.

In some special conditions the shadows look strange. One example is the shadow near the vertical edge facing the camera (the light is on the opposite side) – the corner shadow is weaker than the shadow next to the walls. Maybe it is because the lights are uniformly distributed within the lightRadius range. Would a bell-shape distribution make a more natural shadow?

i can replicate the issue
light radius just adds a random value to x,y,z,

I’ll setup a code sandbox so we can experiment

Added option to save shadow as a png image

alphaTest logic on saved image is not added yet

3 Likes