Search Unity

Feedback HDRP's Screen space reflections are (still) not very good

Discussion in 'High Definition Render Pipeline' started by Albarnie, Dec 17, 2020.

  1. Albarnie

    Albarnie

    Joined:
    Oct 24, 2015
    Posts:
    18
    Before a start, a quick 'control' image of what my sample scene looks like with no ssr:
    upload_2020-12-17_15-35-52.png
    HDRP's SSR has never been that good. The previous implementation (now labeled 'Approximate') blurs reflections nicely with roughness, but does not blur their silhouettes:
    upload_2020-12-17_15-36-17.png
    The new release of HDRP adds the 'PBR Accumulation' mode, which looks WAY better for still renders but it still has some big issues:
    upload_2020-12-17_15-37-20.png
    As soon as you move your camera it turns into a noisy mess:
    upload_2020-12-17_15-38-37.png
    Now, normally this wouldn't be too bad, it's quite similar how Blender's EEVEE and UE4 do it, but there is one key issue:
    The seed for the noise is based on the frame, rather than the sample, meaning it changes drastically from frame to frame and is extremely distracting.
    The accumulation also seems pretty broken, with the influence of new samples being much less than the original sample, meaning it takes way longer to accumulate than it should.
    Accumulation also causes significant ghosting making it unusable for realtime.

    so, how could this be fixed?
    Approximate mode:

    • Blurred the silhouettes
    • Multi-sample support
    PBR Accumulation
    • Noise seed based on sample number rather than frame
    • Accurate accumulation sample weight
    • Support for multiple samples per frame
    HDRP brings unity graphically up to par or ahead of other engines in so many ways, it would be a real shame if it got held back by its current SSR implementation.
     
  2. mahenkumar

    mahenkumar

    Joined:
    Oct 8, 2014
    Posts:
    20
    I am totally agree with you. Initially I also thought that this time(Unity 2020.2) they have improved it but they didn't. I mean the SSR in Built In render Pipeline still looks "so much" better then HDRP. I wonder why they can't use the same technique in HDRP ?

    What's the point of "PBR accumulation" if we can't use is in realtime ? No one wants to use Unity to render still images ?
     

    Attached Files:

    • ssr.jpg
      ssr.jpg
      File size:
      780.4 KB
      Views:
      481
  3. rz_0lento

    rz_0lento

    Joined:
    Oct 8, 2013
    Posts:
    2,361
    For me the PPv2 SSR was completely broken on all scenes I tried it with but I've seen people getting it to work for their use cases. Having used bunch of built-in renderer SSR's, the one in PPv2 was worst in all test scenarios I did and even though HDRP SSR has issues it's actually usable for mirror like reflection unlike the old setup was for me.

    But as for the accumulation SSR option.. I honestly don't know who it's targeted at because it feels only usable for still screenshots and if you only care for that, you'd use raytraced reflections anyway. It feels like this is mainly a denoiser issue so maybe there's still some hope on it but I don't see myself enabling this option today.
     
  4. AydinDeveloper

    AydinDeveloper

    Joined:
    Sep 8, 2017
    Posts:
    92
    I just want the Half resolution option, which is the most passive optimization technique for SSR. PBR Accumulation is great for only screenshot.
    4K SSR performance

    RTX3070

    4K SSR ON 50FPS
    image_10018_0060.jpg

    4K SSR OFF 100FPS
    image_10020_0060.jpg
     
    Last edited: Dec 20, 2020
  5. Albarnie

    Albarnie

    Joined:
    Oct 24, 2015
    Posts:
    18
    It is usable, and it's actually very similar to the way a lot of AAA engines do it (I noticed the same effect in cyberpunk recently for example), just a bit more noisy and adds some smearing. It's alright for cinematic visuals but for fast paced fps. etc the smearing and/or noise is too much. With some of the changes I mentioned it would be quite serviceable.
     
  6. SoufianeKHIAT

    SoufianeKHIAT

    Unity Technologies

    Joined:
    Jan 16, 2020
    Posts:
    7
    Thanks for the feedback.
    • The PBR Accumulation SSR was designed to have a closer match with the reference path tracer.
    • In the context of SSR, the multi-sample implies more memory which is not necessarily desirable but possible.
    • The sampling scheme is based on this paper ("A Low-Discrepancy Sampler that Distributes Monte Carlo Errors as a Blue Noise in Screen Space" by Heitz et al.) which allows us to have better samples, you can read the paper for more details, for information the "seed" depends on the pixel position, frame index & "sample index/dimension".
    • The influence of the "new sample" is controlled by the parameter: "Accumulation Factor": 0 means the result is 100% the new sample, increasing this number reduces the importance of the new sample which cause the accumulation. This is modulated with the motion vector when the camera & object moves.
    • It's a matter of trade-off, the current strategy is in favor of the "reflection grounding", some improvements are possible in the future, we keep improving the renderer, sadly we cannot prove an ETA.
    • Feel free to add TAA on the camera to attenuate the noise when the camera moves.
     
    valarnur, AydinDeveloper and sqallpl like this.
  7. Albarnie

    Albarnie

    Joined:
    Oct 24, 2015
    Posts:
    18
    Thanks for the reply.

    I am using TAA in the screenshots, it helps reduce the noise but unfortunately that does increase the smearing.

    Multi sample would be a much appreciated option for higher end non-rtx cards which have a lot of memory to spare. When mixed with a half res ssr it could actually end up using the same amount or less memory.
    The option to apply a post process blur to reflections would also be great and cheap way to reduce noise.

    I would very much recommend you check out blender's 'EEVEE' renderer and how they do ssr. It's very similar to the PBR Acculation method but it uses the sample index rather than frame index (in addition to pixel position of course), which allows it much greater stability on lower sample counts. Many modern AAA engines and UE4 use a similar technique as well afaik.
    If not by default the option to use it would be much appreciated.

    If you are adamant on the accuracy of the pbr ssr renderer, please do update the approximation mode to at least be usable. Right now it is very distracting.

    Thanks for listening, well done on HDRP so far and good luck!
     
    BKprod, rz_0lento, toto2003 and 2 others like this.
  8. PutridEx

    PutridEx

    Joined:
    Feb 3, 2021
    Posts:
    1,136
    Seems to be the same problem of bad SSR quality in 2021.2 :(
     
  9. LumaPxxx

    LumaPxxx

    Joined:
    Oct 3, 2010
    Posts:
    339
    One vote for this.
    SSR in HDRP is either too sharp with so many sharp holes or too noisy.
    the ssr in PPV2 of built-in is much better in looking.
     
  10. LeFx_Tom

    LeFx_Tom

    Joined:
    Jan 18, 2013
    Posts:
    88
    Agreed.
    The PBR accumulated ones really only work for stills or maybe slow moving cinematics.
    The only alternative to make them look somewhat decent is to slap a 3090 in your system to up the fps to at least 90 and push their samples to 128 - then they look good.
    In any other case, they produce a constant sparkle and just look wrong.
    The older method (aproximation) is just too sharp and produces a hell of a lot of artifacts.

    I don't get how unreal SSR can be so much more reliable over all those years.
    They also have noise issues, but by far less noticable. maybe also because of better connection between their TAA approach and the reflections?

    Interestingly enough, the whole usage approach for SSR in unity is completely opposite to the ones in unreal. Where their documentation states, that you should avoid smooth, mirror like surfaces and have SSR mostly on rough/noise surfaces, the default settings for SSR in hdrp cap anything not almost mirror like from having them at all.
    Which is weird because especially on clear, smooth surfaces, they look the worst (old approximation approach) or show the most artifacts from things moving out of screenspace.

    So...i don't know - is there any plan on optimizing this whole system still? Or are you now relying on ppl running ray tracing for future issues?
     
  11. MisfitVillage

    MisfitVillage

    Joined:
    Jan 3, 2017
    Posts:
    14
    Is anybody doing anything in regards to this at Unity? The current SSR solutions in HDRP are unusable in real world scenarios (games). The old pipeline had much better and more performant SSR. Approximation is too sharp, PBR Accumulation is too noisy. Both start killing your GPU at big sample counts and that's the only way to actually get some decent scene reflections, not just reflect a few centimeters from the object being reflected.
    I don't think anyone would say that the current SSR solutions actually improve the look of a scene.
     
  12. meicexl

    meicexl

    Joined:
    Apr 9, 2020
    Posts:
    12
    Bumping to see if there's anything new going on in this regard. The state of SSR in HDRP is atrocious right now, and nothing seems to have changed.

    I'm not exactly sure why anybody would want screen space reflections to imitate path tracing, as Soufiane stated. They never will and were never intended to do that, so I'm frankly confused as to why this was even pursued as a goal by Unity. I can assure you that nobody who wants to imitate path tracing will be using SSR. They'll use path tracing or planar reflection probes. The goal of SSR is to be an "eh, good enough" cheap way to do real-time reflections. That's its entire point. It should not smear the entire screen into an indiscernible mess or require an absurd amount of rays to produce anything usable. To focus such a crucial feature as SSR to non-realtime users is bizarre, to say the least.

    I, and I'm fairly certain, the majority of people would far prefer something that's based on true and tested techniques, which was even suggested in this thread, with a Unity employee clapping back, saying "If you think that looks good, look at Mirror Edge 2 or Kill Zone 5", both of the games having far better looking, stable, and performant SSR implementations than anything Unity currently has. Mind you, this method was even implemented into Unity by some users 4 years back, and does in fact look better than anything we have now. You can't help but throw your hands up in the air and laugh at the absurdity.

    If I'm being honest, this should be one of the top priorities right now. Having no usable SSR solution in 2022 is simply unacceptable.
     
    ontrigger, Deleted User and PutridEx like this.
  13. PutridEx

    PutridEx

    Joined:
    Feb 3, 2021
    Posts:
    1,136
    Unfortunately, I have to agree.
    To add one more point to this, the current SSR quality presets are useless, anything below high isn't really usable. As default engine values, I'd expect it to be more accurate and usable, so I think the default sample presets should be adjusted accordingly.

    They've been in for quite a while it seems as well. Weird.

    - In terms of anything new, none that I know off, some speed rejection changes were made to SSR accumulate mode, but that's about it
     
  14. impheris

    impheris

    Joined:
    Dec 30, 2009
    Posts:
    1,667
    for my humble and nub opinion, the ssr with dynamics objects looks almost the same as cyberpunk's ssr i tried in my low-end laptop but also in a high-end pc and looks almost the same, there are other game engines that offers ssr and those does not look "amazing" either. Of course is bad but that is a general rule for now xD


    Lol... boss is talking here xD