How to colorize Eevee shadows?

Hi,

in cycles, I can colorize an objects shadow by Mixing a diffuse and transparent shader with IsShadowRay as factor (like here https://blender.stackexchange.com/questions/69709/how-to-change-the-shadow-color-in-blender-cycles).

Doing the same in Eevee does nothing. How can I change the color of the shadow in Eevee?

Not possible…

Bummer… thanks.

Unfortunately availability of Light Path node in Eevee is quite limited. However you can use a trick with Shader to RGB node in material to get the effect you want (You can change color of diffuse shader/shadow):


BwpZTdfXWa
Color ramps and other masking elements may change depending on your scene and setup.

Check this video:

4 Likes

Thank you, working great!

1 Like

Unfortunately this only allows all shadows to be the same color. Is there a way for Eevee to have different shadow colors for different objects? (e.g. green monkey casts green shadow and red monkey casts red shadow)

In Blender 4.0, doesn’t work anymore :frowning:

@CG-Man Works for me in 4.2 version. You can take a look at the file:
shader_to_rgb.blend (991.0 KB)

However it’s quite weird that “Is Shadow Ray” in light path node still not working properly even though Blender manual indicates that it should work in Eevee.

Ah, thank you!