Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Constructors

constructor

Properties

Private _boundings

_boundings: AABB = null

Private _children

_children: Container[] = []

Private _destroyedState

_destroyedState: boolean = false

Private _id

_id: number = 0

Private _modelInverseMatrix

_modelInverseMatrix: mat4 = null

Private _modelMatrix

_modelMatrix: mat4 = null

Private _name

_name: string = null

Private _parent

_parent: Container = null

Private _pivot

_pivot: vec3 = null

Private _rotation

_rotation: quat = null

Private _rotationMatrix

_rotationMatrix: mat4 = null

Private _scale

_scale: vec3 = null

Private _transformAutoUpdateState

_transformAutoUpdateState: boolean = false

Private _translation

_translation: vec3 = null

Private _visibilityState

_visibilityState: boolean = false

Methods

addChild

addChildren

build

computeBoundings

destroy

  • destroy(): void

doTransformAutoUpdate

  • doTransformAutoUpdate(): boolean
  • Indicates if the transforms of the container should be updated automatically

    Returns boolean

getBoundings

  • getBoundings(): AABB

getChildById

getChildByName

getChildren

getId

  • getId(): number

getModelInverseMatrix

  • getModelInverseMatrix(): mat4

getModelMatrix

  • getModelMatrix(): mat4

getName

  • getName(): string

getParent

getPivot

  • getPivot(): vec3

getRotation

  • getRotation(): quat

getRotationMatrix

  • getRotationMatrix(): mat4

getScale

  • getScale(): vec3

getTopLevelParent

getTranslation

  • getTranslation(): vec3

hasChild

hide

  • hide(): void

isDestroyed

  • isDestroyed(): boolean

isVisible

  • isVisible(): boolean

localToWorld

  • localToWorld(vec: vec3): vec3
  • Converts the provided vector from local-space into world-space

    Parameters

    • vec: vec3

      The vector to convert

    Returns vec3

removeChild

render

  • render(encoder: GPURenderPassEncoder): void
  • Render this container This is an internal method

    Parameters

    • encoder: GPURenderPassEncoder

      Encoder object to add commands to

    Returns void

rotate

  • rotate(value: vec3): void
  • Rotates this container

    Parameters

    • value: vec3

      A vector to rotate by (in radians)

    Returns void

rotateByAxisAngle

  • rotateByAxisAngle(axis: vec3, angle: number): void
  • Sets this container's rotation based on the provided axis and angle

    Parameters

    • axis: vec3

      The rotation axis

    • angle: number

      The rotation angle (in radians)

    Returns void

rotateX

  • rotateX(value: number): void
  • Rotates this container on the X axis

    Parameters

    • value: number

      The value to rotate by (in radians)

    Returns void

rotateY

  • rotateY(value: number): void
  • Rotates this container on the Y axis

    Parameters

    • value: number

      The value to rotate by (in radians)

    Returns void

rotateZ

  • rotateZ(value: number): void
  • Rotates this container on the Z axis

    Parameters

    • value: number

      The value to rotate by (in radians)

    Returns void

scale

  • scale(value: vec3): void

scaleX

  • scaleX(value: number): void
  • Scales this container on the X axis

    Parameters

    • value: number

      The value to scale by

    Returns void

scaleY

  • scaleY(value: number): void
  • Scales this container on the Y axis

    Parameters

    • value: number

      The value to scale by

    Returns void

scaleZ

  • scaleZ(value: number): void
  • Scales this container on the Z axis

    Parameters

    • value: number

      The value to scale by

    Returns void

setName

  • setName(value: string): void
  • Update the container name

    Parameters

    • value: string

      The new container name

    Returns void

setParent

setPivot

  • setPivot(value: vec3): void
  • Update the container's rotation pivot

    Parameters

    • value: vec3

      The new container pivot

    Returns void

setRotation

  • setRotation(value: quat): void
  • Update the container's rotation

    Parameters

    • value: quat

      The new container rotation

    Returns void

setScale

  • setScale(value: vec3): void

setTranslation

  • setTranslation(value: vec3): void
  • Update the container's translation

    Parameters

    • value: vec3

      The new container translation

    Returns void

show

  • show(): void

translate

  • translate(value: vec3): void

translateX

  • translateX(value: number): void
  • Translates this container on the X axis

    Parameters

    • value: number

      The number to translate by

    Returns void

translateY

  • translateY(value: number): void
  • Translates this container on the Y axis

    Parameters

    • value: number

      The number to translate by

    Returns void

translateZ

  • translateZ(value: number): void
  • Translates this container on the Z axis

    Parameters

    • value: number

      The number to translate by

    Returns void

update

updateBoundings

  • updateBoundings(): void

updateTransform

  • updateTransform(): void

worldToLocal

  • worldToLocal(vec: vec3): vec3
  • Converts the provided vector from world-space into local-space

    Parameters

    • vec: vec3

      The vector to convert

    Returns vec3

Generated using TypeDoc