Announcement

Collapse
No announcement yet.

Dynamic shadows visibility range too low!

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Dynamic shadows visibility range too low!

    I have a 100m long scene. I use VXGI and dynamic directional light + skylight. Epic settings. I tried tweaking all the values of the cascaded shadow maps without much success. I want to make a cinematic, so sometimes my shots are going to be taken a couple meters aways from the scene elements. Shadows (especially on small meshes) disappear way too ''soon''. here's a picture...

    Click image for larger version

Name:	meh1.jpg
Views:	1
Size:	427.3 KB
ID:	1146721

    I'm coming from the offline rendering world, maybe I'ts a limitation of real-time engines...is there a way to have these shadows stay sharp and visible at more than 10 meters away from player/camera? Thank you.

    #2
    These settings are purposely limited to save performance, but you can change them yourself to both increase view distance and quality of dynamic shadows. You can also type up to 10 (maybe more, not sure, but 10 has been enough for me) into the field for number of Cascaded Shadow Maps (in the settings for your directional light). The slider only goes to 4, but if you type it, you can override that setting.
    I have also had very good results playing with the following settings:

    r.Shadow.RadiusThreshold=0.01
    (Not sure exactly what this does to be honest, but it affects the distance at which shadows are visible. Lower numbers give higher visibility at distance. Default is 0.03)

    r.Shadow.FadeResolution=8
    (affects how small a shadow needs to be on screen before starting to fade out. Default is 64. Lower value gives longer view distance)

    r.Shadow.MinResolution=1
    (affects how small a shadow needs to be on screen before disappearing. Default is 32. Lower value gives longer view distance)

    r.Shadow.TexelsPerPixel=4
    (affects the resolution of the shadow on screen. Default is 1.27324. Higher value means higher resolution)

    These settings can be set in engine/config.ini. Be aware that these settings affect performance, so if you want maximum FPS they might not be optimal, but for prerendered stuff (I primarily make prerendered archviz videos) they work great. Also, the numbers I have used might be a bit overkill for your project, experiment a bit with them to find the sweet spot for your project.
    Last edited by Frepp73; 03-23-2015, 03:40 AM. Reason: typo
    http://www.pixelpirates.se/
    Architectural and product visualisations

    Comment


      #3
      Thank you sir I'll give it a try. It's also for pre-rendered arch viz movie. Hopefully my gtx 980 sc can handle it :-)

      update : I'm getting very nice results. I went a bit crazier with the values. Here's what I did.

      r.Shadow.RadiusThreshold=0.01

      r.Shadow.FadeResolution=1

      r.Shadow.MinResolution=1

      r.Shadow.TexelsPerPixel=16

      I can move very far and my shadow only fade a little bit but they never disappear! Here's quick test.

      Click image for larger version

Name:	better.jpg
Views:	1
Size:	251.8 KB
ID:	1071018
      Last edited by heartlessphil; 03-23-2015, 04:47 AM.

      Comment

      Working...
      X