|
QSDK 1.1 Documentation |
#include <Q/maths.h>
Public Member Functions | |
| Box3f () | |
| Box3f (float minx, float miny, float minz, float maxx, float maxy, float maxz) | |
| Box3f (const Vec3f &vmin, const Vec3f &vmax) | |
| Vec3f | centre () const |
| Vec3f | dimensions () const |
| void | intersect (const Box3f &b) |
| void | add (const Box3f &b) |
| void | add (const Vec3f &p) |
| bool | operator== (const Box3f &box) const |
| bool | operator!= (const Box3f &box) const |
| int | operator<= (const Box3f &) const |
| bool | equal (const Box3f &b, float e=Epsilon) const |
| bool | contains (const Box3f &b) const |
| bool | contains (const Vec3f &p) const |
| bool | intersects (const Box3f &b) const |
| bool | intersects (const Sphere3f &s) const |
| bool | intersects (const Rayf &r, float &rayMin, float &rayMax) const |
| bool | intersects (const Vec3f *v, unsigned int vCount) const |
| void | invalidate () |
| bool | valid () const |
| Box3f | transform (const Matrix4f &mat) const |
| Box3f | inverseTransform (const Matrix4f &mat) const |
| Box3f | expandBy (float delta) const |
| Vec3f & | operator[] (int i) |
| const Vec3f & | operator[] (int i) const |
Public Attributes | |
| Vec3f | bmin |
| Vec3f | bmax |
|
|
Create a new uninitialised box. |
|
||||||||||||||||||||||||||||
|
Create a box with corners (minx,miny,minz) and (maxx,maxy,maxz) |
|
||||||||||||
|
Create a box with corners vmin and vmax |
|
|
Change this box to be the union of this box and the point p. |
|
|
Change this box to be the union of this box and box b. |
|
|
Return the centre point of the box. |
|
|
Return whether the point p is inside the box. |
|
|
Return whether the box b is wholly contained within this box. |
|
|
Return the dimensions of the box. |
|
||||||||||||
|
Return whether this box is equal to b, within e in each dimension. |
|
|
Return the box that is this box expanded by delta units in all directions. |
|
|
Change this box to be the intersection of this box and box b. |
|
||||||||||||
|
Return whether the polygon defined by the array v of size vCount intersects the box. |
|
||||||||||||||||
|
Return whether this box is intersected by the ray r and that the intersection happens between the distances rayMin and rayMax along the ray from its origin. rayMin may be increased by the function to indicate the actual position along the ray at which it entered the box. rayMax maybe be decreased by the function to indicate the actual position along the ray at which it left the box. |
|
|
Return whether this box is intersected by the sphere s. |
|
|
Return whether this box is intersected by the box b. |
|
|
Turns the box inside out, so that it can be used to accumulate results. |
|
|
Return the box that is this box, inverse transformed by the Matrix4f mat. |
|
|
If i is 0, return bmin, if i is 1, return bmax |
|
|
If i is 0, return bmin, if i is 1, return bmax |
|
|
Return the box that is this box, transformed by the Matrix4f mat. |
|
|
Return whether the box is valid. A box is invalid if bmax < bmin. |
|
|
The maximum point of the box in all axes. |
|
|
The minimum point of the box in all axes. |
|
|
|
Qube Software Limited © 2000-2004
|
|