Cinemachine and Postprocessing
Use the Cinemachine Post Processing extension to attach a Postprocessing V2 profile to a Virtual Camera.
Note: Unity recommends using Postprocessing V2 instead of Postprocessing V1.
The Cinemachine Post Processing extension holds a Post-Processing Profile asset to apply to a Virtual Camera when it is activated. If the camera is blending with another Virtual Camera, then the blend weight is applied to the Post Process effects also.
Before attaching post processing profiles to Virtual Cameras, you first need to set up your project to use post processing. You need to do this setup only once.
To set up project to use Post Processing V2 with Cinemachine:
Install the Postprocessing V2 package.
In the Unity menu, choose Cinemachine > Import Post Processing V2 Adaptor Asset Package.
Select your Unity camera with Cinemachine Brain in the Scene view.
Add the component named Post-Process Layer. This will anble Post Process profiles to affect the Camera.
To add a Post Process profile to a Virtual Camera
Select your Virtual Camera in the Scene view or Hierarchy window.
In the Inspector, choose Add Extension > CinemachinePostProcessing, then configre the Profile asset to have the effects you want when this virtual camera is live.
Properties:
Property: | Function: |
---|---|
Profile | The Post-Processing profile to activate when this Virtual Camera is live. |
Focus Tracks Target | Check to set Focus Distance to the distance between the camera and the Look At target. |
Offset | When Focus Tracks Target is checked, this offset is applied to the target position when setting the focus, focus distance. If there is no Look At target, then this is the offset from the Unity camera position, the actual focus distance. |