PDA

View Full Version : Shadow Catcher: best approach to neutralize existing shadows in BG image with nodes?



vncnt
09-30-2018, 06:10 AM
When using Shadow Catcher, virtual shadows are added to the BG image sequence (multiple frames!).
In case real and virtual shadows overlap, the intensity of the shadow is also doubled.

What would be the best approach, with Layout nodes, for excluding existing shadows in BG image sequences and prevent double intensity shadows?

MonroePoteet
09-30-2018, 04:12 PM
I'm definitely no expert, but I think it would be very difficult, if not impossible, for a node network to be smart enough to recognize the shadows on the background sequence. For example, if part of the ground is wet, it will be darker than the surrounding ground, but it's NOT in a shadow. If a shadow passes over the wet part of the ground, its darkeness would be "compounded", similar to doubling the shadows. As well, I think differentiating between a light-blue object in shadows vs. a dark-blue object that's lit would be troublesome in any sort of attempt to use luma or relative brightness to recognize the shadows.

The only time I've done this I created a shaped "shadow catcher" object (although I use Shadow Density=>Alpha) shaped to the lighted area of the floor with a little overlap into the shadows, applied a fuzzy edge to it with an Image map on Transparency, and rotoscoped the object to match the camera motion. This was relatively simple since the lighting on the floor was coming from a window with a reasonably sharp edge to the lighted area and the camera motion was minimal.

I sure wouldn't want to try it with (for example) shadows from leaves moving in the wind on the ground!

mTp

Imageshoppe
09-30-2018, 07:01 PM
I've done this, but only in post using Fusion for compositing... signed add is the best way to get a rendered B&W shadow pass to combine with the values of the plate in such a way to not "double add" to the shadow, and it only works in a few cases. This process, of overlapping fake and real shadows, is a relatively protected and not talked about area in the bag of tricks of advanced compositing folks...

As example, in this commercial I shot and did the VFX for a few years back you can see this in action at around 14secs... the trailer behind the pickup is LW, and the radiosity info and shadow interacts with the shadow from the real pickup in a more (or less) convincing way...

https://www.youtube.com/watch?v=Dju6NFrbzT0

Regards,

vncnt
10-01-2018, 02:34 AM
I'm definitely no expert, but I think it would be very difficult, if not impossible, for a node network to be smart enough to recognize the shadows on the background sequence.
I was thinking of building objects that cast a negative shadow (maybe with a negative light, exclusive to that object) that can be fed to the Shadow Catcher node.

I'll run some tests with this type of setup.

vncnt
10-01-2018, 02:40 AM
I've done this, but only in post using Fusion for compositing... signed add is the best way to get a rendered B&W shadow pass to combine with the values of the plate in such a way to not "double add" to the shadow, and it only works in a few cases. This process, of overlapping fake and real shadows, is a relatively protected and not talked about area in the bag of tricks of advanced compositing folks...

As example, in this commercial I shot and did the VFX for a few years back you can see this in action at around 14secs... the trailer behind the pickup is LW, and the radiosity info and shadow interacts with the shadow from the real pickup in a more (or less) convincing way...

https://www.youtube.com/watch?v=Dju6NFrbzT0

Regards,
Very nice clip (!) and in general nice shadows.

Did you miss a spot at +/- 9s -> 10s? The shadow caused by the back of the trailer seems to be on top of the real shadow, caused by a tree.

MonroePoteet
10-01-2018, 08:26 AM
I was thinking of building objects that cast a negative shadow (maybe with a negative light, exclusive to that object) that can be fed to the Shadow Catcher node.

I'll run some tests with this type of setup.

If you're going to build shadow-casting objects, it may be easier to just substitute the entire ground plane (and any 3D objects receiving shadows as required) rather than the negative shadows. In order to "negate" the existing shadows, the shadow-casting objects would have to be exacting or you'd end up with lighter or darker borders on the BG shadows, whereas substituting the entire ground plane, etc., I think the shadow-casting objects would just have to be "close enough" to simulate whatever was casting real-life shadows in the BG sequence.

As I said, I'm sure no expert though!

mTp

Imageshoppe
10-01-2018, 08:59 AM
Very nice clip (!) and in general nice shadows.

Did you miss a spot at +/- 9s -> 10s? The shadow caused by the back of the trailer seems to be on top of the real shadow, caused by a tree.

Thanks, at that point, the trailer and the truck are both real, no CGI at all, so only nature is to blame... :)

A general observation... this problem is solved day in and day out, hundreds if not thousands of shots in feature films doing it well, but it is very closely held basket of tricks by compositors and I'm certain there's no "one way" to approach it... I've never seen a tutorial or demo of anyone's specific or general approach to this over the years, and I've been looking. I think overall it is an issue for compositing, and beyond generating the shadow/occlusion/radiosity passes will be handled after the render in your compositing program of choice. Over the years I've been a person who has tried to do everything regarding comping a shot in LW, to doing nothing, back to doing as much as possible, and then back to the middle... this is one of those things that can't be solved to your satisfaction in LW exclusively...