Class CinemachineCameraOffset
An add-on module for Cinemachine Virtual Camera that adds a final offset to the camera
Inheritance
Inherited Members
Namespace: Global Namespace
Assembly: Cinemachine.dll
Syntax
[AddComponentMenu("")]
[ExecuteAlways]
[HelpURL("https://docs.unity3d.com/Packages/com.unity.cinemachine@2.9/api/Cinemachine.CinemachineCameraOffset.html")]
public class CinemachineCameraOffset : CinemachineExtension
Fields
m_ApplyAfter
When to apply the offset
Declaration
[Tooltip("When to apply the offset")]
public CinemachineCore.Stage m_ApplyAfter
Field Value
Type | Description |
---|---|
Cinemachine |
m_Offset
Offset the camera's position by this much (camera space)
Declaration
[Tooltip("Offset the camera's position by this much (camera space)")]
public Vector3 m_Offset
Field Value
Type | Description |
---|---|
Vector3 |
m_PreserveComposition
If applying offset after aim, re-adjust the aim to preserve the screen position of the LookAt target as much as possible
Declaration
[Tooltip("If applying offset after aim, re-adjust the aim to preserve the screen position of the LookAt target as much as possible")]
public bool m_PreserveComposition
Field Value
Type | Description |
---|---|
bool |
Methods
PostPipelineStageCallback(CinemachineVirtualCameraBase, Stage, ref CameraState, float)
Applies the specified offset to the camera state
Declaration
protected override void PostPipelineStageCallback(CinemachineVirtualCameraBase vcam, CinemachineCore.Stage stage, ref CameraState state, float deltaTime)
Parameters
Type | Name | Description |
---|---|---|
Cinemachine |
vcam | The virtual camera being processed |
Cinemachine |
stage | The current pipeline stage |
Camera |
state | The current virtual camera state |
float | deltaTime | The current applicable deltaTime |