Let's talk "Shadows"

Discussion in 'Ideas and Suggestions' started by NistingurA, Jul 4, 2021.

  1. NistingurA

    NistingurA
    Expand Collapse

    Joined:
    Nov 22, 2013
    Messages:
    2,092
    Good day everyone.


    Version 0.23 just released a couple of days ago and I cannot complain at all. The game looks as good as ever. But there is just something small that has bugged me, ever since the devs first started updating the materials for maps and cars a while ago. It is nothing major and in my honest opinion, could change the look of the game even more drastic, maybe this could get it’s own little update, as like a “Graphics Part 2” ?

    Anyway,
    Let’s talk about “Shadows”…​


    screenshot_2021-07-04_13-07-51.png
    I play Beam on the new “ultra” settings with all shadows enabled and I am somehow not satisfied with the term “Ultra” or “High” when it comes to the 'Shadow quality'.

    The shadows in this game are a flickery, blurry mess and honestly, need an update.

    I tried finding some info about Torque3Ds different shadow types, but documentation about it seems .. lacking at best? Beam uses something called “PSSM” Shadows, it’s one of several shadow types that Torque supports… For some reason tho, even if there is an option in the World editor to “select” different types, you can’t.

    What PSSM does is pretty simple. It takes “shadows”, splits them into several smaller areas, which increases the quality of the shadow, henceforth allowing the shadow maps to be smoother and more detailed.

    PSSM is quite old, I found an old Nvidia article about it from 2007 or so, give it a read if you want to understand it a bit more.

    Anyway. In the World editor, you can go to “LevelObjects” and select “sunsky”. This basically holds all the important bits and bobs for the sky and lighting itself, including our shadows.

    In the tab “Advanced Lighting”, the first thing I noticed was, that the "texSize" was 1024, meaning 1024 pixels, which isn’t much. Even just setting it to double that (more isn’t supported?) makes a big difference in the shadow quality and you basically loose no performance.

    texSize set to 2048
    screenshot_2021-07-04_13-09-11.png

    I was pretty satisfied with this, but I wanted more. I played around a bit with the other settings in the tab, making the shadow a bit sharper as well, by setting the logWeight from 0.98 to 0.987. The editor also has an option for “numSplits” which is the number of splits for the PSSM shadow type. More splits is better, but you can only set it to 4, which is default. Something like 6 or 8 would be super nice to increase the detail even more.


    My next adventure brought me to the shadow “brightness”. I figured you could still configure this somehow in the SSAO tab in the PostFX manager, but it’s not there anymore. I then thought I could somehow change the colorramp and apply the darker shadows there, but that was a bit too difficult I thought. Luckily, the editor has just the right tabs for that.

    The tabs “ScatterSky” and “Lighting” hold the two values that I needed. Under “ScatterSky” there is a value called “exposure”. Turning that down from 1 to roughly 0.3 – 0.35 makes the shadows way darker, which is good, I believe they’re way too bright by default.

    Secondly, going to “Lighting” the value “brightness” can be changed. This changes the overall bruightness of the scene. I set it to 1.25 instead of 1, and…. Well, see for yourself:

    screenshot_2021-07-04_13-10-35.png

    My final step was too make fine adjustments to the SSAO, since the shadow underneath the car was still a bit too bright for my taste.

    So I went into the camera mode, set the SSAO quality to “High”, the Radius to 0.8 and the contrast to around 6.5

    It might be a bit too dark now, obviously this is just for demonstration purposes, but hey, don’t tell me that it looks “bad”. I obviously advise the game devs to decide what values to change an which they shouldn't. This is only a suggestion thread, I don't even know if some of these requests, like the increased texture size or the higher number of shadow splits, is even possible to implement, or if the PSSM shadows/Torque limit this.

    Anyway, here are some finalising screenshots. Thank you for reading ~Nistii

    screenshot_2021-07-04_13-11-46.png screenshot_2021-07-04_13-38-10.png screenshot_2021-07-04_13-38-57.png
     
    • Like Like x 16
    • Agree Agree x 5
  2. Agent_Y

    Agent_Y
    Expand Collapse
    Jbeam/QA support
    BeamNG Team

    Joined:
    Jul 10, 2020
    Messages:
    10,061
    This honestly looks so much better, obviously aside from the fact that it ruined the brightness of everything other than shadows lol
     
    • Like Like x 1
  3. NistingurA

    NistingurA
    Expand Collapse

    Joined:
    Nov 22, 2013
    Messages:
    2,092
    Yes I agree, but as I noted, it's just for the sake of demonstration.
     
  4. P_enta

    P_enta
    Expand Collapse

    Joined:
    Jan 11, 2020
    Messages:
    3,029
    Shadows in this game are a blocky mess. Glad to see a fix
     
  5. radig

    radig
    Expand Collapse

    Joined:
    Oct 9, 2021
    Messages:
    351
    im a bit confused on how to do it? any videos?
     
  6. KillerBee 2

    KillerBee 2
    Expand Collapse

    Joined:
    May 21, 2021
    Messages:
    53
    Thank you for this!
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice