OrthographicCamera

The orthographic camera class, which has no "bigger when it's closer, small when it's far" effect. Size will not be affected by the distance.

Core Class

The orthographic camera class, which has no “bigger when it’s closer, small when it’s far” effect. Size will not be affected by the distance.

Extends

Constructors

Constructor

new OrthographicCamera(left?, right?, top?, bottom?, near?, far?): OrthographicCamera

Parameters

left?

number

number

top?

number

bottom?

number

near?

number

far?

number

Returns

OrthographicCamera

Overrides

Camera3D.constructor

Properties

DefaultUp

static DefaultUp: Vector3

Every objects in 3D space must have a default up direction.

Default Value

Vector3(0, 1, 0)

Inherited from

Camera3D.DefaultUp


id

id: number

Unique number for each object3D instance.

Inherited from

Camera3D.id


categoryId

categoryId: string

Reserved attribute

Inherited from

Camera3D.categoryId


sourceType

sourceType: string

Record the object rendered as instance or other type.

Inherited from

Camera3D.sourceType


scene

scene: Nullable<Scene3D>

The scene which this object belong to.

Inherited from

Camera3D.scene


updateDirtyId

updateDirtyId: number

The number is the frame id which this object is changed or participates change of scene graph. If this value equals to frame id - 1,

Default Value

-1 means no change happen

Inherited from

Camera3D.updateDirtyId


name

name: string

The name of this object, it is empty if useless.

Inherited from

Camera3D.name


isObject3D

isObject3D: boolean

Used to check type of this or extended instance. This value should not be changed by user.

Inherited from

Camera3D.isObject3D


parent

parent: Nullable<Object3D>

Object’s parent node in the scene graph. An object can have at most one parent.

Inherited from

Camera3D.parent


children

children: Object3D[]

Array with object’s children.

Remarks

See Group| Group for information on manually grouping objects.

Inherited from

Camera3D.children


up

up: Vector3

This is used by the lookAt method, for example, to determine the orientation of the result. Default is DefaultUp.

Inherited from

Camera3D.up


worldMatrixUpdateTimestamp

worldMatrixUpdateTimestamp: number

Record when this object’s world matrix last updated.

Inherited from

Camera3D.worldMatrixUpdateTimestamp


transformChanged

transformChanged: boolean

Record whether the object’s any attribute| attribute is updated.

Inherited from

Camera3D.transformChanged


visibleChanged

visibleChanged: boolean

Inherited from

Camera3D.visibleChanged


matrixWorld

matrixWorld: Matrix4

The global transform of the object. If the Object3D has no parent, then it’s identical to the local transform matrix.

Inherited from

Camera3D.matrixWorld


matrixWorldNeedsUpdate

matrixWorldNeedsUpdate: boolean

When this is set, it calculates the matrixWorld in that frame and resets this property to false.

Default Value

false

Inherited from

Camera3D.matrixWorldNeedsUpdate


netVisibility

netVisibility: boolean

Record if the object is really visible in rendering process. If the Object3D has no parent, it would be set by visible;

Inherited from

Camera3D.netVisibility


localMatrixNeedUpdate

localMatrixNeedUpdate: boolean

When this is set, it calculates the model matrix in that frame and resets this property to false.

Default Value

false

Inherited from

Camera3D.localMatrixNeedUpdate


enableFrustumCulling

enableFrustumCulling: boolean

Inherited from

Camera3D.enableFrustumCulling


enableDetailCulling

enableDetailCulling: boolean

Inherited from

Camera3D.enableDetailCulling


isCamera3D

isCamera3D: boolean

Check the type whether it belongs to Camera3D. This value should not be changed by user.

Inherited from

Camera3D.isCamera3D


type

type: string

The type of this Object3D.

Inherited from

Camera3D.type


matrixWorldInverse

matrixWorldInverse: Matrix4

This is the inverse of matrixWorld. MatrixWorld contains the Matrix which has the world transform of the Camera3D.

