Search Unity

HDRP: Out of Preview in 2019.3

February 24, 2020 in Technology | 14 min. read
Share

Is this article helpful for you?

Thank you for your feedback!

Version 7.2.0 of the HDRP package is now out of Preview and verified for production. That means we guarantee stability, platform support and upgrade path.

With Version 7.2.0 of the HDRP package, we assure, platform support and migration path. It comes with mature debugging tools, scalable settings for all platforms for full control of performance, extensibility options and various artist tools. And best of all, you can start using it now.

The High Definition Render Pipeline (HDRP) targets high-end PCs, high-end Mac and high-end consoles (Xbox One and PlayStation 4) for creating high-definition and photorealistic visuals. With package version 7.2.0 in 2019.3, HDRP is verified. 

Its design follows three principles:

  1. Rendering is physically based.
  2. Lighting is unified and coherent.
  3. Features function independently of the rendering path.

Physically-based rendering relies on three pillars: lighting, material, and camera. Lighting and material rely on physical interaction, and they should be clearly decoupled to get a coherent result under various lighting conditions. The camera interprets the resultant lighting to display it on the screen. The goal is to make it easier for artists to achieve a realistic result.

Unified lighting means that all objects and participating media in the scene should receive the same lighting. There shouldn’t be any distinction between opaque, transparent or volumetric materials. Coherent lighting means that material must interact correctly with the lighting produced by any source (reflection probe, area lights, etc.), even when modified by a Decal, for example. The result is a more coherent look.

Real-time rendering uses various rendering passes: Deferred/Forward, Single Pass/Multi-Pass, and Tile/Cluster. In-game development, it’s common that the rendering path you choose will limit the graphics features you can use. Regardless of the rendering path you choose, with HDRP, the same set of graphics features is available to you. That means you can choose a rendering path based solely on your performance requirements; performance isn’t constrained by the graphics features you want to use.

Features overview

HDRP comes with a graphic feature set that can tackle more rendering challenges than the built-in render pipeline. In particular, this package provides the following advanced features for handling material qualities:

  • Lit Shader
    • Subsurface scattering and translucency simulates light that penetrates and moves within the area under a surface. Use it to make organic materials, like skin or plant leaves.
    • Clear Coating simulates materials with a thin translucent layer over a standard layer. Use it to make multilayered materials such as car paints, soda cans, or glazed objects.
    • Anisotropy simulates materials whose properties change depending on the direction along the object. Those surfaces have highlights that change when viewed from different angles. Use it to make anisotropic materials such as brushed metal, velvet, or crystals.
    • Iridescence simulates materials that appear to change color when viewed from different angles. Use it to make soap bubbles, insect wings, or seashells.
  • Layering of up to four materials with LayeredLit Shader. This allows you to blend materials on top of each other to achieve realistic and diverse visuals. Use it in a photogrammetry workflow.
  • Fabric Shader simulates realistic clothing materials. Use it to make cotton wool, silk or satin.
  • Hair Shader simulates light that penetrates and moves within hair fibers. The shader uses an improved Kajiya-Kay lighting model with better energy conservation.
  • StackLit Shader improves on the Lit Shader in favor of quality over performance. This shader coats surfaces more accurately than the Lit Shader and, unlike the Lit Shader, allows you to use multiple Material features like anisotropy, subsurface scattering iridescence, and hazy parametrization at the same time.
  • Decal Shader allows you to place decals on surfaces in your scene. It supports both projector decals and mesh decals.

This package supports advanced lighting features:

  • Physical light units for all lights. The HDRP light types, as well as sky and emission settings, use physical light units to help you light your scene in the most realistic way. It also improves scene light rigging workflow because it is easier to achieve consistency. Supported units include lumens, candelas, lux, nits, and EV100. You can also enable color temperature.
  • Area lights, such as Rectangle Lights, Tube Lights (runtime only), and Disc Lights (fully baked only), and emission, simulate light emission from a surface uniformly in all directions (baked only).
  • Various shadow types, including regular shadow with PCF filtering, cascade shadow with PCSS filtering, and area light shadow with Exponential shadow map. In addition, shadows can be enhanced with contact shadows and micro shadows.
  • Physically Based Sky simulates a spherical planet with a two-part atmosphere. It is a practical implementation of the method outlined in the paper Precomputed Atmospheric Scattering (Bruneton and Neyret, 2008), HDRI Sky with backplate mode, Gradient Sky.
  • Fog can be set up as a global exponential fog with height in your scene and can be enhanced with volumetric lighting and localized fog.
  • Screen space lighting effects. Ground Truth Ambient Occlusion (GTAO) and Screen Space Reflections (SSR) are standard with HDRP.
  • New artistic features let you exercise your creativity without abiding by the laws of physics. We added Light Layers, to make some lights affect only specific meshes, and Shadow Layers, to make some meshes cast shadows from specific lights. We also added control on penumbra and shadow tint.
  • Shadow matte is a mode on the Unlit Shader Graph Master Node. This mode allows the shader to modulate its opacity depending on the amount of shadow it receives. You can then pick a color for the shadowed parts and compose the result over an unlit image or a video.

