shadows of objects in cloud, but not 100%

Started by Dune, May 19, 2020, 05:51:46 AM

Previous topic - Next topic

Dune

How would you guys do that? I've been experimenting a bit, but am not satisfied yet. I want to have rock outcrops do shadows in a mist layer, as that's the most natural, but also very much liked the mist I had without shadows. So I need a compromise. Two layers immediately get grainy, and I thought there could be a way in lighting a single cloud layer to have say 50% shadow effect. Anyone done that before?

N-drju

I remember we once had a lengthy discussion about adding duplicate sunlights to reduce the soft shadow graininess and it worked great. At a render-time cost of course... So instead of having just one sun powered at 7.5, you made three suns with the power of 2.5 each.

Dirty, I know. But the result was seriously great and smooth. Hard to tell how it's gonna release with PT though... ???
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

N-drju

Another thing you can do is to decrease one of the cloud layer's density by half... Which would, logically, cause the shadow to become less pronounced. Shadow function and direct light modulator may also be useful, though I have never used it before.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

René

Two renders, one with and one without shadow casting in the atmosphere seems to me the simplest way.

N-drju

Hmmm... Or shove an invisible, shadow-casting cube in the place where the shadow is supposed to happen, and disable other shadows.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

René

Or maybe use a 2D shadow map for the clouds because that provides lighter shadows. However, I have no idea if that works.

N-drju

Quote from: René on May 19, 2020, 06:48:46 AMOr maybe use a 2D shadow map for the clouds because that provides lighter shadows. However, I have no idea if that works.

I thought about it too. But then, I got a suspicion that a 2D shadow map may omit the "godray" effect in a volumetric cloud.

I am hardly an expert myself, but I'd think that a two-dimensional shadow is one that you would cast on a surface and forget about - no further light interactions planned.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

cyphyr

#7
Simplest solution I would have thought would be to use a soft shadow on your sunlight.

Or set 1 sunlight (strength 5) to only illuminate surfaces and have a soft shadow radius of 0.5 and 5 sunlights (strength1) set to only illuminate atmosphere and have those with soft shadow diameters of 0.5, 2.5, 5, 7.5 and 10.

This may take a little longer to render ...
www.richardfraservfx.com
https://www.facebook.com/RichardFraserVFX/
/|\

Ryzen 9 5950X OC@4Ghz, 64Gb (TG4 benchmark 4:13)

KyL

I would simply add a second sunlight with surfaces shadows off and light atmosphere/clouds only

Dune

Thanks all for your quick responses. Enough to think about, but I think the latter solution might be easiest, and the first to try.

WAS

#10
Have you tried a max ray depth of 3 (to over compensate for two layers) and upping your voxel scattering quality?

For example, I'm doing an ambient lit scene, no direct light, a single haze layer is noisey as hell, so I had to do voxel scattering quality of 1000, and it's pretty much noiseless even at AA3 for previews. Haze quality was always 1. Though I believe you can exceed maximum quality of a cloud layer. I believe I was using like 5 for my fire.

KyL

Quote from: WAS on May 19, 2020, 02:56:53 PMHaze quality was always 1.

You can probably pump it up to 4. It doesn't add that much render time either. That's what I use all the time.


Also @Dune, is your mist layer a cloud v2 or v3? For your scene you could probably get away with a v2 and "Enable secondary" turned off. This would save a lot of time and probably look very similar.

WAS

Quote from: KyL on May 19, 2020, 03:02:39 PMand "Enable secondary" turned off. This would save a lot of time and probably look very similar.

Hmm, never tried this. Thanks for adding that bit, going to try that in my ambience scene.

Dune

Thanks. It's a v2, as I indeed thought v3 was overkill for simple haze. The extra sun did the trick, I now have a nice mix of a bit of shadow and still the haze in places I liked it. Turning off shadows is another idea, but not really necessary anymore. But I can test if it's really faster. I did increase the propagation mix to 1 at one point to minimize 'self-shadow'.