Inherited from

Camera3D.matrixWorldInverse


worldRotation

worldRotation: Matrix4

Inherited from

Camera3D.worldRotation


worldPosition

worldPosition: Vector3

Inherited from

Camera3D.worldPosition


projectionMatrix

projectionMatrix: Matrix4

This matrix decides the method of projection such as perspective and orthographic.

Inherited from

Camera3D.projectionMatrix


projectionMatrixInverse

projectionMatrixInverse: Matrix4

The inverse matrix of projectionMatrix.

Inherited from

Camera3D.projectionMatrixInverse


bounds

bounds: Vector4

This is used to adapt the bounds of camera to canvas.

Inherited from

Camera3D.bounds


isOrthographicCamera

isOrthographicCamera: boolean

Check the type whether it belongs to OrthographicCamera. This value should not be changed by user.


view

view: Nullable<CameraView>

Frustum window specification or null. This is set using the setViewOffset method and cleared using clearViewOffset.


userData

readonly userData: Record<keyof any, any>

Inherited from

Camera3D.userData


_uuid

_uuid: any

Inherited from

Camera3D._uuid


uuid

uuid: string

Inherited from

Camera3D.uuid


_listeners

_listeners: Map<Symbol, Listener<never>[]>

Inherited from

Camera3D._listeners

Accessors

layers

Get Signature

get layers(): Layers

Returns

Layers

Set Signature

set layers(v): void

Parameters
v

Layers

Returns

void

Inherited from

Camera3D.layers


interactionLayers

Get Signature

get interactionLayers(): Layers | undefined

Returns

Layers | undefined

Set Signature

set interactionLayers(v): void

Parameters
v

Layers | undefined

Returns

void

Inherited from

Camera3D.interactionLayers


groupLayer

Get Signature

get groupLayer(): Layers | undefined

Returns

Layers | undefined

Set Signature

set groupLayer(v): void

Parameters
v

Layers | undefined

Returns

void

Inherited from

Camera3D.groupLayer


position

Get Signature

get position(): Vector3

Returns

Vector3

Set Signature

set position(_position): void

A vector representing the object’s local position.

Parameters
_position

Vector3

Returns

void

Inherited from

Camera3D.position


rotation

Get Signature

get rotation(): Euler

Returns

Euler

Set Signature

set rotation(rotation): void

Object’s local rotation, in radians.

Parameters
rotation

Euler

Returns

void

Inherited from

Camera3D.rotation


quaternion

Get Signature

get quaternion(): Quaternion

Returns

Quaternion

Set Signature

set quaternion(_quaternion): void

Object’s local rotation as a Quaternion.

Remarks

See Quaternion for more details.

Parameters
_quaternion

Quaternion

Returns

void

Inherited from

Camera3D.quaternion


scale

Get Signature

get scale(): Vector3

Returns

Vector3

Set Signature

set scale(_scale): void

The object’s local scale.

Default Value

Vector3( 1, 1, 1 )

Parameters
_scale

Vector3

Returns

void

Inherited from

Camera3D.scale


matrix

Get Signature

get matrix(): Matrix4

The local transform matrix.

Returns

Matrix4

Set Signature

set matrix(value): void

Parameters
value

Matrix4

Returns

void

Inherited from

Camera3D.matrix


visible

Get Signature

get visible(): boolean

Object gets rendered if true.

Default Value

true

Returns

boolean

Set Signature

set visible(value): void

Parameters
value

boolean

Returns

void

Inherited from

Camera3D.visible


zoom

Get Signature

get zoom(): number

Scale width and height of view frustum.

Returns

number

Set Signature

set zoom(v): void

Parameters
v

number

Returns

void


left

Get Signature

get left(): number

Distance from projective plane center to left side.

Returns

number

Set Signature

set left(v): void

Parameters
v

number

Returns

void


right

Get Signature

get right(): number

