Jump to content

Grass shadow does not match grass alpha


photo

Recommended Posts

Hello,

The grass shadow does not match the grass alpha settings, when using 4 shadow cascade. This leads to a very dark and very visible shadow rectangle that follow the camera on the ground.

It looks like the most precise shadow cascade does not use the correct alpha value for the grass.

image.png.213cceb5d1540515b9213e07f2e8ed2d.png

(here highlighted by using a low alpha value on the grass)

When using 4 shadow cascade, increasing the Cascade Border 0 from 0.008 to 0.03 seems to partially hide the issue, but is somewhat defeats the purpose of having a 4th cascade.

Link to comment

While I'm there: a great addition would be to be able to tune the alpha value for the grass shadow independently from the alpha of the grass itself. More than once I'd like to us a high alpha for the grass, but this leads to too much dark shadows for the grass.

Thank you.

Link to comment

Hi, sorry for the late response on this. I had to check with our artists.

The reason you see this artifact is shadow cascades algorithm we use. With current realization there are three possible workarounds:

  • tweak Bias and Normal bias in LightWorld (sun) settings, but I'm afraid this wouldn't totally solve the issue
  • stay with 1 shadow cascade
  • switch to screen space shadows for grass. This will solve the shadows border issue and reduce the number of rendered polygons.
On 7/5/2018 at 2:50 PM, Amerio.Stephane said:

a great addition would be to be able to tune the alpha value for the grass shadow independently from the alpha of the grass itself

If I got the idea right - you're asking for transparent shadows. We currently don't support any kind of hacks that allow imitating such thing. Using SSRTGI and baked light (Voxel Probe or Environment Probe) will make such dense shadows look much better.

The other issue is the shadow from translucent objects (like grass or leaves). I guess for now in real-time graphics it's almost impossible to render fair shadow from a translucent object.

So I recommend you to try baking light for better shading:  https://youtu.be/tEtWzaq4D4I

Please, let us know if this helps you.

Thanks!

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment
5 hours ago, morbid said:

switch to screen space shadows for grass

How do I do that? I unchecked both Cast Shadows/Cast World Shadows on the grass objects but the shadows is still visible from a distance (very close, it completely disappears, though as I settled for 3 cascade (I don't understand why, though)

5 hours ago, morbid said:

If I got the idea right - you're asking for transparent shadows

While transparent shadows would be really great for all sort of things (rotor!) I actually meant that the shadows could be rendered by using an alpha TEST value different from the alpha TEST value used to display the grass itself. It wouldn't change the opacity of the shadow, but it would change its density.

Now, my concern is that from a distance, it looks like grass has some sort of dark halo, due to screen space shadow:

image.png.fde88c48a9b3fc7245f0a278b54b760d.png

Is there any way to tune it per object ?

Link to comment
21 hours ago, Amerio.Stephane said:

How do I do that? I unchecked both Cast Shadows/Cast World Shadows on the grass objects but the shadows is still visible from a distance

I'm sorry, have you managed to turn on screen space shadows for grass object?

If not, let's check these options:

  • both cast shadows options are disabled in the grass material
  • in LightWorld Screen space shadows should be enabled
  • rendering -> shadows -> screen space shadows option is enabled
21 hours ago, Amerio.Stephane said:

Now, my concern is that from a distance, it looks like grass has some sort of dark halo, due to screen space shadow

You can achieve better visuals by tuning screen space shadows and baking Voxel Probes.

By the way, have you tried other textures for grass object?

If you experiencing some issues with render settings you can send us a test scene.

Thanks!

How to submit a good bug report
---
FTP server for test scenes and user uploads:

Link to comment
×
×
  • Create New...