Search Unity

Question Physically based sky completely broken

Discussion in 'High Definition Render Pipeline' started by agus_r, Nov 26, 2021.

  1. agus_r

    agus_r

    Joined:
    Oct 8, 2020
    Posts:
    15
    Hi all, I recently changed my project from 3D to HDRP.
    My project has a scene of a city during daylight, just that, only one directional light source, no emissive materials, no spot-point lights, etc.
    But the scene is completely dark! pitch dark, from the buildings, floor, sky, everything black. And this is not consistent because it would randomly work fine when I move the camera or press play. I suspect this could be a bug, because when it works it looks completely fine, with the correct amount of lighting, shadows, etc. But it would become black when I press play, or if I was on play mode and I go back to the editor mode. There simply is no logical explanation, it could go back to normal (randomly, this cannot be consistently reproduced) if I move the camera or if I change the sky settings from physically based sky to HDRI and back to physically based sky.
    Note that this weird behaviour happens only if I set a volume with a Physically based sky override. The scene works properly if it is set to HDRI sky, but then I don't have a sun.
    Furthermore, if I bake the lighting and look at the .exr files, they look completely white with a few dark spots. I don't think this is normal.
    I am using Unity 2021.2.0f1 on Linux, HDRP version 12.1.0
    The lighting settings seem a bit obscure, I don't know how much time I wasted because of this, I can never tell if everything is set properly. I am not sure if I would recommend HDRP after all the headaches this caused me.
     
  2. PutridEx

    PutridEx

    Joined:
    Feb 3, 2021
    Posts:
    1,136
    This is most likely exposure. Play with exposure on a fixed a value and see if it solves your issue.
     
  3. agus_r

    agus_r

    Joined:
    Oct 8, 2020
    Posts:
    15
    I forgot to mention, but the exposure is fixed at ~13. I know it is the right value because when it randomly works, it looks good wether you are looking at the sun or in places where you only get indirect lighting
     
  4. PutridEx

    PutridEx

    Joined:
    Feb 3, 2021
    Posts:
    1,136
    Maybe try increasing sky exposure, see if that does anything
     
  5. pierred_unity

    pierred_unity

    Unity Technologies

    Joined:
    May 25, 2018
    Posts:
    433
    Hey, a video of the problem would be great.

    But reading your description, it looks indeed like a bug if it's a totally inconsistent behavior. In this case, file a bug report, clearly indicating your hardware, driver version, Linux version, as well as a small repro project.

    In case you have access to a Windows machine, it's a good way to compare, using the same project. It could very much be a Linux-specific issue.
     
    agus_r likes this.