Show/Hide Mobile Menu

Unity's Scriptable Render Pipeline

May 13, 2022

Scriptable render pipeline is a way to customize the render engine in Unity using C#. It hooks into the C++ of the render engine. It's an advanced feature that beginners don't really need to worry about. Unity comes with two pre-built scriptable render pipelines - Universal Render Pipeline and High Definition Render Pipeline. Universal Render Pipeline is for mobile devices and produces a render quality that is similar to the built-in render pipeline but is more performant. High Definition Render Pipeline is for PCs and consoles. It aims for photorealism but requires more powerful hardware.

It is possible to switch from built-in render pipeline to another render pipeline half way through your project. Unity provides an option to do it for you. It basically switches the shader in all the materials to their equivalent in the target render pipeline. But if you use a shader that doesn't have an equivalent you are kind of stuck. This can happen when you download assets from the asset store. So you are better off picking a render pipeline and sticking to it when you create a project. An advantage to using URP over the built-in render pipeline is that you can make use of Shader Graph. This allows you to create shaders using visual programming. You can still create shaders in code if you want to. The downside to SRPs is that not all assets in the asset store are compatible with them.

You can create a custom render pipeline if you are so inclined. Here is an example of one. You can also use URP or HDRP as a base and change it. The code is available on Github. Unity has instructions on migrating a project that uses the built-in render pipeline to the Universal Render Pipeline.