Dealing with the lighting and color tones of your game is just as important as the gameplay aspect. Making your game looks good can attract more players. Unity’s built-in post-processing effects allow you to do a bunch of cool screen effects which can greatly improve the visual of your game.
Post-processing is a technique used to improve the visual quality of rendered media such as games, videos, and films. In video games, the process of post-processing is done by applying various effects before rendering the frame onto the screen.
There are various post-processing effects you can use, ranging from changing hue to the bloom effects or even applying the motion blur effect.
Table of Contents
- How to Enable Post-Processing
- List of Post-Processing Effects
- Putting Multiple Post-Processing Effects Together
How to Enable Post-Processing
It is a simple process to enable the use of post-processing, though you need to meet a prerequisite first. In this article, I’ll be using the URP sample scene as an example.
First of all, your project needs to have either the Universal Render Pipeline (URP) or the High Definition Render Pipeline (HDRP) enabled.
If your project has neither of those rendering pipelines, you need to install the Post-Processing Stack V2 package in order to use post-processing effects.
Once that is done, you’re ready to enable post-processing.
Note: Depending on the render pipeline you pick, the number of post-processing effects available, as well as their behaviors, will be different.
It is important to determine which effects you’re going to need and pick the right render pipeline so you won’t have to deal with the headache of converting your project to a different template.
Visit the official Post-Processing Overview for the list of effects available for each pipeline.
First, let’s create a Volume object. This object is a game object with a Volume component that will enable you to apply various post-processing effects to the scenes.
- Global Volume applies the post-processing effects to the entire screen
- Box Volume, Sphere Volume, and Convex Mesh Volume create a boundary in their respective shape that applies the post-processing effects when the camera enters the boundary. This is useful when you want to do things like applying different effects when diving underwater.
You can also do this by creating an empty object and manually adding the Volume component to the object. Just make sure to add a collider component to set the boundary if you set the Volume’s mode to Local.
The Volume component should look something like this:
Now, you’ll need a Volume Profile which is like a container for holding your post-processing effects and their settings.
You can create one by clicking on the New button on the profile field, or by right-clicking on the Project window, selecting Create > Volume Profile, and dragging the file to the profile field.
Once a Volume Profile is added, you will see Add Override button.
Clicking on the Add Override button will bring up a menu.
Select Post-processing and you will see a list of effects.
Pick whatever you like and play around with it. The best way to learn is to try and find out what each effect does. Have fun!
A Volume Profile can be shared across multiple Volumes.
For example, you might want the same underwater filter effects in multiple locations in your game. You can simply link the same Volume Profile to each local Volume to get the same consistent post-processing effects.
If you can’t find where the Volume Profile is located, click on the profile’s name in the Volume component and Unity Editor will highlight the file in the Project Explorer for you.
List of Post-Processing Effects
Below are some of the effects you can use. Do note that not all effects are available on all render pipelines and not all of them have the same settings. I highly recommend you try them yourself to get a better understanding.
The Bloom effect adds a glow effect to the bright parts of your game scene. This effect behaves differently depending on the render pipeline you’re using.
This is a great effect for making your scene look brighter and more vibrant.
The Vignette effect darkens the edges around the camera. This is useful for making the scene look darker and sometimes more realistic depending on how you adjust the values.
Depth Of Field
The Depth Of Field effect blurs anything that’s further than a specified distance to keep the focus on certain things in the scene.
This is one of the commonly used post-processing effects and can make your game scene look like it has more depth.
The Tonemapping effect remaps the High Definition Range (HDR) color values, making a scene with a lower dynamic range appears to have more range of colors.
This effect adjusts the range of colors to a wider range to give the scene more contrast and make the scene look more realistic.
Note that URP’s Tonemapping has limited options. If you want finer control, consider using HDRP or Post Processing V2 package.
The Film Grain effect adds an animated film noise effect to the camera to make the scene look like it’s being played via a physical film.
The White Balance effect changes the overall tone of the scene by shifting the temperature or the tint while maintaining the white areas.
The Motion Blur effect creates a blurred-lines visual effect when you move the camera around, making objects appear to move fast.
The Chromatic Aberration creates a visual effect that the real-world camera produces when it fails to display colors correctly and shows 3 separate colors on different points instead.
The above effects are only some of the effects Unity has to offer. For the list of all available effects and more detailed explanations of the settings, visit the official Post-Processing Overview page or you can try them yourself inside Unity Editor.
Putting Multiple Post-Processing Effects Together
Multiple post-processing effects can be overlayed on top of each other so you can stack as many effects as you like.
The above image used Tonemapping, Bloom, Vignette, Depth Of Field, and Color Adjustments effects to create this amazing-looking scene.
Now it’s your turn. Go and play around with the effects to your heart’s content! Let me know how it goes in the comment section.