There is a built-in implementation for post-processing using the Volume system. For post-processing, a Physical Camera setup enables you to control some of the effects, such as Depth of Field or Exposure, with a single set of standard physical settings (focal length, aperture, etc.). A Contrast Adaptive Sharpen (CAS) upscaling effect is also available. Finally, post-processing supports alpha channel; however, to use alpha channel with an effect like depth of field, allowing further composition, you need to switch the color pipeline to float16 RGBA.

You can get a full overview of the post-processing effects available in this package and their execution order in the manual. 

Another benefit is that  HDRP uses the SRP Batcher to speed up its CPU rendering.

For an in-depth look at the features of the built-in render pipeline and HDRP, see our comparison table.

Artists’ tools

To be production-ready, a render pipeline needs to provide tools for artists to express their creativity. HDRP comes with verified Visual Effect Graph and Shader Graph, and offers new tools like Look Dev and HDRI Sky with Backplate for asset workflow.

As mentioned above, HDRP is built on the premise of physically based rendering. Thanks to this, materials authored correctly should respond to lighting in a natural way in all lighting conditions.

The Look Dev view lets you quickly check the look of your assets under several lighting conditions. It also includes some view modes that allow you to check each component of your materials.

You start by creating a library of HDRI images, then you load an asset or a prefab into the view. You can switch between images in the view or even use one of the debug view modes. Or you can adjust the display for a split-screen view to compare different assets, lighting conditions, or view modes.

In addition to Look Dev, Backplate is an advanced mode in the HDRI sky. It creates a virtual geometry that can be textured using the bottom part of the HDRI image, it can fade at the edges, and it can also render shadow maps on top of the otherwise unlit HDRI sky.

HDRP allows you to make advanced visual effects thanks to Visual Effect Graph, which is our new node-based visual effect authoring tool. It is easy to use, flexible, and powerful. The visual effects generated rely on GPU particles, which allows you to take full advantage of GPUs to simulate and display large quantities of particles. The node graph allows deep customization of your effects, and you can expose the properties you need for interacting with your game systems. Read more about the Visual Effect Graph in this blog post.

Shader Graph is our node-based shader authoring tool. When used with HDRP, additional features become available (often prefixed by HD). You can use a shader graph to override the GI, edit vertex normals and vertex tangents, control Material Quality, or render your shader with a parallax occlusion mapping node that writes a depth offset. You can use distortion, refraction, subsurface scattering and other effects. You can also access specific HDRP lighting models for your shaders by using the Hair master node or the Fabric master node.

HDRP package includes Sample Content to show you how to use certain features. The package comes with a sample shader for Fabric and hair shader graph, an example of custom sky, some textures resources for post-processing, a particle system shaders for compatibility with Shuriken, and a set of material samples.

Sample content in the HDRP package: Fabric and Hair shader

Lastly, the Render Pipeline Debug displays all material properties for both opaque and transparent materials, either with Deferred or Forward Rendering path. You can choose to display various lighting, such as Diffuse lighting only, Specular lighting only, shadows, etc. It also lets you override properties for the whole scene, like normal, albedo, or smoothness. It can display intermediate render targets like motion vector, depth buffer, and many others. An invaluable tool for artists, it works both in the Unity Editor and on any player (e.g., PS4).

The MatCap mode replaces the material and lighting of objects with a simple environment texture. This mode is useful for navigating and getting a sense of the scene without having to set up the scene lighting. For example, you can use this mode when editing a dark area, like the inside of a cave, which would be difficult to navigate with low lighting.

Extensibility of HDRP

HDRP contains a lot of passes and it can be tricky to dig into it, but there is a way to add new passes without having to change the code.

The main purpose of Custom Passes is to inject effects or custom code into the render loop. They allow you to access HDRP buffers and modify them at certain points in the frame. Custom Passes use the same volume system principle as Post Process but have more restrictions (they don’t rely on profile assets and they can’t interpolate). Custom Passes require some C# scripting and shader authoring.

Here is an example of an effect you can achieve with Custom Pass:

Example of animated effects done with Custom Pass

See the Custom Pass documentation for more information, or explore some more effects made with custom passes

