Search Unity

Discussion about HDRP shadows

Discussion in 'High Definition Render Pipeline' started by EternalClickbait, Jun 16, 2019.

?

Would you like to see an option for shadow softness

  1. Slider (as a percentage)

    90.3%
  2. Selection (Hard/Soft)

    9.7%
  3. No

    0 vote(s)
    0.0%
  1. EternalClickbait

    EternalClickbait

    Joined:
    May 5, 2019
    Posts:
    22
    I'm not trying to be whiny here, but the shadows in HDRP seriously suck in quite a few ways. I'm currently trying to get something as simple as changing the softness of the shadows, but nope, HDRP won't let me do that. I get that hard shadows REALLY don't look good at low resolutions, but at least let me change how sharp they are!
    I really don't want this blurred excuse for shadows in my game.
    Screenshot (196).png
    At least a working property would be nice.

    I've gone through EVERY SINGLE PROPERTY/FIELD on all of the scripts attached to the light, and none of them do anything. I mean, at least remove
    Code (CSharp):
    1.  
    2. Light.shadowRadius;//Controls the amount of artificial softening applied to the edges of shadows cast by the Point or Spot light.
    3. Light.shadowAngle; //Controls the amount of artificial softening applied to the edges of shadows by directional lights.
    4. Light.shadows; //(Enum) None, Hard or soft
    5.  
    6. HDAdditionalLightData.shadowSoftness; //Float
    7.  
    I've gone through reflected properties and sub-properties, and STILL nothing. I don't want to have to crank up the shadow resolution, just to be able to see them properly. Please, HDRP Team, either remove the references or let us be able to do it.
     
  2. Tartiflette

    Tartiflette

    Joined:
    Apr 10, 2015
    Posts:
    84
    Shadow softness isn't exactly a solved problem in the world of 3d graphics. That being said, it is perfectly possible in HDRP but you need to set a few things up correctly first, and I'm not 100% sure which ones. First, I believe you have to use the forward render, then you need to crank up the shadow filtering in your renderer config, and then I think you can finally play with the light's softness sliders.
     
  3. Gekigengar

    Gekigengar

    Joined:
    Jan 20, 2013
    Posts:
    738
    There was a demo video on Nvidia YT Channel about using Real-Time Raytracing for only shadows (Instead of using it for reflection/GI/etc). It achieved realistic physically correct shadows with both hard and soft shadows on real-time. I hope the new Unity Raytracing will support raytraced shadows to solve this once and for all.. (No more static baked shadows/shadow maps/cascading/etc I hope!)
     
  4. Tartiflette

    Tartiflette

    Joined:
    Apr 10, 2015
    Posts:
    84
    I'm pretty sure that the current raytracing beta already supports all that, but I still wouldn't call it a solved problem. Right now it's all heavily filtered spatially and temporally, which is not exactly great and will have some nasty artifcats. Also very few people have that kind of hardware for now, which means that most games will need to keep the good old shadowmaps as a backup.
    If the next consoles genuinely support raytracing (with actual hardware acceleration), we will most likely see some amazing new techniques in the next few years :)
     
  5. laurent-h

    laurent-h

    Joined:
    Sep 29, 2016
    Posts:
    78
    HDRP supports PCSS shadow filtering which allows soft shadows with certain constraints for now :
    - you need to render in forward completely (lit shader mode forward only in HDRP asset)
    - shadows filtering quality needs to be set to high in the HDRP asset
    https://docs.unity3d.com/Packages/c...es.high-definition@6.7/manual/HDRP-Asset.html

    This gives you more controls over the shadow filtering at the light level, but you get options like "shadow softness".
    There are some technical barriers that don't allow us to enable this filter for deferred rendering right now.
    Also note that the parameters for this shadow filter might change in the future.
     
    EternalClickbait likes this.