Distance from projective plane center to right side.

Returns

number

Set Signature

set right(v): void

Parameters
v

number

Returns

void


top

Get Signature

get top(): number

Returns

number

Set Signature

set top(v): void

Parameters
v

number

Returns

void


bottom

Get Signature

get bottom(): number

Returns

number

Set Signature

set bottom(v): void

Parameters
v

number

Returns

void


near

Get Signature

get near(): number

Returns

number

Set Signature

set near(v): void

Parameters
v

number

Returns

void


far

Get Signature

get far(): number

Returns

number

Set Signature

set far(v): void

Parameters
v

number

Returns

void


businessTag

Get Signature

get businessTag(): string

Returns

string

Set Signature

set businessTag(v): void

Parameters
v

string

Returns

void

Inherited from

Camera3D.businessTag

Methods

destroy()

destroy(): void

Returns

void

Inherited from

Camera3D.destroy


freeGPU()

freeGPU(): void

Returns

void

Inherited from

Camera3D.freeGPU


syncData()

syncData(): void

Returns

void

Inherited from

Camera3D.syncData


updateVisibility()

updateVisibility(): boolean

Scene will check the object’s visibility in each render and make change netVisibility based on its and parent’s visible.

Returns

boolean

Inherited from

Camera3D.updateVisibility


clearChangeMark()

clearChangeMark(): void

Set marks of change to false include attributeChanged| attribute, transform and visible.

Returns

void

Inherited from

Camera3D.clearChangeMark


setMatrixUpdated()

setMatrixUpdated(): void

If the local matrix is changed, use this method to manually refresh data in scene graph.

Returns

void

Tips

It’s better to use notifySceneChange() as an alternative.

Inherited from

Camera3D.setMatrixUpdated


notifySceneChange()

notifySceneChange(): void

Use this method to manually refresh data in scene graph and draw again. The engine may not notify every change of the scene. If any effect is not changed with the parameters, use this may solve.

Returns

void

Inherited from

Camera3D.notifySceneChange


setMatrixDirty()

setMatrixDirty(): void

If the local matrix or world matrix is changed, use this method to make engine refresh data in scene graph automatically. This method will set matrixWorldNeedsUpdate and localMatrixNeedUpdate to true.

Returns

void

Inherited from

Camera3D.setMatrixDirty


updateWorldRenderData()

updateWorldRenderData(updateID): boolean

Change matrixWorldNeedsUpdate and worldMatrixUpdateTimestamp state. This method will refresh data of world matrix by updateMatrixWorld

Parameters

updateID

number

This number is used to identify the render.

Returns

boolean

Inherited from

Camera3D.updateWorldRenderData


isFlipped()

isFlipped(): boolean

If there are zero or two negative numbers in xyz, return false, otherwise return true.

Returns

boolean

Inherited from

Camera3D.isFlipped


localToWorld()

localToWorld(vector): Vector3

Converts the vector from local space to world space.

Parameters

vector

Vector3

A vector represents a position in local (object) coordinate.

Returns

Vector3

Inherited from

Camera3D.localToWorld


worldToLocal()

worldToLocal(vector): Vector3

Updates the vector from world space to local space.

Parameters

vector

Vector3

A vector in world coordinate.

Returns

Vector3

Inherited from

Camera3D.worldToLocal


applyMatrix()

applyMatrix(matrix): void

Applies the matrix transform to the object and updates the object’s position, rotation and scale.

Parameters

matrix

Matrix4

A matrix represents the information of transform.

Returns

void

Inherited from

Camera3D.applyMatrix


applyQuaternion()

applyQuaternion(q): this

Applies the rotation represented by the quaternion to the object.

Parameters

q

Quaternion

A Quaternion represents the information of rotation.

Returns

this

Inherited from

Camera3D.applyQuaternion


setRotationFromAxisAngle()

setRotationFromAxisAngle(axis, angle): void

