Volume Overrides: Visual Environment

Tutorial

·

intermediate

·

+10XP

·

20 mins

·

(109)

Unity Technologies

Volume Overrides: Visual Environment

The Visual Environment component allows you to override a Volume’s settings for the sky (including sky type and whether its ambience is static or dynamic) and fog. In this workflow, we’ll create and confgure a Visual Environment Override.

1. Introduction

If you're using 2019.2 or lower, click here.

Unity’s Visual Environment component allows you to override a Volume’s settings for the sky (including sky type and whether its ambiance is static or dynamic) and fog. In this tutorial, we’ll create and configure a Visual Environment Override.

If you create a project using the HDRP template, all Scenes will start with a Visual Environment Override attached to a GameObject named Render Settings. If you’ve created your Volume manually — for example when adapting an existing project to use the HDRP — you will need to add the Visual Environment Override manually.

Each setting in the Visual Environment has a corresponding Override. For example, if you choose a Gradient Sky in your Visual Environment, you’ll also need to add a Gradient Sky Override to your Volume.

2. Disabling or Removing Existing Overrides

The default Visual Environment comes preconfigured. If you’d like to remove the preconfigured Override, or you change your mind about an Override you’ve added, you can either uncheck the box next to the name of the Override or right-click the name of the Override and select Remove (Figure 01). You might want to just uncheck the Override’s box, rather than deleting it altogether, when you’re trying out different options.

Figure 01: Click the box to disable an Override, or use the context menu to remove it.

Figure 01: Click the box to disable an Override, or use the context menu to remove it.

3. Creating and Configuring a Volume and Visual Environment Manually

  • Create an empty GameObject by selecting Create Empty from the GameObject drop-down. Name this object; we’ll use Render Settings.
  • In the Inspector, attach a new Volume component.
  • Check the box marked Is Global if you’d like to apply these settings across the entire Scene. If you’d like to confine this Volume to a certain section of the Scene,
    leave Is Global unchecked and attach a Box Collider component. The size and position of the Collider determines the area affected by this Volume’s settings.
  • Click the button labeled New to create a new Volume Profile (Figure 02).
Figure 02: Creating a new Volume Profile.

Figure 02: Creating a new Volume Profile.

  • In the bottom of the Volume Inspector, click Add Override (Figure 03).
Figure 03: Click here to add an Override to the Volume.

Figure 03: Click here to add an Override to the Volume.

  • Click Visual Environment (Figure 04).
Figure 04: Click here to select the Visual Environment Override.

Figure 04: Click here to select the Visual Environment Override.

  • Enable the Type checkbox under Sky to override the Sky setting for the Volume (Figure 05).
Figure 05: Click here to override the Sky type.

Figure 05: Click here to override the Sky type.

  • In the Sky drop-down, select Physically Based Sky (Figure 06).
Figure 06: Use the drop-down to change any settings you wish to override.

Figure 06: Use the drop-down to change any settings you wish to override.

  • Click Add Override at the bottom of the Inspector. Select Sky > Physically Based Sky
    (Figures 07-08).
Figure 07: Adding a Sky Override

Figure 07: Adding a Sky Override

Figure 08: Selecting the type of Sky Override

Figure 08: Selecting the type of Sky Override

  • In the Sky section of Visual Environment, check the box next to Ambient Mode and select Static from the drop-down (Figure 09).
Figure 09: The Static Ambient Mode requires an additional component, but the Dynamic Ambient Mode does not.

Figure 09: The Static Ambient Mode requires an additional component, but the Dynamic Ambient Mode does not.

  • Add a Volumetric Fog Override by clicking Add Override and selecting
    Fog (Figure 10).
Figure 10: When changing an option in the Visual Environment, remember to add its corresponding Override, for example this Fog Override.

Figure 10: When changing an option in the Visual Environment, remember to add its corresponding Override, for example this Fog Override.

  • In order to make it volumetric expand Fog and click the Enable checkbox then go to the very bottom and check the box called Volumetric Fog (Figure 11).
Figure 11: Enabling the Fog override and turning it into Volumetric fog.

Figure 11: Enabling the Fog override and turning it into Volumetric fog.

4. Conclusion

The Visual Environment gives you the power to customize your Volumes, whether they encompass an entire Scene or are restricted to a certain Collider space. Try experimenting with different combinations of settings, and you’re sure to find the right configuration.

Complete this tutorial