Set up camera transforms and lens distortion
This page covers how to set up camera transforms and lens distortion.
Prerequisites
To set up camera transforms and lens distortion, ensure you have set up and installed the following components:
- 1 x PC with Vicon software (Shogun) installed
- 1 x PC with Unreal Engine 5 (UE5) installed
- The PCs are connected via LAN
- Vicon Live Link Datastream plugin is installed and enabled on Unreal Engine 5 (see Install and set up a Live Link)
- SDI set up in Vicon software and Unreal Engine
- A UE5 project is open
- A Live Link source has been created and is currently connected to UE5.
Set up camera tracking in Unreal Engine
- Open UE5 and open a project.
- In the Actor Placement panel, search for CineCamera, add it to the scene, and zero out the position of the camera.
- In the World Outliner, select CineCameraActor and then select Add Component.
Find and add a component called Live Link Controller.
Select the new LiveLinkComponentController and in the Subject Representation, select the name of the camera subject.
In the Camera Role field, select Live Link Vicon Camera Controller.
In the Component to Control dropdown select CameraComponent.
Select CineCameraActor and in Filmback > Sensor Width/Height set the width and height to match the camera's sensor size.
Set up lens distortion on a CineCameraActor in Unreal Engine
Important
Ensure you have completed the previous section (Set up camera tracking in Unreal Engine).
Select the CineCameraActor, and in the Details panel add a Lens component.
In the Distortion Source drop-down, select Live Link Lens Subject.
At the top of the CineCameraActor section, click Live Link Component Controller section, and in Lens Role > Component to Control, set the Component Picker to the Lens component.
Select the Lens component, go to Distortion, and select the Apply Distortion checkbox.
Set up lens distortion in Composure in Unreal Engine
Important
Ensure you have completed the previous sections (Set up camera tracking in Unreal Engine and Set up lens distortion on a CineCameraActor in Unreal Engine).
On the Composure Layer tab, complete the following steps for each CG Layer.
Select a CG Layer.
In the Details panel, expand LensDistortion and select Apply Distortion.
Set Lens Component to the CineCamera Lens created in the previous section.
For information on how to add actors to CG Layers, see Real-Time Compositing Tools in the Unreal Engine documentation.
Tip
After you have followed these steps, if the props are misaligned with their real world counterparts when you view the final composure, go back to Shogun and recalibrate the SDI. This realigns the final composure.