Calls setFromAxisAngle( axis, angle ) on the Quaternion.

Parameters

axis

Vector3

A normalized vector in object space.

angle

number

Angle in radians.

Returns

void

Inherited from

Camera3D.setRotationFromAxisAngle


setRotationFromEuler()

setRotationFromEuler(euler): void

Calls Quaternion.setRotationFromEuler| setRotationFromEuler(euler, true) on the Quaternion.

Parameters

euler

Euler

Euler angle specifying rotation amount.

Returns

void

Inherited from

Camera3D.setRotationFromEuler


setRotationFromMatrix()

setRotationFromMatrix(m): void

Calls setFromRotationMatrix(m) on the Quaternion.

Parameters

m

Matrix4

Euler angle specifying rotation amount.

Returns

void

Inherited from

Camera3D.setRotationFromMatrix


setRotationFromQuaternion()

setRotationFromQuaternion(q): void

Copy the given quaternion to object’s quaternion.

Parameters

q

Quaternion

Euler angle specifying rotation amount.

Returns

void

Inherited from

Camera3D.setRotationFromQuaternion


rotateOnAxis()

rotateOnAxis(axis, angle): this

Rotate an object along an axis in object space. The axis is assumed to be normalized.

Parameters

axis

Vector3

A normalized vector in object space.

angle

number

Angle in radians.

Returns

this

Inherited from

Camera3D.rotateOnAxis


rotateOnWorldAxis()

rotateOnWorldAxis(axis, angle): this

Rotate an object along an axis in world space. The axis is assumed to be normalized. Method Assumes no rotated parent.

Parameters

axis

Vector3

A normalized vector in object space.

angle

number

Angle in radians.

Returns

this

Inherited from

Camera3D.rotateOnWorldAxis


rotateX()

rotateX(angle): this

Rotates the object around x axis in local space.

Parameters

angle

number

The angle to rotate in radians.

Returns

this

Inherited from

Camera3D.rotateX


rotateY()

rotateY(angle): this

Rotates the object around x axis in local space.

Parameters

angle

number

The angle to rotate in radians.

Returns

this

Inherited from

Camera3D.rotateY


rotateZ()

rotateZ(angle): this

Rotates the object around x axis in local space.

Parameters

angle

number

The angle to rotate in radians.

Returns

this

Inherited from

Camera3D.rotateZ


translateOnAxis()

translateOnAxis(axis, distance): this

Translate an object by distance along an axis in object space. The axis is assumed to be normalized.

Parameters

axis

Vector3

A normalized vector in object space.

distance

number

The distance to translate.

Returns

this

Inherited from

Camera3D.translateOnAxis


translateX()

translateX(distance): this

Translates object along x axis in object space by distance units.

Parameters

distance

number

The distance to translate.

Returns

this

Inherited from

Camera3D.translateX


translateY()

translateY(distance): this

Translates object along y axis in object space by distance units.

Parameters

distance

number

The distance to translate.

Returns

this

Inherited from

Camera3D.translateY


translateZ()

translateZ(distance): this

Translates object along z axis in object space by distance units.

Parameters

distance

number

The distance to translate.

Returns

this

Inherited from

Camera3D.translateZ


lookAt()

lookAt(_x): void

Rotates the object to face to a point in world space. This method does not support objects having non-uniformly-scaled parent(s)

Parameters

_x

Vector3

A vector representing position of target in world space.

Returns

void

Inherited from

Camera3D.lookAt


lookAtLocalPoint()

lookAtLocalPoint(_x): void

Rotates the object to face a point in local space.

Parameters

_x

Vector3

A vector representing position of target in local space.

Returns

void

Inherited from

Camera3D.lookAtLocalPoint


add()

add(o): this

Adds object as child of this object. An arbitrary number of objects may be added. Any current parent on an object passed in here will be removed, since an object can have at most one parent. The scene graph change will be immediately notify by engine after adding nodes.

