Page 1 of 1

How to get correct layer shadow

Posted: Fri Apr 17, 2020 11:04 am
by designandcode
I've been trying to render a Layer Shadow Pass with no success - i keep getting wrong results.

cylinder-01.jpg
This is my beauty render - I want to render the cylinder separately so I can place it on an even red background in Photoshop. I'm trying to render out a render layer shadow pass for that, but it looks completely wrong.

I'm using the following settings:
"Render Layer Setup" is enabled, I'm rendering Layer 1
Cylinder is on Layer 1
Background is Layer 2
Alpha Shadow is enabled
Scene is lit by an HDR in a texture environment

cylinder-01-shadow.jpg
This is what the shadow pass looks like - there's an entire extra section of shadow in front of the cylinder that shouldn't be there.

If i disable "Alpha Shadow", this is what I get:
cylinder-01-shadow-no-alpha.jpg
I get the correct shadow below the cylinder, but also get the entire environment shadow for the background - this is not what I want. I only want the shadow that layer 1 (the cylinder) is throwing on to layer 2 (the background!)
Additionally, when I comp this back in in Photoshop, the entire thing is far too dark.

Can someone please explain how I can get the correct shadow here? What am I doing wrong?

Re: How to get correct layer shadow

Posted: Fri Apr 17, 2020 1:45 pm
by paride4331
Hi designandcode,
I would not use shadow pass compositing in your case, I would recommend you to use and shadow catcher and render layer on the fly.
https://docs.otoy.com/StandaloneH_STA/S ... Passes.htm
Regards
Paride

Re: How to get correct layer shadow

Posted: Wed Apr 22, 2020 12:36 pm
by designandcode
paride4331 wrote:Hi designandcode,
I would not use shadow pass compositing in your case, I would recommend you to use and shadow catcher and render layer on the fly.
https://docs.otoy.com/StandaloneH_STA/S ... Passes.htm
Regards
Paride
Hi Paride, thank you but that doesn't work either.
cylinder-shadowcatcher2.jpg
I've done a lot of testing over the past days and I cannot find a way to set this up to just get the layer shadows I need. I've compiled a big image for info with everything I've tried.
layer-shadow-issues.jpg
1) Scene setup, with a pretty normal environment for product rendering scenes - there is a 360 degree HDR lighting the scene, and some of the light is being blocked by the background plane
2) Beauty Render -behaves as expected with light from behind plane blocked
3) Layer Shadows - this seems wrong? I have it set to Layer 1, so I'd expect to see only the shadows that Layer 1 (Cylinder) are throwing on to Layer 2 (Plane), instead I also get the shadows that Layer 2 (Plane) throws on to itself?
4) Layer Shadows with Alpha Shadow enabled - ignores the background plane blocking the light behind the cylinder
5) With Shadow Catcher Material applied to Background Plane - ignores light being blocked
6) With Shadow Catcher Material applied to extra plane below cylinder - completely unusable

Is this how it is supposed to work? It seems insane to me that I cannot get a simple shadow pass from an object with correct lighting information just because some of the light is being blocked?

Is there any way to get what I need here, or is it just impossible?

Re: How to get correct layer shadow

Posted: Thu Apr 23, 2020 2:07 pm
by paride4331
Hi designandcode,
what you say makes sense, but that's how it is.
Try to take a look at my screeshot.
I hope it helps.