Custom Post Processes allow you to write your own post-processing effects. (They look a lot like the Post Processing Stack via Volume components in the Built-in render pipeline.) They are integrated within the Volume system, benefiting from the blending and overrides of this system. You create a shader that creates your custom post-process effect and link it to your Volume component.

Platforms supported

In 2019.3, we support the following platforms: 

  • PC (Vulkan / DirectX 11) 
  • PC DX12 in Preview (for DirectX Raytracing) 
  • Mac (Metal) 
  • PlayStation 4 (Base and Pro) 
  • Xbox One (Base, Scorpio and X)
  • Oculus Rift & Rift S (Oculus XR Plugin, Windows 10, DirectX 11)
  • Windows Mixed Reality (Windows XR Plugin, Windows 10, DirectX 11)
  • PlayStationVR
  • Open VR*

Note: Valve is currently developing their OpenVR Unity XR plugin for 2019.3 and beyond.

What does verified mean?

HDRP has been in development for two years and we have expanded its features based on your feedback. In that time, some consumer-grade hardware (that supports ray tracing) has become more affordable and the code base has evolved.

Version 7.2.0 of the HDRP package is now verified. That means we assure stability, platform support and upgrade path. You will be able to migrate your project data and code to future versions safely, and we will continue to develop and extend these features. All the features are documented here.

In this case, verified also means the HDRP comes with mature debugging tools, scalable settings for all platforms for full control of performance, extensibility options and various artists’ tools. Read on to learn more about these advantages.

Finding your way in HDRP

Longtime users of Unity should understand that HDRP isn’t like the built-in pipeline. It requires a new learning curve for both artists and programmers. New paradigms have been introduced, new artist tools, new settings system, new volume system, new shaders, etc. Migrating from an existing built-in Unity project isn’t a simple task and may require rewriting custom scripts, rewriting custom shaders, reworking the lighting, or setting up your scenes from scratch.

One major change is that this pipeline is a package; you need to use Package Manager to upgrade to the latest version. We recommend that you always use the latest available version compatible with your Unity binary as it contains more bug fixes. You can check the version in the Package Manager window.

To get started with HDRP, check out this documentation. It includes several helper guides, including the Getting Started manual and how to upgrade from the Built-in pipeline or from a previous HDRP version.

You can also refer to presentations by the Unity team at events such as Unite or GDC. In particular, we recently presented about Getting Started with HDRP and VR support in HDRP. Alternatively, you can go deep and learn more about the architecture of HDRP (The Road toward Unified Rendering with Unity’s High Definition Render Pipeline) or how we implement some effects (Efficient Screen-Space Subsurface Scattering Using Burley’s Normalized Diffusion in Real-Time).

To help you on your journey and check that you have the right setup for your projects (regular, VR, ray tracing), we provide an HDRP Wizard. The Wizard validates your settings and can fix them if they are incorrect. It also lets you convert your built-in project and provides an HDRP Scene Prefab to create new scenes.

The Render Pipeline Wizard

The future of the High Definition Render Pipeline

Future versions of HDRP will focus on improving performance and build time. We intend to increase the quality of and support for existing features (like SSR, Area Lights, and Volumetric) and extend them with more options. We will continue to improve artist workflows in the Editor, particularly interactions with Animator, Timeline, Cinemachine, Preset, and more.

We will also work on taking full advantage of the DOTS technology.

Lastly, this version 7.2.0 of HDRP comes with a Preview of real-time ray tracing support, which we will discuss in a separate blog post. Ray tracing is a technology that we will develop further.

High Definition Render Pipeline and Universal Render Pipeline

HDRP does not replace or encompass the Universal Render Pipeline.

HDRP delivers state-of-the-art graphics. HDRP is the best choice if your goal is to push graphics on high-end hardware. It also comes with increased complexity compared to Universal Render Pipeline and has a constrained set of supported platforms.

The Universal Render Pipeline aims to be the future default render pipeline for Unity. Develop once, deploy everywhere. It is more flexible, is more extensible and, like HDRP, delivers higher performance than the built-in render pipeline, and has improved graphics quality.

Given the differences, choose a render pipeline according to the features and platform requirements of your project.

Start using HDRP

Several high-graphic productions are in progress with HDRP, including games and VR projects. We’ve even rendered Unity’s Japan office in HDRP, so you can see how the architecture, engineering and construction (AEC) industry can leverage HDRP’s photorealism. 

Check out these sample projects to help you get started: Fontainebleau and The Spaceship.

To learn more about its capabilities and how to get the most out of HDRP, check out the following blog posts. But first, read more here on our Forum.

You can start taking advantage of HDRP for your projects today. Meanwhile, our team is continuing development. Please send us feedback in the HDRP forum!

February 24, 2020 in Technology | 14 min. read

Is this article helpful for you?

Thank you for your feedback!