Objects and shadows in separate passes

Hi guys

I’m trying to figure out how to render nice shadows for objects that will appear on a website.

My setup is similar to this:

An object with a large floor set as shadow catcher. It seemingly gives pure shadow, without bounce light, which is nice for my purpose.

Now I’d like to control the intensity of the shadow separately in another image tool or even with CSS just lowering the opacity of the shadow pass. But when I enable the shadow catcher pass in the view layer properties, it gives me this:

It contains the red bounce light as well. Which is technically correct, but undesired in my case.

Any tips? Thank you!

Just put a color ramp after the shadow pass. You can adjust the black slider to what value you want to make it less dark e.g.

You can Render both images in separate layers.

1 Like

Of course! Can’t believe I missed the obvious, thank you.

For posterity. This is a tutorial on how to make a shadow “pass” that uses the simplified shadow catcher, which only renders shadows and no light unlike the built-in shadow catcher pass, in a separate layer.

Shadowcatcher-compositing.blend (1.1 MB)

Setup

Make sure you have an Objects collection and a Shadow Catcher collection. Create a linked duplicate of the shadow catcher, Plane in my case, to add bounce light to your object.


image

Set the duplicate’s (Plane.001) visibility to not show to camera and shadow rays.
image

Make sure to enable transparency under film of the render properties
image

Create two render layers: Knockout and Shadows. Hide the shadow catcher collection in the knockout layer and set the Objects collection to only indirect in the Shadows layer.
image
image

Now you have two layers perfect for compositing.
Knockout

Shadows

Composite

1 Like

This would work in the example above, but not with more irregular shapes objects where the bounce light doesn’t fall inside the shadow.