SOFA API  c76874b7
Open source framework for multi-physics simuation
sofa::component::collision::InfoFilter Class Referenceabstract

#include <LocalMinDistanceFilter.h>

LocalMinDistance cone information class for an unique collision primitive. More...

Inheritance diagram for sofa::component::collision::InfoFilter:

Detailed Description

LocalMinDistance cone information class for an unique collision primitive.

Protected Attributes

int m_revision
 Last filter update revision. More...
 
const LocalMinDistanceFilterm_lmdFilters
 The LocalMinDistanceFilters object that contains this InfoFilter. More...
 
core::topology::BaseMeshTopologybase_mesh_topology
 
const sofa::helper::vector< sofa::defaulttype::Vector3 > * position_filtering
 

Public Member Functions

 InfoFilter (LocalMinDistanceFilter *lmdFilters)
 Default constructor. More...
 
virtual ~InfoFilter ()
 Default destructor. More...
 
virtual bool validate (const unsigned int, const defaulttype::Vector3 &)=0
 Returns the validity of a detected contact according to the InfoFilter. More...
 
virtual bool isValid (void)
 Returns cone information validity (up to date or not?). More...
 
virtual void setValid ()
 Sets cone information validity. More...
 
const LocalMinDistanceFiltergetLMDFilters (void)
 Returns the LocalMinDistanceFilters object that contains this InfoFilter. More...
 
void setLMDFilters (const LocalMinDistanceFilter *lmdFilters)
 Sets the LocalMinDistanceFilters object that contains this InfoFilter. More...
 
void setBaseMeshTopology (core::topology::BaseMeshTopology *bmt)
 
void setPositionFiltering (const sofa::helper::vector< sofa::defaulttype::Vector3 > *x)
 

Protected Member Functions

virtual void buildFilter (unsigned int)=0
 If InfoFilter data is invalid, computes the region of interest cone of the collision primitive. More...
 

Attribute details

core::topology::BaseMeshTopology* sofa::component::collision::InfoFilter::base_mesh_topology
protected
const LocalMinDistanceFilter* sofa::component::collision::InfoFilter::m_lmdFilters
protected

The LocalMinDistanceFilters object that contains this InfoFilter.

int sofa::component::collision::InfoFilter::m_revision
protected

Last filter update revision.

const sofa::helper::vector< sofa::defaulttype::Vector3 >* sofa::component::collision::InfoFilter::position_filtering
protected

Constructor details

sofa::component::collision::InfoFilter::InfoFilter ( LocalMinDistanceFilter lmdFilters)
inline

Default constructor.

Parameters
m_revisionCone information is up to date.
m_lmdFiltersThe localMinDistance filtration class that contains this InfoFilter.
virtual sofa::component::collision::InfoFilter::~InfoFilter ( )
inlinevirtual

Default destructor.

Function details

virtual void sofa::component::collision::InfoFilter::buildFilter ( unsigned  int)
protectedpure virtual

If InfoFilter data is invalid, computes the region of interest cone of the collision primitive.

If the collision primitive is mapped to a rigid MState, the computation is only an update according to the rigid transformation.

Implemented in sofa::component::collision::LineInfo, sofa::component::collision::PointInfo, and sofa::component::collision::TriangleInfo.

const LocalMinDistanceFilter* sofa::component::collision::InfoFilter::getLMDFilters ( void  )
inline

Returns the LocalMinDistanceFilters object that contains this InfoFilter.

bool sofa::component::collision::InfoFilter::isValid ( void  )
virtual

Returns cone information validity (up to date or not?).

void sofa::component::collision::InfoFilter::setBaseMeshTopology ( core::topology::BaseMeshTopology bmt)
inline
void sofa::component::collision::InfoFilter::setLMDFilters ( const LocalMinDistanceFilter lmdFilters)
inline

Sets the LocalMinDistanceFilters object that contains this InfoFilter.

void sofa::component::collision::InfoFilter::setPositionFiltering ( const sofa::helper::vector< sofa::defaulttype::Vector3 > *  x)
inline
void sofa::component::collision::InfoFilter::setValid ( )
virtual

Sets cone information validity.

virtual bool sofa::component::collision::InfoFilter::validate ( const unsigned  int,
const defaulttype::Vector3 &   
)
pure virtual

Returns the validity of a detected contact according to the InfoFilter.

Implemented in sofa::component::collision::LineInfo, sofa::component::collision::PointInfo, and sofa::component::collision::TriangleInfo.