SOFA API  73d8bb95
Open source framework for multi-physics simuation
sofa::component::collision::TTriangle< TDataTypes > Class Template Reference

#include <TriangleModel.h>

Inheritance diagram for sofa::component::collision::TTriangle< TDataTypes >:

Public Member Functions

 TTriangle (ParentModel *model, index_type index)
 
 TTriangle ()
 
 TTriangle (const core::CollisionElementIterator &i)
 
 TTriangle (ParentModel *model, index_type index, helper::ReadAccessor< typename DataTypes::VecCoord > &)
 
const Coordp1 () const
 
const Coordp2 () const
 
const Coordp3 () const
 
const Coordp (index_type i) const
 
index_type p1Index () const
 
index_type p2Index () const
 
index_type p3Index () const
 
const Coordp1Free () const
 
const Coordp2Free () const
 
const Coordp3Free () const
 
const Coordoperator[] (index_type i) const
 
const Derivv1 () const
 
const Derivv2 () const
 
const Derivv3 () const
 
const Derivv (index_type i) const
 
const Derivn () const
 
Derivn ()
 
bool hasFreePosition () const
 Return true if the element stores a free position vector. More...
 
int flags () const
 
TTriangleshape ()
 
const TTriangleshape () const
 
Coord interpX (defaulttype::Vec< 2, Real > bary) const
 
- Public Member Functions inherited from sofa::core::TCollisionElementIterator< TriangleCollisionModel< TDataTypes > >
 TCollisionElementIterator (Model *model=nullptr, index_type index=0)
 
 TCollisionElementIterator (Model *model, index_type index, VIterator it, VIterator itend)
 
 TCollisionElementIterator (Model *model, VIterator it, VIterator itend)
 
bool isActive (core::CollisionModel *cm=nullptr) const
 
bool operator== (const TCollisionElementIterator< Model2 > &i) const
 
bool operator!= (const TCollisionElementIterator< Model2 > &i) const
 
bool valid () const
 
ModelgetCollisionModel () const
 Return the CollisionModel containing the referenced element. More...
 
std::pair< CollisionElementIterator, CollisionElementIteratorgetInternalChildren () const
 
std::pair< CollisionElementIterator, CollisionElementIteratorgetExternalChildren () const
 
bool isLeaf () const
 
bool canCollideWith (TCollisionElementIterator< Model > &elem)
 
double getProximity ()
 Distance to the actual (visual) surface. More...
 
double getContactStiffness ()
 Contact stiffness. More...
 
double getContactFriction ()
 Contact friction (damping) coefficient. More...
 
void draw (const core::visual::VisualParams *vparams)
 
- Public Member Functions inherited from sofa::core::BaseCollisionElementIterator
 BaseCollisionElementIterator (index_type index=0)
 
 BaseCollisionElementIterator (index_type index, VIterator it, VIterator itend)
 
 BaseCollisionElementIterator (VIterator it, VIterator itend)
 
void next ()
 Increment this iterator to reference the next element. More...
 
void operator++ ()
 Increment this iterator to reference the next element. More...
 
void operator++ (int)
 Increment this iterator to reference the next element. More...
 
index_type getIndex () const
 
const VIteratorgetVIterator () const
 Return the current iterator in the vector of indices, in case such a vector is currently used. More...
 
const VIteratorgetVIteratorEnd () const
 Return the end iterator in the vector of indices, in case such a vector is currently used. More...
 

Additional Inherited Members

- Public Attributes inherited from sofa::core::TCollisionElementIterator< TriangleCollisionModel< TDataTypes > >
Modelmodel
 CollisionModel containing the referenced element. More...
 
- Protected Attributes inherited from sofa::core::BaseCollisionElementIterator
index_type index
 index of the referenced element inside the CollisionModel. More...
 
VIterator it
 current position in a vector of indices, in case this iterator traverse a non-contiguous set of indices More...
 
VIterator itend
 end position in a vector of indices, in case this iterator traverse a non-contiguous set of indices More...
 
