Unity 2018 To Focus on Graphics, Will Allow Programmers To Write Custom Renderers
Unity 2018 will focus on improving graphics rendering quality, as announced via an official blog post appeared late last week. The main new feature coming shortly to game developers is the ability for programmers to write completely custom renderers for their projects. The post-processing stack is also being updated with higher quality effects and a Shader graph system now will allow building shaders visually, without having to write any code.
You may check a demonstration of Unity 2018's capabilities in the real-time demo below.
Scriptable Render Pipelines
The Scriptable Render Pipeline is a way of configuring and performing rendering in Unity that is controlled from C# script. This is a big shift away from how Unity has traditionally performed rendering, moving control of how a project renders from being hard coded to being completely project driven.
To solve these issues we have been developing the SRP API as an experimental feature throughout 2017. Now in Unity 2018.1, the feature is moving into beta. We are confident that not only does this system resolve these problems, but it is also fast, easy to work with, and empowering for rendering programmers.
With SRP we no longer have to provide a monolithic rendering pipeline that is trying to do everything for everyone. The SRP API opens up the Unity rendering interface, allowing for flexibility and control right from C# scripts. Programmers can now write custom renderers tailored specifically to their project.
In 2018.1 we have included 2 rendering pipelines for users. Not only are these usable right out of the box, they can serve as reference for developers building their own render pipelines.
- Lightweight Rendering Pipeline – A pipeline designed for mobiles and platforms without compute shader capability.
- High Definition Rendering Pipeline – A modern high fidelity renderer for developing games for platforms that support Shader Model 5.0 (DX11 and above).
Lightweight Rendering Pipeline
The LT RP is designed to be fast and scale well to lower end hardware. It’s a forward based renderer and scales well from mobile, to VR, to PC.
The Lightweight Pipeline is a Scriptable Render Pipeline available with Unity 2018.1. It performs a single-pass forward rendering with light culling per-object with the advantage that all lights are shaded in a single pass. Compared to the vanilla Unity forward rendering, which performs an additional pass per pixel light, using the LT pipeline will result in less draw calls at the expense of slightly higher shader complexity.
The pipeline supports at most 8 lights per-object and only supports a subset of built-in Unity rendering features. A feature comparison table of Lightweight Pipeline vs stock Unity pipeline can be found here.
HD Rendering Pipeline
The high definition render pipeline is a Scriptable Render Pipeline available with Unity 2018.1 (Experimental). The HDRP is a modern rendering pipeline designed with PBR, linear lighting, HDR lighting in mind. It’s built with a configurable hybrid Tile/Cluster deferred/Forward lighting architecture.
HDRP adds several features over built-in Unity with improved options for lights, reflection probes, standard materials. It also provides advanced material like Anisotropy, Subsurface scattering, and Clear Coating. Advanced lights, like Area lights, are also supported.
Post-processing Stack v2
The Post-processing stack has been improved to feature higher quality effects, automatic volume blending with a powerful override stack and a flexible framework to write and distribute your own custom effects.
Unity Shader Graph
Authoring shaders in Unity has traditionally been the realm of people with some programming ability. In 2018 we are changing this!
Shader Graph enables you to build your shaders visually. Instead of hand writing code, you create and connect nodes in a graph network. The graph framework gives instant feedback on the changes, and it’s simple enough that new users can become involved in shader creation.
The Shader Graph system is designed to work with both the LT and HD render pipelines, can be extended to work with any custom render pipeline, and has an open architecture that allows for custom nodes to be written.