Skip to main content

abstract BaseCamera

Abstract class representing a camera in a 3D world. All cameras should use this class as a base.

Extends​

Extended by​

Properties​

controls?​

optional abstract controls: CameraControls

Optional CameraControls instance for controlling the camera. This property is only available if the camera is controllable.


enabled​

abstract enabled: boolean

Whether the camera is enabled or not.


onWorldChanged​

readonly onWorldChanged: Event<object>

Event that is triggered when a world is added or removed from the worlds map. The event payload contains the world instance and the action ("added" or "removed").

Type declaration​

action​

action: "added" | "removed"

world​

world: World

Inherited from​

BaseWorldItem . onWorldChanged


three​

abstract three: Camera

The Three.js camera instance.

Accessors​

currentWorld​

set currentWorld(value): void

The current world this item is associated with. It can be null if no world is currently active.

Parameters​

ParameterType
valuenull | World

Methods​

hasCameraControls()​

hasCameraControls(): this is CameraControllable

Checks whether the instance is CameraControllable.

Returns​

this is CameraControllable

True if the instance is controllable, false otherwise.


isConfigurable()​

isConfigurable(): this is Configurable<any, any>

Whether is component is Configurable.

Returns​

this is Configurable<any, any>

Inherited from​

BaseWorldItem . isConfigurable


isDisposeable()​

isDisposeable(): this is Disposable

Whether is component is Disposable.

Returns​

this is Disposable

Inherited from​

BaseWorldItem . isDisposeable


isHideable()​

isHideable(): this is Hideable

Whether is component is Hideable.

Returns​

this is Hideable

Inherited from​

BaseWorldItem . isHideable


isResizeable()​

isResizeable(): this is Resizeable

Whether is component is Resizeable.

Returns​

this is Resizeable

Inherited from​

BaseWorldItem . isResizeable


isSerializable()​

isSerializable(): this is Serializable<any, Record<string, any>>

Whether is component is Serializable.

Returns​

this is Serializable<any, Record<string, any>>

Inherited from​

BaseWorldItem . isSerializable


isUpdateable()​

isUpdateable(): this is Updateable

Whether is component is Updateable.

Returns​

this is Updateable

Inherited from​

BaseWorldItem . isUpdateable