API Docs for: 2.7.3
Show:

ObjectHelper.OBB Class

Module: Helpers
Parent Module: Wanaplan

Oriented Bounding Box.

In order to keep things simple and limit space complexity, this class holds minimal mandatory properties.

Constructor

ObjectHelper.OBB

(
  • dimension
  • matrix
)

Parameters:

  • dimension BABYLON.Vector3

    the vector from the origin to the top corner ( positive vector )

  • matrix BABYLON.Matrix

    the transormation matrix of the box, should be a rotation combined with a translation

Item Index

Methods

copyFromAABB

(
  • AABB
)

Sets the OBB in order to define the same volume as the AABB given in argument. The resulting OBB fits exactly the volume.

Parameters:

  • AABB AABB

    the Axis Aligned Bounding Box

Returns:

this

copyFromOyBB

(
  • OyBB
)

Sets the OBB in order to define the same volume as the OBB given in argument. The resulting OBB fits exactly the volume.

Parameters:

  • OyBB OyBB

    the Bounding Box Oriented along y axis

Returns:

this