sofa::component::collision::NewProximityIntersection Class Reference

#include <NewProximityIntersection.h>

Inheritance diagram for sofa::component::collision::NewProximityIntersection:

Inheritance graph
[legend]
Collaboration diagram for sofa::component::collision::NewProximityIntersection:

Collaboration graph
[legend]

Public Member Functions

 NewProximityIntersection ()
virtual void init ()
 Initialization method called at graph modification, during bottom-up traversal.
virtual bool useProximity () const
 returns true if algorithm uses proximity
double getAlarmDistance () const
 Return the alarm distance (must return 0 if useNewProximity() is false).
double getContactDistance () const
 Return the contact distance (must return 0 if useNewProximity() is false).
void setAlarmDistance (double v)
void setContactDistance (double v)
bool testIntersection (Cube &, Cube &)
bool testIntersection (Point &, Point &)
template<class Sphere >
bool testIntersection (Sphere &, Point &)
template<class Sphere >
bool testIntersection (Sphere &, Sphere &)
bool testIntersection (Line &, Point &)
template<class Sphere >
bool testIntersection (Line &, Sphere &)
bool testIntersection (Line &, Line &)
bool testIntersection (Triangle &, Point &)
template<class Sphere >
bool testIntersection (Triangle &, Sphere &)
bool testIntersection (Triangle &, Line &)
bool testIntersection (Triangle &, Triangle &)
bool testIntersection (Ray &, Triangle &)
int computeIntersection (Cube &, Cube &, OutputVector *)
int computeIntersection (Point &, Point &, OutputVector *)
template<class Sphere >
int computeIntersection (Sphere &, Point &, OutputVector *)
template<class Sphere >
int computeIntersection (Sphere &, Sphere &, OutputVector *)
int computeIntersection (Line &, Point &, OutputVector *)
template<class Sphere >
int computeIntersection (Line &, Sphere &, OutputVector *)
int computeIntersection (Line &, Line &, OutputVector *)
int computeIntersection (Triangle &, Point &, OutputVector *)
template<class Sphere >
int computeIntersection (Triangle &, Sphere &, OutputVector *)
int computeIntersection (Triangle &, Line &, OutputVector *)
int computeIntersection (Triangle &, Triangle &, OutputVector *)
int computeIntersection (Ray &, Triangle &, OutputVector *)

Static Public Member Functions

static int doIntersectionLineLine (double dist2, const Vector3 &p1, const Vector3 &p2, const Vector3 &q1, const Vector3 &q2, OutputVector *contacts, int id)
static int doIntersectionLinePoint (double dist2, const Vector3 &p1, const Vector3 &p2, const Vector3 &q, OutputVector *contacts, int id, bool swapElems=false)
static int doIntersectionPointPoint (double dist2, const Vector3 &p, const Vector3 &q, OutputVector *contacts, int id)
static int doIntersectionTrianglePoint (double dist2, int flags, const Vector3 &p1, const Vector3 &p2, const Vector3 &p3, const Vector3 &n, const Vector3 &q, OutputVector *contacts, int id, bool swapElems=false)

Data Fields

Data< double > alarmDistance
Data< double > contactDistance

Detailed Description

Definition at line 46 of file NewProximityIntersection.h.


Constructor & Destructor Documentation

sofa::component::collision::NewProximityIntersection::NewProximityIntersection (  ) 

Definition at line 55 of file NewProximityIntersection.cpp.


Member Function Documentation

int sofa::component::collision::NewProximityIntersection::computeIntersection ( Ray &  t1,
Triangle &  t2,
OutputVector *  contacts 
)

int sofa::component::collision::NewProximityIntersection::computeIntersection ( Triangle &  e1,
Triangle &  e2,
OutputVector *  contacts 
)

int sofa::component::collision::NewProximityIntersection::computeIntersection ( Triangle &  e1,
Line &  e2,
OutputVector *  contacts 
)

template<class Sphere >
int sofa::component::collision::NewProximityIntersection::computeIntersection ( Triangle &  e1,
Sphere &  e2,
OutputVector *  contacts 
) [inline]

int sofa::component::collision::NewProximityIntersection::computeIntersection ( Triangle &  e1,
Point &  e2,
OutputVector *  contacts 
)

int sofa::component::collision::NewProximityIntersection::computeIntersection ( Line &  e1,
Line &  e2,
OutputVector *  contacts 
)

template<class Sphere >
int sofa::component::collision::NewProximityIntersection::computeIntersection ( Line &  e1,
Sphere &  e2,
OutputVector *  contacts 
) [inline]

int sofa::component::collision::NewProximityIntersection::computeIntersection ( Line &  e1,
Point &  e2,
OutputVector *  contacts 
)

template<class Sphere >
int sofa::component::collision::NewProximityIntersection::computeIntersection ( Sphere &  e1,
Sphere &  e2,
OutputVector *  contacts 
) [inline]

template<class Sphere >
int sofa::component::collision::NewProximityIntersection::computeIntersection ( Sphere &  e1,
Point &  e2,
OutputVector *  contacts 
) [inline]

