CameraProjection class abstract Scene graph
A lens projection that maps view-space coordinates into clip space.
The projection is the half of a camera that does not depend on where the camera is or what it looks at, only on the lens (field of view, clip planes) and the render target's aspect ratio. Pair one with a view (a Camera's Camera.getViewMatrix) to form a full view-projection transform. PerspectiveProjection and OrthographicProjection are built in; applications can implement CameraProjection for others.
The renderer reads the projection's kind from its matrix, not its type, so a custom pinhole or parallel projection (including an off-center one) gets the same depth-based effects as the built-ins.
- Implementers
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
getProjectionMatrix(
double aspectRatio, {Vector2? jitter}) → Matrix4 -
Returns the projection matrix for a render target of the given
aspectRatio(width / height). -
getProjectionMatrixForViewport(
Size viewportSize, {Vector2? jitter}) → Matrix4 -
Returns the projection matrix for a view
viewportSizein logical pixels. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited