The Size
property of the BBox
struct represents the calculated size of the Axis-Aligned Bounding Box (AABB) on each axis. This property provides a Vector3
value that indicates the dimensions of the bounding box in 3D space.
The Size
property of the BBox
struct represents the calculated size of the Axis-Aligned Bounding Box (AABB) on each axis. This property provides a Vector3
value that indicates the dimensions of the bounding box in 3D space.
Use the Size
property to retrieve the dimensions of a BBox
instance. This can be useful for understanding the spatial extent of the bounding box in your game or application.
Note that this property is read-only and is automatically calculated based on the minimum and maximum extents of the bounding box.
// Example of accessing the Size property of a BBox BBox boundingBox = new BBox(new Vector3(0, 0, 0), new Vector3(10, 10, 10)); Vector3 size = boundingBox.Size; // Output the size of the bounding box // size will be (10, 10, 10) in this case Debug.Log($"Bounding Box Size: {size}");