Public Member Functions | |
| void | set (vec3 min, vec3 max) |
| Assign specific values. | |
| vec3 | center () |
| Return the center of the box. | |
| void | center (vec3 value) |
| Change the center of the box. | |
| bit | concontains (vec3 point) |
| Return whether this point is conservatively within the box. | |
| bit | concontains (box3 box) |
| Return whether this box conservatively envelopes b (greater than rather than greater than or equal to) . | |
| bit | conoverlaps (box3 box) |
| Return whether the box conservatively overlaps the other box. | |
| bit | contains (vec3 point) |
| Return whether the point is within the box. | |
| bit | contains (box3 box) |
| Return whether this box fully envelopes b. | |
| vec3 | dim () |
| Get the dimensions of the box. | |
| void | dim (vec3 value) |
| Alter the dimensions of the box without changing the center. | |
| void | ensure (vec3 point) |
| Ensure that the bounds contain this point. | |
| void | ensure (box3 box) |
| Ensure that the bounds contain this box. | |
| bit | isnan () |
| Return whether this is an uninitialised box. | |
| bit | overlaps (box3 box) |
| Return whether this box overlaps the other box. | |
| bit | overlaps (sphere3 sphere) |
| Return whether the sphere overlaps or is within the box. | |
| bit | overlaps (obb3 obb) |
| Return whether the oriented bounding box overlaps or is within the box. | |
| vec3 | nearestPoint (vec3 vector) |
| Return the nearest point in the box to the vector. | |
| vec3 | corner (uint index) |
| Return an indexed corner of the box. | |
| sphere3 | toSphere () |
| Return the sphere that encapsulates the box. | |
| char[] | toString () |
| Convert to string. | |
Operator overloading. | |
| box3 | add (vec3 value) |
| box3 = (box3 + vec3) | |
| box3 | addass (vec3 value) |
| box3 = (box3 += vec3) | |
| box3 | sub (vec3 value) |
| box3 = (box3 - vec3) | |
| box3 | subass (vec3 value) |
| box3 = (box3 -= vec3) | |
Static Public Member Functions | |
| box3 | create (vec3 vector) |
| Create the box with a specific value. | |
| box3 | create (vec3 min, vec3 max) |
| Create a box with specific values. | |
| box3 | fromCenter (vec3 center, vec3 length) |
| Create a box by specifying the center and the length of each side. | |
Public Attributes | |
| vec3 | min |
| Starting bounds. | |
| vec3 | max |
| Ending bounds. | |
Related Functions | |
| (Note that these are not member functions.) | |
| box3 | abox3 (vec3 vector) |
| Create a box with a specific bound. | |
| box3 | abox3 (vec3 min, vec3 max) |
| Create a box with specific bounds. | |
|
|
Return an indexed corner of the box.
|
|
|
Return whether the oriented bounding box overlaps or is within the box.
|
|
|
Return whether the sphere overlaps or is within the box.
|
|
|
Return the sphere that encapsulates the box.
|
1.3.2