Search Unity

Making a dark scene with HDRP

Discussion in 'High Definition Render Pipeline' started by D-Coy, Apr 13, 2020.

  1. D-Coy

    D-Coy

    Joined:
    Jun 2, 2013
    Posts:
    16
    Hi, this seems like it should be simple but I can not find any relevant info.

    I want to create a night scene while utilising HDRP, but I cant find a way to control (or even get rid of) the environment lighting and exposures are way too extreme. Even if I create a room from the sample scene, with 6 boxes, completely sealing off a light source, it is still totally bright inside.

    Ive dug around all day trying to find a solution but theres a lot of mixed info out there and has just left me confused.
    Are there any decent tutorials out there that cover setting up for a night/indoor or even cave environment, that are relevant and up to date?
    Thanks,
     
    zaiman1996 likes this.
  2. gilley033

    gilley033

    Joined:
    Jul 10, 2012
    Posts:
    1,191
    Haha, this is funny because just last week I was trying to do the same thing and couldn't figure it out. I think there must be an HDRP dedicated tutorial out there that we need to consume in order to understand how things work.

    If I figure it out the answer to our question I'll let you know! Just be sure to post back here if you figure it out first.

    Edit: Unity Learn is currently free. I found these two tutorials that may be of help:

    https://learn.unity.com/tutorial/introduction-to-hdrp-2019-3 [Seems pretty useless]

    and

    https://learn.unity.com/tutorial/introduction-to-hdrp-lights [More useful but not for the topic at hand]

    Edit2: Both tutorials don't really apply to our issue. I'm going to search on YouTube.
     
    Last edited: Apr 13, 2020
    deus0 likes this.
  3. D-Coy

    D-Coy

    Joined:
    Jun 2, 2013
    Posts:
    16
    Hey thanks for the reply.
    I think Ive solved it by adding an Exposure component, and just crushing everything. Think there might be a better way tho.
    Thanks for the links, will check them out now.:)

    edit: These look great! Cheers
     
  4. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,190
    angrypenguin likes this.
  5. angrypenguin

    angrypenguin

    Joined:
    Dec 29, 2011
    Posts:
    15,620
    Plus, screenshots of what you've tried and achieved would be great.
     
  6. BIGTIMEMASTER

    BIGTIMEMASTER

    Joined:
    Jun 1, 2017
    Posts:
    5,181
    DId you bake the scene lighting first? I am not sure why but even if you are using realtime lighting, you still have to bake one time first before the slider will respond.
     
    ammills11 likes this.
  7. Velo222

    Velo222

    Joined:
    Apr 29, 2012
    Posts:
    1,437
    I guess it depends on what "sky" you are using, if any at all. And are you thinking mainly indoor or outdoor?

    For outdoor lighting I'm using the Procedural Sky post-process component. I found the "atmosphere thickness" to have the most influence on the darkness level at night. I'm not sure if that would work for the Physically based or HDRI sky at all though -- I'm assuming most people actually don't use the Procedural Sky......but I love the look of it.

    The second thing I found to influence good night lighting is the "Dimmer" on a Directional Light, under the Emission section. This allows you to control the light intensity of the Directional Light as a percentage of it's intensity.

    For a night scene, I actually control the atmosphere thickness in post-process, the Light Emission "Dimmer" value, the actual main intensity, the sky tint color, the ground tint color, and if you're using exposure or a multiplier -- those settings as well.

    A mix of all of that can give you good control over the lighting you want at night -- in my opinion.
     
    Ryiah likes this.
  8. D-Coy

    D-Coy

    Joined:
    Jun 2, 2013
    Posts:
    16
    Thanks for the info, all.
    Yeah, I think Ive now had the most control in post processing. This does feel a little illogical to me as it seems like Im adding an effect to get rid of an effect (adding a process to counter act the brightness of the scene.. where as I would just like to control the light of the scene).
    Anyway, perhaps this is not such a huge hit in HDRP world (?). I am losing frames but its mostly the lights Im using as opposed the the post processing stack.

    Cheers
     
  9. Migueljb

    Migueljb

    Joined:
    Feb 27, 2008
    Posts:
    562
    Took me awhile to figure that one out to. In your Sky and Fog Volume set the sky type HDRI Sky. In your HDRI Sky section set intensity Mode to Multiplier or LUX and right under multiplier or LUX value to 0 will completely blacken the sky as needed OR keep the Intensity Mode to exposure and set exposure to -100 cause like -10 will still show thru so its a per scene basis. In the Lighting Tab under Environment - Static Lighting Sky set it to none as well.

    Should always setup your sky first per scene then work on lighting - directional lights, point. spot etc.
     

    Attached Files:

  10. cloverme

    cloverme

    Joined:
    Apr 6, 2018
    Posts:
    198
    You also have to disable any baked reflection probes too, so like if you have a room where the lights go out, if you baked any probes with the lights on, that area will stay lit. While I love the look of lighting in HDRP, working with lights now is a learning experience all over again.
     
  11. EvanKnowles

    EvanKnowles

    Joined:
    Dec 10, 2015
    Posts:
    3
    Setting the intensity mode to a Lux of 1 showed the sky, but suddenly all my lights, that had completely not been behaving (and which I'd had to crank the settings up for), started working as expected for me.
     
  12. UnityLighting

    UnityLighting

    Joined:
    Mar 31, 2015
    Posts:
    3,874