Jump to content
  • Sign Up

    Welcome to CANOPY.
    Browse and post on Forums, read articles in the Library, and check out News to see what's new.

    Existing Customer?
    If you would like access to your free downloads then signup and contact us with your invoice number. 

    Want More, Subscribe!
    Check out our amazing offer and for all our assets and the xChange, weekly updates, game ready levels, asset packs, spawner packs and much more!

  • Using the new HDRP Time of Day System (Early Access)


    This article explains how to use the new HDRP Time of Day / Lighting System released as Gaia Early Access Version in Canopy. This system will later be released as regular part of Gaia. The Time of Day System allows you to display a dynamic day and night cycle with volumetric clouds and weather, as commonly found in most open world games.



    Grab 20220420040419 w3840h2160 x-121y61z228r314.png
    Grab 20220419213845 w3840h2160 x42y63z-203r13.png
    Grab 20220419213259 w3840h2160 x-156y87z-153r183.png
    Grab 20220420041449 w3840h2160 x-67y58z260r183.png

    To use the system, you need to have Unity Editor version 2021.2 and higher in the HDRP Pipeline. (The system makes use of features solely found in this pipeline version and above).


    The system will be installed alongside the Early-Access Version of Gaia. If you install over an existing Gaia installation, please make sure to remove the folder Procedural Worlds\Gaia\Gaia Pro\HDRP Time Of Day first - this folder contains an older version of the system that will create conflicts if it is being kept around. If you accidentally installed over without deleting the folder first, delete the folder now and re-import the Early-Access Version again. This should fix it.

    Pro Tip: It is possible to only import the folder Procedural Worlds\Gaia\Gaia Pro\HDRP Time Of Day only in a project to use the Time Of Day system without Gaia being present as well.

    Adding the system to your scene

    To use the system, you need to add it to the scene first. This can be done in the following ways:

    1. By selecting "Procedural Worlds Sky" in the Gaia Manager "Create Runtime" tab when adding the runtime components to your scene:


    If you are running HDRP in Unity 2021.2, this will add the HDRP Time Of Day System then

    2. By switching to "Procedural Worlds Sky" on the Gaia Lighting Object if a different Lighting Profile was set up before:



    3. By adding the HDRP Time of Day System from the Window menu to the scene. (This allows to add the system without Gaia being involved at all)


    Configuring the system

    Once the system was added to the scene, locate the "HDRP Time Of Day" object in the scene hierarchy to configure it. If Gaia is part of the scene setup, you can find it below the "Gaia Lighting" object, if used without Gaia the system will sit in the scene root.

    The System has a lot of settings that allow for complete customization of the look of the day and night cycle. Before you start, make sure the correct camera is set up in the system:


    If not, drag and drop the main camera into this slot.

    Time of Day Settings

    To get a feeling for how the system works, look at the next section and adjust the time of day slider to the left and the right:


    You should see an immediate impact on the lighting in the scene as the time of day changes:




    The settings sections below reveal how this is controlled: Most settings that you can find in the different panels below is mapped to the current time of day via a curve mapping - The value at the left side of the curve is being applied as the time of day slider is all the way to the left (0:00 o' clock), the value at the right side of the curve is being applied when the time of day slider is all the way to the right (24:00). This means as the slider "travels through the day", the different settings that use an animation curve below will be altered accordingly. 

    For example when looking at the fog settings, imagine a line would be drawn from the slider to the curves below - the point where the line would intersect with the curves would be the value that is applied for that setting at that time of day.


    You can tell for example that the fog distance is closer around midnight and further away around noon. Note that the "Fog Color" uses a color  gradient - same principle, the fog color is selected according to the position of the time of day slider. 

    When clicking on the curves you can see a more detailed view that allows to edit the curve and which also reveals the scaling of the curve:


    The scale can be vastly different depending on what the value is that we are editing - a distance as displayed above would be measured in meters, a multiplier value might be single digits only.

    It would exceed the scope of this documentation to list every setting that can be found in the time of day system, but note that if you hover over the field descriptions and / or click on the help button in the top right corner of the UI, you will get on-screen help that explains what a value is good for:



    With a basic understanding how the settings are being processed, you can start the scene, and activate the "Auto Update" checkbox in the Time Of Day Settings, and enter a value like "100"  as multiplicator.


    You should now notice how the time progresses and the Time Of Day slider is pushed forward automatically:


    Post Processing Settings

    The same principle of mapping the time of day to a curve (or color gradient) applies for the post processing settings panel as well. The only difference is that the values edited here fall in the realm of HDRP post-processing.

    Ambient Audio Settings

    The Time Of Day system comes with a feature to play different Ambient Audio soundloops while the time of day progresses.


    The "Ambient" slots take on a soundfile that is being looped while the respective section of the day is active. The Volume settings help to fine tune the volume during the day and when a weather effect is running. The "Time Of Day Intervals" define the duration of the 4 different segments "Morning", "Afternoon", "Evening", "Night" during the day.  (The setting is expressed as a scalar value where 0 would be the start of the time of day loop, and 1 at the end. The "0.25" from the screenshot above would translate to "the morning loop plays for the first quarter of the time of day loop".)

    Underwater Settings

    The system can override the fog settings when the camera goes under water - this helps with creating underwater VFX.


    You can choose to apply these settings in sync with the Gaia underwater VFX, or you can switch the System Sync Type to "Custom" to integrate your own solution via scripting (see HDRPTimeOfDayProfile.ApplySettings())

    Weather Settings

    The system allows you to define weather effects that can kick in as the time of day progresses.


    The Min / Max Wait time determines how long it takes until a weather effect becomes active. The  Weather profile contains override settings for the regular time of day settings. In this way the rain effect alters the cloud settings, fog settings and lighting settings etc. to make it appear like it is raining:

    Grab 20220420041449 w3840h2160 x-67y58z260r183.png

    Additionally there are also particle VFX being played back that are supplied in the weather profile. During runtime you can quickly start and stop the weather effects with the respective buttons. To develop your own weather profile, you can use the "Copy Settings Over" button to copy the current active settings from the time of day system into the weather profile.
    If you were to develop a new weather effect you could define how this effect should look like across the different times of day, then when you are happy with it, move the settings in the weather profile.

    Debug Settings

    Lastly, the debug settings help with testing and developing your scene and the time of day system therein.


    You can use the "Simulate Speed" and the "Start Simulation" button to run the time of day cycle in the editor.
    "Fetch Debug Information" prints information about the current time of day values into the console.
    "Refresh Time Of Day Components" forces an update on the components controlled by the Time Of Day system in case an outside influence changed settings.
    "Remove Time Of Day" lastly will remove the system from the scene again.


    • Like 2

    User Feedback

    Recommended Comments

    There are no comments to display.

  • Create New...