Camera

Home

A Camera is an Urbject that is used to represent the physical location, orientation, and field of view of a camera in the Scene.

See also: Urbject, Scene, Renderer, PerformanceRenderer

Constructors

Camera( ): Camera Initializes with default attribute values.
Camera( { fov?: number, position?: Vector, orientation?: Quaternion, scale?: number | Vector, state?: number, group?: number, superCopy?: Urbject } ): Camera Initializes with the given values or default values if not provided. The default values are:

fov 60 The field of view of the Camera in degrees. Range: [1, 360]
position new Vector(-10, 0, 0) The position of the Camera in 3D space. by default, this is set to be located at -10 units on the X-Axis so the Camera has a clear view of the origin of the scene. See also: Urbject
orientation Default from Urbject constructor See also: Urbject
scale Default from Urbject constructor See also: Urbject
state Default from Urbject constructor See also: Urbject
group Default from Urbject constructor See also: Urbject
superCopy Default from Urbject constructor See also: Urbject

Variables

Public Variables

fov: number The field of view of the Camera in degrees. Expected domain: [1, 360]

Functions

Public Functions

copy(options?: { shallow: boolean } ): Camera Returns a copy of the Camera. If shallow is true, the children of this Urbject will not be included in the copy.

Static Functions

Camera.copy(c: Camera, options?: { shallow: boolean } ): Camera Returns a copy of the Camera or a new Camera from an Object with all of the necessary Camera and Urbject public attributes. If shallow is true, the children of the Urbject will not be included in the copy.

Home

Copyright © 2020 Trevor Richard