#include <lib_hair.h>
Hair collider class.
Public Member Functions | |
Bool | Init (HairGuides *hair) |
void | Release () |
Int32 | GetClosestPoint (const Vector &p) |
Bool | GetClosestSegment (const Vector &p, Int32 *guide, Int32 *segment, Float *segt) |
Bool | GetParticleIntersection (const Vector &p, const Vector &v, Float r, Int32 *guide, Int32 *segment, Float *segt, Float *rayt) |
Static Public Member Functions | |
static HairCollider * | Alloc () |
static void | Free (HairCollider *&p) |
Private Member Functions | |
HairCollider () | |
~HairCollider () | |
Private Attributes | |
HairColliderData * | m_pData |
|
private |
|
private |
|
static |
|
static |
Bool Init | ( | HairGuides * | hair | ) |
Initializes the hair collider.
[in] | hair | The hair to initialize with. |
void Release | ( | ) |
Releases allocated memory. Called automatically by Free().
Gets the closest point to p.
[in] | p | The point to search for. |
Gets the closest segment to p.
[in] | p | The point to search for. |
[out] | guide | Assigned the guide index. |
[out] | segment | Assigned the segment index. |
[out] | segt | Assigned the segment t coordinate. |
Bool GetParticleIntersection | ( | const Vector & | p, |
const Vector & | v, | ||
Float | r, | ||
Int32 * | guide, | ||
Int32 * | segment, | ||
Float * | segt, | ||
Float * | rayt | ||
) |
Gets the intersection of particle p with vector v, looking within a distance radius of r.
[in] | p | The point to search for. |
[in] | v | The vector of particle to search for. |
[in] | r | The search distance radius. |
[out] | guide | Assigned the guide index. |
[out] | segment | Assigned the segment index. |
[out] | segt | Assigned the segment t coordinate. |
[out] | rayt | Assigned the ray coordinate. |
|
private |