Updated for 2021 LTS: The definitive guide to lighting in the High-Definition Render Pipeline
Those who are familiar with Unity will be aware that the High-Definition Render Pipeline (HDRP) is a high-fidelity Scriptable Render Pipeline that was developed by Unity to target modern platforms that are compatible with Compute Shader. First introduced in 2018, the HDRP makes use of techniques such as Physically-Based Lighting, linear lighting, and High Dynamic Range (HDR) lighting, in addition to a hybrid Tile and Cluster deferred or Forward lighting architecture that can be configured. The High-Definition Render Pipeline provides artists and developers with the tools that are necessary for the creation of applications with a very high graphical standard. These applications can include games, technical demos, and animations. Anything that a developer makes in Unity can be passed through the HDRP.
Unity developed the High-Definition Render Pipeline to assist content creators in bringing their ideas to life by harnessing the processing power of powerful personal computers or game consoles to achieve previously unachievable levels of graphical realism. Existing Unity artists and developers can use this guide as a reference when exploring HDRP’s physically based lighting techniques. HDRP is a technological advancement that represents a step forward for Unity’s real-time rendering. It enables creators to manipulate light in the same way that it behaves in the real world. Amongst the features of the HDRP system are:
-
Exposure to physical light units, as well as the use of real-world lighting intensities and units, are both incorporated into HDRP. Adjust the exposures using the physical cameras, then compare the results to the specifications of the known light sources.
-
Using lighting like that is more advanced and allows the artist to control the placement of the light by providing additional shape options for spot and area lights. It can make use of multiple Light Layers to restrict the effect that certain lights have on particular meshes. Applying real-time effects such as Screen Space Global Illumination and Screen Space Refraction in this way is highly recommended when creating a realistic environment.
-
Specific shadows and lighting that is fundamentally more advanced allows developers to control the placement of the light by providing additional shape options for both spot and area lights. It makes use of Light Layers to restrict the effect that certain lights have on particular meshes, as well as applying real-time effects such as Screen Space Global Illumination and Screen Space Refraction.
-
Advanced reflections are easy to produce using the HDRP. The rendering of reflective surfaces can be done in a number of different ways, with Reflection Probes providing a more conventional method for reflection mapping, whereas Planar Reflection Probes provide the developer with more sophisticated options for mapping flat surfaces. Screen-space reflection, also known as SSR, is a technique that uses the depth buffer and adds real-time support.
If it is important to create a scene depicting natural sunlight shining on a verdant tropical rainforest or live in the neon-lit concrete jungle of a big city, which is teeming with emissive lighting from neon signs, then the power of HDRP comes into its own. To develop these kinds of scenes and to have the ability to paint scene levels with the skill of a cinematographer then it is essential to use HDRP tools within Unity. Constructing worlds for a new game that can take players to all kinds of different locations, from the everyday to the fantastical, takes the power of the HDRP to realise them. To enable new features and allow the system to do ever more, Unity updated the software, and the latest issue has a number of powerful additions and upgrades, including:
-
Light anchors. This component allows the developer to quickly set up lights around characters or props by controlling the angle at which the camera is positioned in relation to the subject as well as the distance between the camera and the subject. It is packed with predefined presets and gizmos.
-
Realistic clouds. The Cloud Layers dialogue box can be used to animate clouds and change their appearance through the use of parameters and textures. Natural-looking Volumetric Clouds can be used to render shadows or receive fog and volumetric light.
-
Complex lens flare. This effect imitates the artefacts that can be seen on the lens of a camera when it is pointed at sources of light. It is possible to incorporate these into the rendering process in order to help give a game a more cinematic and realistic appearance.
-
Dynamic resolution settings. This automatically lowers the rendering resolution whenever the frame rate is on the verge of dropping and then upscales it using filters to make sure that players can enjoy smooth gameplay without experiencing a negative impact on the game’s presentation and looks.
-
Easier ray tracing. Unity has added more information to this section in order to make the functionality of this feature easier to access in the future.
As a consequence of these updates, the Unity package is far more powerful and capable of generating realistic environments for games, industrial renders, and simulations, and much of it is due to the increased abilities of the High-Definition Render Pipeline. If you want to know more, an ebook that accompanies the release is available from the Unity website.