Parameters

o

Object3D | Object3D[]

Parameter can be one object or objects array, all of them is added to this object.

Returns

this

Inherited from

Camera3D.add


remove()

remove(object): this

Remove the specified object form children.

Parameters

object

Object3D

The object which needs to be removed.

Returns

this

Inherited from

Camera3D.remove


removeFromParent()

removeFromParent(): void

Returns

void

Inherited from

Camera3D.removeFromParent


removeAllChildren()

removeAllChildren(): Object3D[]

Remove all children of this object.

Returns

Object3D[]

Inherited from

Camera3D.removeAllChildren


removeObjects()

removeObjects(objects): this

Remove all children in specified objects from this objects. Migrate from tools common

Parameters

objects

Object3D[]

An array of objects which need to be removed.

Returns

this

Inherited from

Camera3D.removeObjects


getObjectById()

getObjectById(id): Object3D

Searches through an object and its children, starting with the object itself, and returns the first with a matching id. Note that ids are assigned in chronological order: 1, 2, 3, …, incrementing by one for each new object.

Parameters

id

number

Unique number of the object instance.

Returns

Object3D

Inherited from

Camera3D.getObjectById


getObjectByName()

getObjectByName(name): Object3D

Searches through an object and its children, starting with the object itself, and returns the first with a matching name. Note that for most objects the name is an empty string by default. You will have to set it manually to make use of this method.

Parameters

name

string

String to match to the children’s Object3D.name property.

Returns

Object3D

Inherited from

Camera3D.getObjectByName


getObjectByProperty()

getObjectByProperty(name, value): Object3D

Searches through an object and its children, starting with the object itself, and returns the first with a property that matches the value given.

Parameters

name

string

The property name to search for.

value

any

Value of the given property.

Returns

Object3D

Inherited from

Camera3D.getObjectByProperty


getWorldPosition()

getWorldPosition(target): Vector3

Return a vector representing the position of the object in world space.

Parameters

target

Vector3

the result will be copied into this Vector3.

Returns

Vector3

Inherited from

Camera3D.getWorldPosition


getWorldQuaternion()

getWorldQuaternion(target): Quaternion

Return a quaternion representing the rotation of the object in world space.

Parameters

target

Quaternion

the result will be copied into this Quaternion.

Returns

Quaternion

Inherited from

Camera3D.getWorldQuaternion


getWorldScale()

getWorldScale(target): Vector3

Return a vector of the scaling factors applied to the object for each axis in world space.

Parameters

target

Vector3

the result will be copied into this Vector3.

Returns

Vector3

Inherited from

Camera3D.getWorldScale


traverse()

traverse(callback): void

Execute the callback on this object and all descendants.

Parameters

callback

(object) => any

A function with as first argument an object3D object.

Returns

void

Inherited from

Camera3D.traverse


traverseWithChildrenSkip()

traverseWithChildrenSkip(callback): void

Execute the callback when return is false, stop traverse the object’s descendants.

Parameters

callback

(object) => boolean

A function with as first argument an object3D object, return boolean.

Returns

void

Inherited from

Camera3D.traverseWithChildrenSkip


traverseVisible()

traverseVisible(callback): void

Execute the callback on this object and all descendants which is visible.

Parameters

callback

(object) => any

A function with as first argument an object3D object.

Returns

void

Inherited from

Camera3D.traverseVisible


traverseAncestors()

traverseAncestors(callback): void

Execute the callback on this object and all ancestors.

Parameters

callback

(object) => any

A function with as first argument an object3D object.

Returns

void

Inherited from

Camera3D.traverseAncestors


updateMatrix()

updateMatrix(): void

Update the matrix local transform.

Returns

void

Inherited from

Camera3D.updateMatrix


updateMatrixWorld()

updateMatrixWorld(force?): void

Update the object’s and its descendants’ matrix of global transform with. If the parameter or matrixWorldNeedsUpdate is true, matrix will not skip updates.