int sofa::component::collision::NewProximityIntersection::computeIntersection ( Point &  e1,
Point &  e2,
OutputVector *  contacts 
)

int sofa::component::collision::NewProximityIntersection::computeIntersection ( Cube &  ,
Cube &  ,
OutputVector *   
)

int sofa::component::collision::NewProximityIntersection::doIntersectionLineLine ( double  dist2,
const Vector3 &  p1,
const Vector3 &  p2,
const Vector3 &  q1,
const Vector3 &  q2,
OutputVector *  contacts,
int  id 
) [inline, static]

int sofa::component::collision::NewProximityIntersection::doIntersectionLinePoint ( double  dist2,
const Vector3 &  p1,
const Vector3 &  p2,
const Vector3 &  q,
OutputVector *  contacts,
int  id,
bool  swapElems = false 
) [inline, static]

int sofa::component::collision::NewProximityIntersection::doIntersectionPointPoint ( double  dist2,
const Vector3 &  p,
const Vector3 &  q,
OutputVector *  contacts,
int  id 
) [inline, static]

int sofa::component::collision::NewProximityIntersection::doIntersectionTrianglePoint ( double  dist2,
int  flags,
const Vector3 &  p1,
const Vector3 &  p2,
const Vector3 &  p3,
const Vector3 &  n,
const Vector3 &  q,
OutputVector *  contacts,
int  id,
bool  swapElems = false 
) [inline, static]

double sofa::component::collision::NewProximityIntersection::getAlarmDistance (  )  const [inline, virtual]

Return the alarm distance (must return 0 if useNewProximity() is false).

Reimplemented from sofa::core::componentmodel::collision::Intersection.

Definition at line 60 of file NewProximityIntersection.h.

References alarmDistance, and sofa::core::objectmodel::Data< T >::getValue().

Referenced by computeIntersection(), and testIntersection().

double sofa::component::collision::NewProximityIntersection::getContactDistance (  )  const [inline, virtual]

Return the contact distance (must return 0 if useNewProximity() is false).

Reimplemented from sofa::core::componentmodel::collision::Intersection.

Definition at line 63 of file NewProximityIntersection.h.

References contactDistance, and sofa::core::objectmodel::Data< T >::getValue().

Referenced by computeIntersection().

void sofa::component::collision::NewProximityIntersection::init ( void   )  [virtual]

void sofa::component::collision::NewProximityIntersection::setAlarmDistance ( double  v  )  [inline]

void sofa::component::collision::NewProximityIntersection::setContactDistance ( double  v  )  [inline]

bool sofa::component::collision::NewProximityIntersection::testIntersection ( Ray &  t1,
Triangle &  t2 
)

bool sofa::component::collision::NewProximityIntersection::testIntersection ( Triangle &  ,
Triangle &   
)

Definition at line 245 of file NewProximityIntersection.cpp.

bool sofa::component::collision::NewProximityIntersection::testIntersection ( Triangle &  ,
Line &   
)

template<class Sphere >
bool sofa::component::collision::NewProximityIntersection::testIntersection ( Triangle &  ,
Sphere &   
) [inline]

Definition at line 362 of file NewProximityIntersection.inl.

bool sofa::component::collision::NewProximityIntersection::testIntersection ( Triangle &  ,
Point &   
)

Definition at line 172 of file NewProximityIntersection.cpp.

bool sofa::component::collision::NewProximityIntersection::testIntersection ( Line &  ,
Line &   
)

Definition at line 148 of file NewProximityIntersection.cpp.

template<class Sphere >
bool sofa::component::collision::NewProximityIntersection::testIntersection ( Line &  ,
Sphere &   
) [inline]

Definition at line 338 of file NewProximityIntersection.inl.

bool sofa::component::collision::NewProximityIntersection::testIntersection ( Line &  ,
Point &   
)

Definition at line 126 of file NewProximityIntersection.cpp.

template<class Sphere >
bool sofa::component::collision::NewProximityIntersection::testIntersection ( Sphere &  e1,
Sphere &  e2 
) [inline]

template<class Sphere >
bool sofa::component::collision::NewProximityIntersection::testIntersection ( Sphere &  e1,
Point &  e2 
) [inline]

bool sofa::component::collision::NewProximityIntersection::testIntersection ( Point &  e1,
Point &  e2 
)

bool sofa::component::collision::NewProximityIntersection::testIntersection ( Cube &  cube1,
Cube &  cube2 
)

virtual bool sofa::component::collision::NewProximityIntersection::useProximity (  )  const [inline, virtual]

returns true if algorithm uses proximity

Reimplemented from sofa::core::componentmodel::collision::Intersection.

Definition at line 57 of file NewProximityIntersection.h.


Field Documentation

Definition at line 49 of file NewProximityIntersection.h.

Referenced by getAlarmDistance(), and setAlarmDistance().

Definition at line 50 of file NewProximityIntersection.h.

Referenced by getContactDistance(), and setContactDistance().


The documentation for this class was generated from the following files:

Generated on Sun Nov 23 04:17:30 2008 for Sofa by  doxygen 1.5.7.1