Struct MinMaxAABB
Axis aligned bounding box (AABB) stored in min and max form.
Namespace: Unity.Mathematics
Syntax
[Serializable]
public struct MinMaxAABB
Remarks
Axis aligned bounding boxes (AABB) are boxes where each side is parallel with one of the Cartesian coordinate axes X, Y, and Z. AABBs are useful for approximating the region an object (or collection of objects) occupies and quickly testing whether or not that object (or collection of objects) is relevant. Because they are axis aligned, they are very cheap to construct and perform overlap tests with them.
Fields
Name | Description |
---|---|
Max | The maximum point contained by the AABB. |
Min | The minimum point contained by the AABB. |
Properties
Name | Description |
---|---|
Empty | An empty AABB - where the minimum and maximum coordinates are at opposing infinities. |
IsEmpty | Is this AABB empty? It is empty only if the minimum and maximum coordinates are at opposing infinities. |
Methods
Name | Description |
---|---|
Encapsulate(float3) | Encapsulates the given AABB. |
Encapsulate(MinMaxAABB) | Make this AABB into the smallest AABB that contains both this AABB, and another AABB. |
Equals(MinMaxAABB) | Determine whether this MinMaxAABB is the same as another MinMaxAABB |
Operators
Name | Description |
---|---|
Implicit(AABB to MinMaxAABB) | Make a MinMaxAABB from an AABB (an AABB which has a center and extents) |
Implicit(MinMaxAABB to AABB) | Make an AABB (an AABB which has a center and extents) from a MinMaxAABB |