#include <collision/frustum.h>
Collaboration diagram for neo::collision::Frustum:

Public Types | |
| enum | PlaneID |
| Frustum planes. | |
Public Member Functions | |
| bool | intersect (const math::Vector3 &point) const |
| Test if point is inside frustum. | |
| bool | intersect (const AABB &aabb) const |
| Test if AABB is inside frustum. | |
| bool | intersect (const OBB &obb) const |
| Test if OBB is inside frustum. | |
| bool | intersect (const Sphere &sphere) const |
| Test if sphere is inside frustum. | |
| bool | intersect (const Volume *p_volume, bool def=true) const |
| Test if generic volume is inside frustum. | |
Public Attributes | |
| unsigned int | _signP [6][3] |
| unsigned int | _signN [6][3] |
| Plane | _planes [6] |
| math::Vector3 | _direction |
| float | _zNear |
| float | _zFar |
| bool neo::collision::Frustum::intersect | ( | const math::Vector3 & | point | ) | const |
Test if point is inside frustum
| point | Point |
| bool neo::collision::Frustum::intersect | ( | const AABB & | aabb | ) | const |
| bool neo::collision::Frustum::intersect | ( | const OBB & | obb | ) | const |
| bool neo::collision::Frustum::intersect | ( | const Sphere & | sphere | ) | const |
Test if sphere is inside frustum
| sphere | Sphere |
| bool neo::collision::Frustum::intersect | ( | const Volume * | p_volume, | |
| bool | def = true | |||
| ) | const [inline] |
Test if generic volume is inside frustum. If a null pointer is passed, the default value is returned
| p_volume | Volume | |
| def | Default return value |
| unsigned int neo::collision::Frustum::_signP[6][3] |
Vertex signs. These indicate which box corner in the AA box should be used as near and far vertex when culling against frustum during rendering. 6 planes in frustum as first index. Second index is vertex component, 0 = x, 1 = y, 2 = z. A value of 0 is positive and 1 is negative
| unsigned int neo::collision::Frustum::_signN[6][3] |
N is inverted P but precalculate to gain speed
The equation data (normal and distance) for the 6 frustum planes
View vector (which is negated Z vector of local coordinate system in world space)
Near plane distance along direction
Far plane distance along direction
1.5.1