Nightly releases are generated automatically from the latest source code and are intended for experimental purposes only.
These builds may contain incomplete or untested features, bugs, or security vulnerabilities, and as such, are not for production use.
Users should be aware that nightly releases may cause unexpected behavior, data loss, or system instability.
Use of these releases is at the user's own risk, and it is advised to have adequate backups before testing.
The software is provided as is with no guarantees or support.
This interfaces provides functions for working with BoxVolumes.
BoxVolumes are axis aligned bounding boxes (AABB). They are usually used to describe the minimal bounding box of a node.
They consist of six values, 3 for the minimum and 3 for the maximum corner.
Extends this box in such a way that both, newMin and newMax, are included.
If one of the given values is already inside the box, nothing is done (i.e., the box is potentially extended,
but never shrunk after calling this function).
If this box has no valid minimum / maximum yet, the given values are used.
Extends a BoxVolume by another BoxVolume.
The resulting BoxVolume will span over the other BoxVolume, too. If the other BoxVolume is already inside
this BoxVolume, nothing is done.
the number array with 6 values, representing the minimum and maximum corners of the BoxVolume
Returns boolean
true if the new BoxVolume is valid, false otherwise
getCenter
getCenter():Float32Array<ArrayBufferLike>
Gets the center point of the BoxVolume.
The point is specified as a single array with the format [x, y, z].
Returns Float32Array<ArrayBufferLike>
the center point of the BoxVolume
getCornerPoints
getCornerPoints():Float32Array<ArrayBufferLike>[]
Gets the corner points of a BoxVolume.
Returns Float32Array<ArrayBufferLike>[]
An array of eight Float32Array objects. Each Float32Array represents a corner
point of the bounding box in 3D space, with the fourth component set to 1.
getDiameter
getDiameter():number
Gets the diameter of the BoxVolume.
Returns number
The diameter of the bounding box, which is the Euclidean distance between
the minimum and maximum coordinates.
getMax
getMax():Float32Array<ArrayBufferLike>
Gets the maximum point of the BoxVolume.
The point is specified as a single array with the format [x, y, z].
Returns Float32Array<ArrayBufferLike>
the maximum point of the BoxVolume
getMin
getMin():Float32Array<ArrayBufferLike>
Gets the minimum point of the BoxVolume.
The point is specified as a single array with the format [x, y, z].
Returns Float32Array<ArrayBufferLike>
the minimum point of the BoxVolume
getRadialVec
getRadialVec():Float32Array<ArrayBufferLike>
Gets the radial vector of the BoxVolume.
Returns Float32Array<ArrayBufferLike>
A Float32Array representing the radial vector, which is half the difference
between the maximum and minimum coordinates of the bounding box.
getSize
getSize():Float32Array<ArrayBufferLike>
Gets the size of the BoxVolume.
Returns Float32Array<ArrayBufferLike>
the size of the BoxVolume, specified as a single array with the format [max_x - min_x, max_y - min_y, max_z - min_z].
This interfaces provides functions for working with BoxVolumes. BoxVolumes are axis aligned bounding boxes (AABB). They are usually used to describe the minimal bounding box of a node. They consist of six values, 3 for the minimum and 3 for the maximum corner.