SOFA API  6a688117
Open source framework for multi-physics simuation
sofa::component::interactionforcefield::PenalityContactForceField< DataTypes >::Contact Class Reference

#include <PenalityContactForceField.h>

Public Attributes

int m1
 
int m2
 the indices of the vertices the force is applied to More...
 
int index1
 
int index2
 the indices of the two collision elements (currently unused) More...
 
Deriv norm
 contact normal, from m1 to m2 More...
 
Real dist
 distance threshold below which a repulsion force is applied More...
 
Real ks
 spring stiffness More...
 
Real pen
 current penetration depth More...
 
int age
 how old is this contact More...
 

Public Member Functions

 Contact (int _m1=0, int _m2=0, int _index1=0, int _index2=0, Deriv _norm=Deriv(), Real _dist=(Real) 0, Real _ks=(Real) 0, Real=(Real) 0, Real=(Real) 0, Real _pen=(Real) 0, int _age=0)
 

Friends

std::istream & operator>> (std::istream &in, Contact &c)
 
std::ostream & operator<< (std::ostream &out, const Contact &c)
 

Attribute details

how old is this contact

distance threshold below which a repulsion force is applied

the indices of the two collision elements (currently unused)

spring stiffness

the indices of the vertices the force is applied to

contact normal, from m1 to m2

current penetration depth

Constructor details

template<class DataTypes >
sofa::component::interactionforcefield::PenalityContactForceField< DataTypes >::Contact::Contact ( int  _m1 = 0,
int  _m2 = 0,
int  _index1 = 0,
int  _index2 = 0,
Deriv  _norm = Deriv(),
Real  _dist = (Real)0,
Real  _ks = (Real)0,
Real  = (Real)0,
Real  = (Real)0,
Real  _pen = (Real)0,
int  _age = 0 
)
inline

Related details

template<class DataTypes >
std::ostream& operator<< ( std::ostream &  out,
const Contact c 
)
friend
template<class DataTypes >
std::istream& operator>> ( std::istream &  in,
Contact c 
)
friend