Parameters

force?

boolean

Whether or not force to updates the matrix.

Returns

void

Inherited from

Camera3D.updateMatrixWorld


getLocalBounds()

getLocalBounds(localBox?): Box3

Get the whole bounding box of current object cover all children’s.

Parameters

localBox?

Box3

If this is not undefined, result will be stored to it.

Returns

Box3

Inherited from

Camera3D.getLocalBounds


getUUID()

getUUID(): string

Get UUID of this object instance. This value is automatically assigned, so this shouldn’t be edited.

Returns

string

Inherited from

Camera3D.getUUID


notifyCameraChanged()

notifyCameraChanged(): void

Make the engine to render the scene again.

Returns

void

Inherited from

Camera3D.notifyCameraChanged


getWorldDirection()

getWorldDirection(target): Vector3

Set the value of camera’s faced direction to given vector.

Parameters

target

Vector3

this vector representing the world space direction in which the camera is looking.

Returns

Vector3

Inherited from

Camera3D.getWorldDirection


updateWorldMatrix()

updateWorldMatrix(updateParents, updateChildren, force?): void

Update the camera’s matrixWorld and matrixWorldInverse.

Parameters

updateParents

boolean

if true, it also updates all the parents.

updateChildren

boolean

if true, it also updates all the children.

force?

boolean

Whether or not force to updates the matrix.

Returns

void

Inherited from

Camera3D.updateWorldMatrix


updateJitter()

updateJitter(jitter): void

Parameters

jitter

ReadonlyVector2

Returns

void

Inherited from

Camera3D.updateJitter


getJitter()

getJitter(): Readonly<Pick<ReadonlyMarked, "_readonly_mark" | "cloneReadonly" | "clone" | "equals" | "getSerializeData" | "x" | "y" | "getNumberCount" | "toArray" | "width" | "height" | "isVector2" | "dot" | "cross" | "lengthSq" | "length" | "angle" | "manhattanLength" | "distanceTo" | "distanceToSquared" | "manhattanDistanceTo" | "intoSize">>

Returns

Readonly<Pick<ReadonlyMarked, "_readonly_mark" | "cloneReadonly" | "clone" | "equals" | "getSerializeData" | "x" | "y" | "getNumberCount" | "toArray" | "width" | "height" | "isVector2" | "dot" | "cross" | "lengthSq" | "length" | "angle" | "manhattanLength" | "distanceTo" | "distanceToSquared" | "manhattanDistanceTo" | "intoSize">>

Inherited from

Camera3D.getJitter


updatePrev()

updatePrev(): void

Returns

void

Inherited from

Camera3D.updatePrev


pixelsPerUnitCreator()

pixelsPerUnitCreator(viewHeight): (distance) => number

return a function that compute pixelsPerUnit

Parameters

viewHeight

number

Returns

(distance) => number

Inherited from

Camera3D.pixelsPerUnitCreator


getViewIndependentScaleRatio()

getViewIndependentScaleRatio(distance, viewHeight): number

Calculate a scale value that keep one object’s screen unit size match it’s world unit size

Parameters

distance

number

the distance from camera to object.

viewHeight

number

the hight of view window.

Returns

number

Inherited from

Camera3D.getViewIndependentScaleRatio


className()

className(): string

The name of instance’s class.

Returns

string

Overrides

Camera3D.className


copy()

copy(source, recursive?): this

Copy the data to this camera instance from source. This method need override in derived classes to copy extended data.

Parameters

source

OrthographicCamera

the data source.

recursive?

boolean

if true, descendants of the object are also cloned. Default is true.

Returns

this

Overrides

Camera3D.copy


setViewOffset()

setViewOffset(fullWidth, fullHeight, x, y, width, height): void

Parameters

fullWidth

number

fullHeight

number

x

number

y

number

width

number

height

number

Returns

void

Remarks

See PerspectiveCamera for more details.


