Camera class abstract Scene graph
A view onto a scene: a world-space eye position and orientation paired with a lens projection, used by Scene.render to map the scene into clip space.
A camera separates its view (where it is and which way it looks, from getViewMatrix) from its projection (the lens, a CameraProjection). PerspectiveCamera is the built-in free camera, positioned by eye/target/up. Attach a CameraComponent to a Node to drive the view from that node's transform instead.
- Implementers
Constructors
- Camera()
Properties
- forward → Vector3
-
The world-space direction the camera looks along (unit length).
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- position → Vector3
-
The world-space position of the camera (the eye point). Used by
materials for view-dependent shading (e.g. specular reflections).
no setter
- projection → CameraProjection
-
The lens projection paired with this camera's view.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- up → Vector3
-
The world-space up direction used to orient the camera around
forward.
no setter
Methods
-
getFrustum(
Size dimensions) → Frustum -
Returns the view frustum (six normalized clip planes) for a render
target of the given
dimensions. -
getViewMatrix(
) → Matrix4 - Returns the world-to-view transform (the view matrix), independent of the render target size.
-
getViewTransform(
Size dimensions) → Matrix4 -
Returns the combined projection-and-view transform for a render target
of the given
dimensions. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
screenPointToRay(
Offset screenPosition, Size viewSize) → Ray -
Maps a position inside a view (logical pixels, origin top-left) to the
world-space ray leaving the camera through that point, for picking
(
Scene.raycast) and pointer input.viewSizeis the view's logical size (the constraintsSceneViewrenders into). -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited