Class CinemachineFollowZoom
An add-on module for Cinemachine Virtual Camera that adjusts the FOV of the lens to keep the target object at a constant size on the screen, regardless of camera and target position.
Inherited Members
Namespace: Cinemachine
Syntax
[DocumentationSorting(DocumentationSortingAttribute.Level.UserRef)]
public class CinemachineFollowZoom : CinemachineExtension
Fields
m_Damping
Increase this value to soften the aggressiveness of the follow-zoom. Small numbers are more responsive, larger numbers give a more heavy slowly responding camera.
Declaration
public float m_Damping
Field Value
Type | Description |
---|---|
System.Single |
m_MaxFOV
Will not generate an FOV larget than this.
Declaration
public float m_MaxFOV
Field Value
Type | Description |
---|---|
System.Single |
m_MinFOV
Will not generate an FOV smaller than this.
Declaration
public float m_MinFOV
Field Value
Type | Description |
---|---|
System.Single |
m_Width
The shot width to maintain, in world units, at target distance. FOV will be adusted as far as possible to maintain this width at the target distance from the camera.
Declaration
public float m_Width
Field Value
Type | Description |
---|---|
System.Single |
Methods
PostPipelineStageCallback(CinemachineVirtualCameraBase, CinemachineCore.Stage, ref CameraState, Single)
Callback to preform the zoom adjustment
Declaration
protected override void PostPipelineStageCallback(CinemachineVirtualCameraBase vcam, CinemachineCore.Stage stage, ref CameraState state, float deltaTime)
Parameters
Type | Name | Description |
---|---|---|
CinemachineVirtualCameraBase | vcam | |
CinemachineCore.Stage | stage | |
CameraState | state | |
System.Single | deltaTime |