31 virtual void UpdateFrustum(
const Matrix4* matViewProj,
bool bInversedMatrix=
false,
float fNearPlane = 0.f,
float fFarPlane = 1.f);
different physics engine has different winding order.
Definition: EventBinding.h:32
Standard 3-dimensional vector.
Definition: ParaVector3.h:16
Vector3 vecFrustum[8]
corners of the view frustum
Definition: ShapeFrustum.h:47
Definition: ShapeSphere.h:6
AABB-related code.
Definition: ShapeAABB.h:11
Plane & GetPlane(int nIndex)
Get a given frustum plane.
Definition: ShapeFrustum.h:36
bool CullPointsWithFrustum(Vector3 *pVecBounds, int nCount)
return true if any of the point is inside the frustum
Definition: ShapeFrustum.cpp:162
Class encapsulating a standard 4x4 homogeneous matrix.
Definition: ParaMatrix4.h:23
int TestBox(const CShapeAABB *box) const
Tests if an AABB is inside/intersecting the view frustum.
Definition: ShapeFrustum.cpp:134
Defines a plane in 3D space.
Definition: ParaPlane.h:23
bool CullPointWithPlane(int iPlane, const Vector3 *vPos)
whether the point is inside a given plane.
Definition: ShapeFrustum.cpp:157
Plane planeFrustum[6]
planes of the view frustum
Definition: ShapeFrustum.h:49
a general view frustum class.
Definition: ShapeFrustum.h:9
virtual void UpdateFrustum(const Matrix4 *matViewProj, bool bInversedMatrix=false, float fNearPlane=0.f, float fFarPlane=1.f)
build a frustum from a camera (projection, or viewProjection) matrix
Definition: ShapeFrustum.cpp:26
static bool SweptSpherePlaneIntersect(float &t0, float &t1, const Plane *plane, const CShapeSphere *sphere, const Vector3 *sweepDir)
this function tests if the projection of a bounding sphere along the light direction intersects the v...
Definition: ShapeFrustum.cpp:64