Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Constructors

constructor

Properties

Protected _eventCallbackDicts

_eventCallbackDicts: {} = {}

Type declaration

_pose

Protected _projection

_projection: Mat4

Protected _subscriptions

_subscriptions: {} = {}

Type declaration

lrbt

lrbt: number[]

movementSpeed

movementSpeed: number

state

state: {} = {}

Type declaration

  • [name: string]: any

uid

uid: string

zFar

zFar: number

zNear

zNear: number

zoom

zoom: number

Static AObjectStateKeys

AObjectStateKeys: string[] = []

Static AObjectVersion

AObjectVersion: number = 1

Static CameraUpdateEvents

CameraUpdateEvents: typeof CamUpdateEvents = ...

Static DEFAULT_FAR

DEFAULT_FAR: number = ...

Static DEFAULT_NEAR

DEFAULT_NEAR: number = ...

Accessors

ClassConstructor

  • get ClassConstructor(): typeof AObject

PV

_nearPlaneCenter

  • get _nearPlaneCenter(): Vec2

_nearPlaneWH

  • get _nearPlaneWH(): Vec2

aspect

  • get aspect(): number

backward

  • get backward(): Vec3

forward

frustumBottom

  • get frustumBottom(): number

frustumLeft

  • get frustumLeft(): number

frustumRight

  • get frustumRight(): number

frustumTop

  • get frustumTop(): number

modelMatrix

  • get modelMatrix(): Mat4

pose

projection

  • get projection(): Mat4
  • set projection(p: Mat4): void

right

serializationLabel

  • get serializationLabel(): any

stateSnapshop

  • get stateSnapshop(): {}

up

viewMatrix

  • get viewMatrix(): Mat4

Methods

_getEventCallbackDict

_getFarPlaneMatrix

  • _getFarPlaneMatrix(camera: Camera): Mat4
  • gets a matrix with: x column: the vector from the left of the far plane to the right of the far plane in world coords y column: the vector from the bottom of the far plane to the top of the far plane in world coords z column: the vector from the near to the far plane in world coords w column: the location of the middle of the far plane

    Parameters

    • camera: Camera

    Returns Mat4

_getListeners

  • _getListeners(): {}

_getNearPlaneMatrix

  • _getNearPlaneMatrix(camera: Camera): Mat4
  • gets a matrix with: x column: the vector from the left of the near plane to the right of the near plane in world coords y column: the vector from the bottom of the near plane to the top of the near plane in world coords z column: the vector from the near to the far plane in world coords w column: the location of the middle of the near plane

    Parameters

    • camera: Camera

    Returns Mat4

_setProjection

  • _setProjection(projection: Mat4, signalEvent?: boolean): void

activateSubscription

  • activateSubscription(name: string): void

addEventListener

  • addEventListener(eventName: string, callback: (...args: any[]) => void, handle?: string): AEventCallbackSwitch

addEventListeners

  • addEventListeners(eventName: string, callbacks: ((...args: any[]) => void)[], handle?: string): AEventCallbackSwitch

addOneTimeEventListener

  • addOneTimeEventListener(eventName: string, callback: (...args: any[]) => void, handle?: string): AEventCallbackSwitch

addPoseListener

  • addPoseListener(callback: (self: AObject) => void, handle?: string, synchronous?: boolean): AStateCallbackSwitch

addProjectionListener

  • addProjectionListener(callback: (self: AObject) => void, handle?: string, synchronous?: boolean): AStateCallbackSwitch

addStateKeyListener

  • addStateKeyListener(state_key: string, callback: (self: AObject) => void, handle?: string, synchronous?: boolean): AStateCallbackSwitch
  • Sets a callback function to be called whenever the state specified in state_key changes. The return value callbackSwitch is a callback switch. You can activate the listener with callbackSwitch.activate() and deactive with callbackSwitch.deactivate(). Example Usage:

    var callbackswitch = model.addStateKeyListener('name',()=>{
    n_name_changes = n_name_changes+1;
    })

    Parameters

    • state_key: string

      the name of the state to listen to

    • callback: (self: AObject) => void

      the callback to be executed when state changes

    • Optional handle: string

      the handle / unique identifier for

    • synchronous: boolean = true

      whether callbacks should happen synchronously or allow for batching

    Returns AStateCallbackSwitch

addStateListener

  • addStateListener(callback: (self: AObject) => void, handle?: string, synchronous?: boolean): AStateCallbackSwitch

clearSubscriptions

  • clearSubscriptions(): void

deactivateSubscription

  • deactivateSubscription(name: string): void

dispose

  • dispose(): void

getHUDTransform

  • getHUDTransform(): Mat4

getPose

getProjectedPoint

getProjection

  • getProjection(): Mat4

getProjectionInverse

  • getProjectionInverse(): Mat4

getWorldSpaceProjectionOnNearPlane

  • getWorldSpaceProjectionOnNearPlane(p: Vec3 | Vec4, offset?: number): Vec3

getWorldToNDC

  • getWorldToNDC(): Mat4

Abstract onCanvasResize

  • onCanvasResize(width: number, height: number): void

onZoomUpdate

  • onZoomUpdate(): void

removeEventListener

  • removeEventListener(eventName: string, handle: string): void

removeListener

  • removeListener(handle: string): void

setPose

setPosition

  • setPosition(position: Vec3): void

setProjection

  • setProjection(projection: Mat4): void

setWithThreeJSCamera

  • setWithThreeJSCamera(camera: Camera): void

signalEvent

  • signalEvent(eventName: string, ...args: any[]): void

subscribe

toJSON

  • toJSON(): {}

unsubscribe

  • unsubscribe(name: string, errorIfAbsent?: boolean): void

Abstract updateProjection

  • updateProjection(): void

Static CreateWithState

  • CreateWithState(state: {}): AObject

Static SerializationLabel

  • SerializationLabel(): any

Static fromJSON

Generated using TypeDoc