Skip to main content

Post Processing

Good graphics are good. That's why I was excited to find adding Post Processing to my Unity 3D project was a huge improvement. This enables common modern graphics features like Motion Blur, Ambient Occlusion, Depth of Field, and more.

Add Post Processing

Post Processing is added to each scene individually, and not a project as a whole. To add this to a Unity 3D project, we first need to add the Post-process Layer component to our scene's main camera. Its important that the camera the player views the game from contains this component. Otherwise, if the player can toggle between a camera which has the Post-process Layer and one that does not, they effects gained by post processing will only be rendered in one view and not the other.

Once we've added the above component to the scene's main camera, we need to adjust the layer of both this component and our main camera to reflect this. Change to the Postprocessing Layer in the Post-process Layer component.

Now change the layer of the camera itself to the Postprocessing Layer as well

Now anywhere within your current scene hierarchy, add an empty GameObject and name it PostProcessingVolume or otherwise something relative to your specific scenario. Select this new GameObject and within the inspector Add Component->Post-processing Volume as seen below

At a glance, there is not much here. But once we add a Post Process Profile and finish configuring our scene we will use this component to adjust some pretty neat looking visuals. Click New to the right of the Profile field in our new Post-processing Layer component

Unity will automatically create a Post Processing Profile and place it in a directory relative to your scene. Now we can check the Global tick box to apply this volume to our entire scene and start adding new effects to our scene!

An example of some effects that I added to my scene to achieve the screenshot at the top of this page

Emission Lighting

In my screenshot at the beginning of this page, I have a work light that both emits area light from the light source (bulbs) and shines a spot light. The combination of the two makes for a GameObject which is pretty realistic, and for this Post Processing is required.

Post Processing Enabled

Post Processing Disabled

First, you'll need to define the source of light emission. For my particular object, the only sources of light are isolated to the two bulbs at the top. It is important in this case to have the needed texture maps to configure emission from the source. Otherwise, you will have to create these texture maps yourself and apply them to the material, defining where the light source is.

For this GameObject's material, the albedo texture is seen below.

It's easy to see the bulb near the center of this texture, but how do we define that area as our source of light? Below we see an Emission Color map, which simply shows the bulb in a lit state.

Now we can apply the Emission Color map to our material by checking the Emission tick-box and applying this texture in the Color field.

Now we can adjust the color swatch to the right of this texture as needed to adjust the emission light color. It's important to also adjust the Intensity of the color emission here to be relevant to your light source. For a work light, they are ultra bright so I wanted to wash the texture out with an ultra-white glow. Since you would literally be blinded by these things in real life if you were to start into the bulbs, you would not see details of the light bulb or its material.

That's it! See the glow coming from the lights in the picture below for an example of how this can add visuals to any light source.

The other scenario here is just creating a new material which is entirely emissive of one color. This is very simple to do, so I figured I'd show a more specific example using an Emission Color map. Below, I've left a screenshot of an ultra-simple emssive material and the result of applying this to a barrel object within the same scene as my work light, with the same Post Processing configuration.