Options
All
  • Public
  • Public/Protected
  • All
Menu

Class BoundingInfo

Info for a bounding data of a mesh

Hierarchy

  • BoundingInfo

Implements

Index

Constructors

constructor

Properties

Readonly boundingBoxSearch playground for boundingBox

boundingBox: BoundingBox

Bounding box for the mesh

Readonly boundingSphereSearch playground for boundingSphere

boundingSphere: BoundingSphere

Bounding sphere for the mesh

Accessors

diagonalLength

  • get diagonalLength(): number
  • Gets the world distance between the min and max points of the bounding box

    Returns number

isLocked

  • get isLocked(): boolean
  • set isLocked(value: boolean): any
  • If the info is locked and won't be updated to avoid perf overhead

    Returns boolean

  • If the info is locked and won't be updated to avoid perf overhead

    Parameters

    • value: boolean

    Returns any

maximum

  • max vector of the bounding box/sphere

    Returns Vector3

minimum

  • min vector of the bounding box/sphere

    Returns Vector3

Methods

centerOnSearch playground for centerOn

  • Recreate the bounding info to be centered around a specific point given a specific extend.

    Parameters

    Returns BoundingInfo

    the current bounding info

encapsulateSearch playground for encapsulate

  • Grows the bounding info to include the given point.

    Parameters

    • point: Vector3

      The point that will be included in the current bounding info

    Returns BoundingInfo

    the current bounding info

encapsulateBoundingInfoSearch playground for encapsulateBoundingInfo

  • Grows the bounding info to encapsulate the given bounding info.

    Parameters

    • toEncapsulate: BoundingInfo

      The bounding info that will be encapsulated in the current bounding info

    Returns BoundingInfo

    the current bounding info

intersectsSearch playground for intersects

intersectsPointSearch playground for intersectsPoint

isCompletelyInFrustumSearch playground for isCompletelyInFrustum

  • Checks if a cullable object (mesh...) is in the camera frustum Unlike isInFrustum this checks the full bounding box

    Parameters

    Returns boolean

    true if the object is in frustum otherwise false

isInFrustumSearch playground for isInFrustum

  • Returns true if the bounding info is within the frustum defined by the passed array of planes.

    Parameters

    • frustumPlanes: Array<DeepImmutable<Plane>>

      defines the frustum to test

    • Optional strategy: number

      defines the strategy to use for the culling (default is BABYLON.AbstractMesh.CULLINGSTRATEGY_STANDARD)

    Returns boolean

    true if the bounding info is in the frustum planes

reConstructSearch playground for reConstruct

  • Recreates the entire bounding info from scratch as if we call the constructor in place

    Parameters

    Returns void

scaleSearch playground for scale

  • Scale the current bounding info by applying a scale factor

    Parameters

    • factor: number

      defines the scale factor to apply

    Returns BoundingInfo

    the current bounding info

updateSearch playground for update

  • Updates the bounding sphere and box

    Parameters

    Returns void

Legend

  • Constructor
  • Property
  • Method
  • Accessor
  • Property
  • Method
  • Inherited property
  • Inherited method
  • Static property
  • Static method