Class CinematicCamera
- Namespace
- OmegaEngine.Graphics.Cameras
- Assembly
- OmegaEngine.dll
A camera that cinematically swings from one view to another.
public class CinematicCamera : QuaternionCamera, IPositionable
- Inheritance
-
CinematicCamera
- Implements
- Inherited Members
- Extension Methods
Remarks
"Cinematic" means that the movement starts slowly, speeds up dramatically and then slows down again before reaching the target.
Constructors
CinematicCamera(DoubleVector3, DoubleVector3, Quaternion, Quaternion, float, Engine)
Creates a new cinematic camera for the engine
public CinematicCamera(DoubleVector3 sourcePosition, DoubleVector3 targetPosition, Quaternion sourceQuat, Quaternion targetQuat, float duration, Engine engine)
Parameters
sourcePosition
DoubleVector3The initial camera position
targetPosition
DoubleVector3The target camera position
sourceQuat
QuaternionThe initial view as a quaternion
targetQuat
QuaternionThe target view as a quaternion
duration
floatThe complete transition time in seconds
engine
EngineThe Engine containing this camera
Properties
Moving
Is this CinematicCamera currently moving?
public bool Moving { get; }
Property Value
Methods
PerspectiveChange(float, float, float, float)
Called when the user changes the view perspective.
public override void PerspectiveChange(float panX, float panY, float rotation, float zoom)
Parameters
panX
floatThe number of pixels panned along the X-axis divided by the number of pixels of the longest side of the viewport.
panY
floatThe number of pixels panned along the Y-axis divided by the number of pixels of the longest side of the viewport.
rotation
floatHorizontal rotation in degrees.
zoom
floatScaling factor; 1 for no change, must not be 0.
UpdateView()
Update cached versions of View and related matrices
protected override void UpdateView()