Jump to content

Bad looking shadow contour on surface with normal map


photo

Recommended Posts

Posted

Hi,

I have a recurring critic from our users about the visual aspect of shadow contour on surface with a normal map.

As an example, here is a flat surface with 0 specularity, 0 metalness, 1 roughness:

with no normal map: image.png.c7a121359abe59da2c18e952cb0a2bf8.png

with normal map activated: image.png.9d0f1025b23fb512ebd6b9239c1f56ee.png

 

In the fully shadowed area, the normal map effect is null as expected. But as you can see, in the penumbra area, the normal make the surface looks strangely lit, as if some bumps were fully lit. From a distance, it makes the surface look glossy or like jelly and it can be very disturbing, as if the normal map was very exaggerated.

I compared with UnrealEngine in similar condition and the same textures: the penumbra is always smooth...

image.png.c03ad38f057db16db471d7382490ce94.png

How can this be improved, without getting rid of the normal mapping of course?

Thanks!

 

Posted

Hi Stephane,

Is that cropped view from a bigger image or it needs to be displayed as is in your application (with a rectangular shape)?

Could you please send us a small reproduction scene with your actual rendering settings (basically .world where you doing this tests) with your test content (FBX with textures)? Right now it's not completely clear if there anything we can do about it.

Screenshot from UE looks like there is no any normal applied at all (too flat). If that's the case, you can adjust Normal Intensity in material settings and reduce normal texture influence on lighting.

Thanks!

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

Posted

These are cropped, close up image of the contour. And the Unreal version definitively has normal enabled (would be obvious with specularity enabled).

Actually, I was investigating this issue because our tree shadows contour are very "jelly", on a landscape with a normal map. So I tried with just plain normal map on a plain object and got similar effects, albeit only visible on close up.

So, back to my main issue: shadow contour on tree on terrain. I set up a small demo (attached), with varying lights parameters and here is what I found:

- I can't have a correct shadow on a large distance (1000m). It will be ugly on near, or ugly on far. I can't get a nice smooth progression, even with 4 CSS @4096.
- TAA has an influence on shadow contour, even when not moving.
- If the landscape has a normal map with a large scale, then it will be ugly. It looks as if there is no texture filtering (you can see hard texels), and as if the "UV" per texel is all wrong

 image.png.486759f961786f31017e84a9a9db1aaa.png Close up of a branch shadow: image.png.2035117374dde9ae4cd3fe01f20510ee.png

These lead to pretty ugly shadows, unless you restrict yourself to small normal scale and height and close-range shadows only.

Moreover, we'd like to add the Penumbra effect to get rid of the sharp shadows on tall constructions (pylons), but I couldn't find a nice setting. Even ULTRA get weird for building higher than 20m (and some pylons are 60 or more).

Some good insights would be welcome here :)

data.zip

Posted

Thanks for the test scene, we will see what can be done here.

So if I understand you correctly, the main difficulty here is to get a combination of these requirements:

  1. Good looking shadows (with penumbra) on LandscapeTerrain
  2. Smooth shadow transitions from at least 1km distance up to closer 5-10 meters distances
  3. Tall objects like trees and power pylons /20-60 meters high

That's pretty tough requirements for realtime shadows :) And to  get a better understanding limitations we also need to know the typical rendering distance (ZFar) of your projects and what is typical shadow distances? In your world shadow distance is set to 100, but I don't think that it's real value.

Shadows on terrain should look slightly better with full terrain shading and details (with non-uniform grayscale fill). I don't think that we can do something extra here due to performance limitations.

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

Posted

Hi Silent, you got the requirements correctly.

The penumbra is a nice-to-have effect because it would dramatically improve the aspect of shadows and give a clue to the pilot on the height of the object (sharper shadows = shorter object)

The long distance shadows is required because otherwise it changes the brightness of the ground with the distance. Far shadows can be very blurry of course, but the transitions must be smooth, otherwise the pilot complains that it get the transition distance as an unrealistic clue (ie something that does not exist IRL)

ZFar is typically 50km (clear sky, and flying up to 5000m) but can be much larger (100km) for specific projects (where shadows wouldn't be a concern).

ZNear is 1m, because we have external attachments to the hull of the HC that must be visible to the pilot.

Shadows can be blurry at a distance, but must be clean from up-close (landing). Transition(s) must be smooth.

The 1km distance is only an estimate, as pilots would want the tree to appear as far as 2km...

In the test scene, I put the shadows distance at 100m to show that even with a short distance the aspect is not nice. With 1000m, the shadows are just not showable without warning the public :)

 

Thanks for your help!

Posted

Got it, thanks for the additional details.

One small request (if you don't mind) - can you record a short video from the sim and send it to me (so we can at least compare if we are having a better results or the same)? You can send it in PM. If you can show most of the issues - it would be even better :)

Thanks!

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

×
×
  • Create New...