Recently I’ve seen some blender games that have large landscapes that look dull and boring just because of the lack of shadows. So, here’s my first try to create non-overlapping shadow cascades with a dynamic day/night cycle (shadows only cycle) and no cascade overlapping. I’ve used some basic vector maths to make the cascades behave as they should and follow the camera correctly.
There is 1 main sun lamp that controls that’s basically the light source (called MainSun), and 4 shadow-only sun lamps for the cascades. and there are few pink cubes parented to each lamp just for visualization, and an almost transparent huge plane slightly above the ground that’s simply just for casting shadows to show if anything is overlapping.
(I know that this is nothing close to the actual concept and implementation of cascaded shadow maps, but atleast it works as it should ! )
press Space to rotate the main sun , D to rotate the camera.
cascades.blend (571 KB)