clearViewOffset()

clearViewOffset(): void

Removes any offset set by the setViewOffset method.

Returns

void


updateProjectionMatrix()

updateProjectionMatrix(jitter?): void

Updates the camera’s projectionMatrix and projectionMatrixInverse. When user change the attribute such as far, top …, this method will have to be called for the changes to take effect.

Parameters

jitter?

if jitters need to be applied on this camera, this parameter need to be given.

offset

Vector2

canvas_size

Vector2

Returns

void

Overrides

Camera3D.updateProjectionMatrix


getPixelsOfDistOne()

getPixelsOfDistOne(): number

The tangent value of camera frustum’s vertical angle.

Returns

number

Overrides

Camera3D.getPixelsOfDistOne


pixelsPerUnit()

pixelsPerUnit(_, viewHeight): number

Calculate how many screen pixel match one world unit at given distance.

Parameters

_

number

viewHeight

number

the hight of view window.

Returns

number

Overrides

Camera3D.pixelsPerUnit


castRay()

castRay(ray, coords): void

Set the origin and direction for ray.

Parameters

ray

Ray

the calculate result will be set to this.

coords

Vector2

the position of window where the ray through out.

Returns

void

Overrides

Camera3D.castRay


serialize()

serialize(ctx): void

Store the attributes of this class into string as serializing format.

Parameters

ctx

Serializer

an instance used to store the data of scene objects.

Returns

void

Overrides

Camera3D.serialize


deserialize()

deserialize(ctx): void

Parse the data for this class from string according to serializing format.

Parameters

ctx

Deserializer

an instance give the method to take the data for attribute.

Returns

void

Overrides

Camera3D.deserialize


clone()

clone(recursive?): OrthographicCamera

Return a cloned instance of this instance.

Parameters

recursive?

boolean

Returns

OrthographicCamera

Overrides

Camera3D.clone


markBusinessTag()

markBusinessTag(v): this

Parameters

v

string

Returns

this

Inherited from

Camera3D.markBusinessTag


isDestroyed()

isDestroyed(): boolean

Returns

boolean

Inherited from

Camera3D.isDestroyed


validate()

validate(): void

Returns

void

Inherited from

Camera3D.validate


destroyAllResourcesOwned()

destroyAllResourcesOwned(): void

Returns

void

Inherited from

Camera3D.destroyAllResourcesOwned


freeAllGpuResourceOwned()

freeAllGpuResourceOwned(): void

Returns

void

Inherited from

Camera3D.freeAllGpuResourceOwned


on()

on<T>(_type, _listener): void

Adds a listener to an event type.

Type Parameters

T

T

Parameters

_type

EventType<T>

_listener

Listener<T>

Returns

void

Inherited from

Camera3D.on


once()

once<T>(_type, _listener): void

Only active the listener one times and then off it| it.

Type Parameters

T

T

Parameters

_type

EventType<T>

_listener

Listener<T>

Returns

void

Inherited from

Camera3D.once


has()

has<T>(_type, _listener): boolean

Checks if listener is added to an event type.

Type Parameters

T

T

Parameters

_type

EventType<T>

_listener

Listener<T>

Returns

boolean

Inherited from

Camera3D.has


off()

off<T>(_type, _listener): void

Removes a listener from listening list.

Type Parameters

T

T

Parameters

_type

EventType<T>

_listener

Listener<T>

Returns

void

Inherited from

Camera3D.off


emit()

Call Signature

emit(type): void

Active the event and call the registered listener.

Parameters
type

EventType<never>

Returns

void

Inherited from

Camera3D.emit

Call Signature

emit<T>(type, payload): void

Type Parameters
T

T

Parameters
type

EventType<T>

payload

T

Returns

void

Inherited from

Camera3D.emit


clearAllListeners()

clearAllListeners(): void

Removes all listeners from listening list.

Returns

void

Inherited from

Camera3D.clearAllListeners