![]() |
Gray C++ Libraries
0.0.2
A set of C++ libraries for MSVC, GNU on Windows, WinCE, Linux
|
#include <cSphere.h>
Public Member Functions | |
cSphere2 () | |
cSphere2 (const cVector3f &vCenter, DVALUE_t fObjectRadius) | |
void | put_Radius (DVALUE_t fRadius) |
DVALUE_t | get_RadiusSq () const |
void | SetSphere (const cVector3f &vCenter, DVALUE_t fRadius) |
GINTERSECT_TYPE | GetRayIntersectionFrustum (const cVector3f &vRayOrigin, const cVector3f &vRayDir, cVector3f *pvIntersect, DVALUE_t fDistMaxSq) const |
bool | IsRayIntersectionInFront (const cVector3f &vRayOrigin, const cVector3f &vRayDir, cVector3f *pvIntersect) const |
bool | IsRayIntersectionDistSq (const cVector3f &vRayOrigin, const cVector3f &vRayDir, DVALUE_t fDistMaxSq, OUT cVector3f *pvIntersect) const |
Protected Attributes | |
DVALUE_t | m_fRadiusSq |
keep radius squared. for faster access. More... | |
class to represent a Sphere in 3d space. (float) keep the radius squared for faster access.
|
inline |
|
inline |
|
inline |
GINTERSECT_TYPE GrayLib::cSphere2::GetRayIntersectionFrustum | ( | const cVector3f & | vRayOrigin, |
const cVector3f & | vRayDir, | ||
cVector3f * | pvIntersect, | ||
DVALUE_t | fDistMaxSq | ||
) | const |
ray to sphere intersection test
bool GrayLib::cSphere2::IsRayIntersectionDistSq | ( | const cVector3f & | vRayOrigin, |
const cVector3f & | vRayDir, | ||
DVALUE_t | fDistMaxSq, | ||
OUT cVector3f * | pvIntersect | ||
) | const |
Similar to D3DXSphereBoundProbe but with intersection returned.
bool GrayLib::cSphere2::IsRayIntersectionInFront | ( | const cVector3f & | vRayOrigin, |
const cVector3f & | vRayDir, | ||
cVector3f * | pvIntersect | ||
) | const |
No idea what this means. what is the 'front' of a sphere ? closest intersection to vRayOrigin ?
|
inline |
|
inline |
|
protected |
keep radius squared. for faster access.