- Static Protected Attributes inherited from sofa::core::BaseCollisionElementIterator
static std::vector< int > SOFA_CORE_API emptyVector
 empty vector to be able to initialize the iterator to an empty pair More...
 

Constructor details

template<class DataTypes >
sofa::component::collision::TTriangle< DataTypes >::TTriangle ( ParentModel model,
index_type  index 
)
inline
template<class TDataTypes>
sofa::component::collision::TTriangle< TDataTypes >::TTriangle ( )
inline
template<class DataTypes >
sofa::component::collision::TTriangle< DataTypes >::TTriangle ( const core::CollisionElementIterator i)
inlineexplicit
template<class DataTypes >
sofa::component::collision::TTriangle< DataTypes >::TTriangle ( ParentModel model,
index_type  index,
helper::ReadAccessor< typename DataTypes::VecCoord > &  x 
)
inline

Function details

template<class DataTypes >
int sofa::component::collision::TTriangle< DataTypes >::flags ( ) const
inline
template<class DataTypes >
bool sofa::component::collision::TTriangle< DataTypes >::hasFreePosition ( ) const
inline

Return true if the element stores a free position vector.

template<class TDataTypes>
Coord sofa::component::collision::TTriangle< TDataTypes >::interpX ( defaulttype::Vec< 2, Real bary) const
inline
template<class DataTypes >
const DataTypes::Deriv & sofa::component::collision::TTriangle< DataTypes >::n ( ) const
inline
template<class DataTypes >
DataTypes::Deriv & sofa::component::collision::TTriangle< DataTypes >::n ( )
inline
template<class DataTypes >
const DataTypes::Coord & sofa::component::collision::TTriangle< DataTypes >::operator[] ( index_type  i) const
inline
template<class DataTypes >
const DataTypes::Coord & sofa::component::collision::TTriangle< DataTypes >::p ( index_type  i) const
inline
template<class DataTypes >
const DataTypes::Coord & sofa::component::collision::TTriangle< DataTypes >::p1 ( ) const
inline
template<class DataTypes >
const DataTypes::Coord & sofa::component::collision::TTriangle< DataTypes >::p1Free ( ) const
inline
template<class DataTypes >
TTriangle< DataTypes >::index_type sofa::component::collision::TTriangle< DataTypes >::p1Index ( ) const
inline
template<class DataTypes >
const DataTypes::Coord & sofa::component::collision::TTriangle< DataTypes >::p2 ( ) const
inline
template<class DataTypes >
const DataTypes::Coord & sofa::component::collision::TTriangle< DataTypes >::p2Free ( ) const
inline
template<class DataTypes >
TTriangle< DataTypes >::index_type sofa::component::collision::TTriangle< DataTypes >::p2Index ( ) const
inline
template<class DataTypes >
const DataTypes::Coord & sofa::component::collision::TTriangle< DataTypes >::p3 ( ) const
inline
template<class DataTypes >
const DataTypes::Coord & sofa::component::collision::TTriangle< DataTypes >::p3Free ( ) const
inline
template<class DataTypes >
TTriangle< DataTypes >::index_type sofa::component::collision::TTriangle< DataTypes >::p3Index ( ) const
inline
template<class TDataTypes>
TTriangle& sofa::component::collision::TTriangle< TDataTypes >::shape ( )
inline
template<class TDataTypes>
const TTriangle& sofa::component::collision::TTriangle< TDataTypes >::shape ( ) const
inline
template<class DataTypes >
const DataTypes::Deriv & sofa::component::collision::TTriangle< DataTypes >::v ( index_type  i) const
inline
template<class DataTypes >
const DataTypes::Deriv & sofa::component::collision::TTriangle< DataTypes >::v1 ( ) const
inline
template<class DataTypes >
const DataTypes::Deriv & sofa::component::collision::TTriangle< DataTypes >::v2 ( ) const
inline
template<class DataTypes >
const DataTypes::Deriv & sofa::component::collision::TTriangle< DataTypes >::v3 ( ) const
inline