Computer Assited Medical Intervention Tool Kit  version 5.0
TranslationConstraint< DataTypes > Class Template Reference

TODO Comment class here. More...

#include <TranslationConstraint.h>

+ Inheritance diagram for TranslationConstraint< DataTypes >:
+ Collaboration diagram for TranslationConstraint< DataTypes >:

Public Types

typedef DataTypes::Coord Coord
 
typedef DataTypes::Deriv Deriv
 
typedef DataTypes::MatrixDeriv::RowType MatrixDerivRowType
 
typedef DataTypes::VecCoord VecCoord
 template types More...
 
typedef DataTypes::VecCoord::iterator VecCoordIterator
 
typedef DataTypes::VecDeriv VecDeriv
 
typedef DataTypes::VecDeriv::iterator VecDerivIterator
 

Public Member Functions

TranslationConstraint< DataTypes > * addConstraint (unsigned int index, Deriv trans)
 fix or translate a point More...
 
void draw ()
 – VisualModel interface More...
 
std::vector< unsigned int > getTargets ()
 return the targets list More...
 
void initTextures ()
 
virtual void projectPosition (VecCoord &x)
 project x to constrained space (x models a position) More...
 
void projectResponse (MatrixDerivRowType &dx)
 
void projectResponse (VecDeriv &dx)
 Constraint inherits. More...
 
virtual void projectVelocity (VecDeriv &v)
 project dx to constrained space (dx models a velocity) More...
 
TranslationConstraint< DataTypes > * removeConstraint (int index)
 
void setInitTime (double time)
 set initial time (context->getTime() remind the same when simulation is rewind) More...
 
 TranslationConstraint (Loads *loadsList, const std::map< unsigned int, unsigned int > &atomIndexToDOFIndex, sofa::core::behavior::MechanicalState< DataTypes > *mm)
 constructor More...
 
void update ()
 
 ~TranslationConstraint ()
 

Private Member Functions

void fixDOF (int index, int axe)
 fix a point on the axe specified (0=x, 1=y, 2=z) More...
 

Private Attributes

std::map< unsigned int, unsigned int > atomToDOFIndexes
 link between PML object indexes and sofa Dofs Indexes More...
 
VecDeriv directionsNULLs
 list of fixed directions More...
 
VecDeriv initPos
 initial positions More...
 
double initTime
 initial time More...
 
std::vector< Load * > loads
 the lml loads More...
 
sofa::core::behavior::MechanicalState< DataTypes > * mmodel
 the mechanical model More...
 
std::vector< unsigned int > targets
 the set of vertex targets More...
 
VecDeriv translations
 list of translations More...
 

Detailed Description

template<class DataTypes>
class TranslationConstraint< DataTypes >

TODO Comment class here.

Member Typedef Documentation

◆ Coord

template<class DataTypes >
typedef DataTypes::Coord TranslationConstraint< DataTypes >::Coord

◆ Deriv

template<class DataTypes >
typedef DataTypes::Deriv TranslationConstraint< DataTypes >::Deriv

◆ MatrixDerivRowType

template<class DataTypes >
typedef DataTypes::MatrixDeriv::RowType TranslationConstraint< DataTypes >::MatrixDerivRowType

◆ VecCoord

template<class DataTypes >
typedef DataTypes::VecCoord TranslationConstraint< DataTypes >::VecCoord

template types

◆ VecCoordIterator

template<class DataTypes >
typedef DataTypes::VecCoord::iterator TranslationConstraint< DataTypes >::VecCoordIterator

◆ VecDeriv

template<class DataTypes >
typedef DataTypes::VecDeriv TranslationConstraint< DataTypes >::VecDeriv

◆ VecDerivIterator

template<class DataTypes >
typedef DataTypes::VecDeriv::iterator TranslationConstraint< DataTypes >::VecDerivIterator

Constructor & Destructor Documentation

◆ TranslationConstraint()

template<class DataTypes >
TranslationConstraint< DataTypes >::TranslationConstraint ( Loads loadsList,
const std::map< unsigned int, unsigned int > &  atomIndexToDOFIndex,
sofa::core::behavior::MechanicalState< DataTypes > *  mm 
)

constructor

◆ ~TranslationConstraint()

template<class DataTypes >
TranslationConstraint< DataTypes >::~TranslationConstraint ( )
inline

Member Function Documentation

◆ addConstraint()

template<class DataTypes >
TranslationConstraint<DataTypes>* TranslationConstraint< DataTypes >::addConstraint ( unsigned int  index,
Deriv  trans 
)

fix or translate a point

◆ draw()

template<class DataTypes >
void TranslationConstraint< DataTypes >::draw ( )

– VisualModel interface

◆ fixDOF()

template<class DataTypes >
void TranslationConstraint< DataTypes >::fixDOF ( int  index,
int  axe 
)
private

fix a point on the axe specified (0=x, 1=y, 2=z)

◆ getTargets()

template<class DataTypes >
std::vector<unsigned int> TranslationConstraint< DataTypes >::getTargets ( )
inline

return the targets list

Referenced by SofaSimulator::buildConstraints().

+ Here is the caller graph for this function:

◆ initTextures()

template<class DataTypes >
void TranslationConstraint< DataTypes >::initTextures ( )
inline

◆ projectPosition()

template<class DataTypes >
virtual void TranslationConstraint< DataTypes >::projectPosition ( VecCoord x)
virtual

project x to constrained space (x models a position)

◆ projectResponse() [1/2]

template<class DataTypes >
void TranslationConstraint< DataTypes >::projectResponse ( MatrixDerivRowType dx)
inline

◆ projectResponse() [2/2]

template<class DataTypes >
void TranslationConstraint< DataTypes >::projectResponse ( VecDeriv dx)

Constraint inherits.

project dx to constrained space

◆ projectVelocity()

template<class DataTypes >
virtual void TranslationConstraint< DataTypes >::projectVelocity ( VecDeriv v)
virtual

project dx to constrained space (dx models a velocity)

◆ removeConstraint()

template<class DataTypes >
TranslationConstraint<DataTypes>* TranslationConstraint< DataTypes >::removeConstraint ( int  index)

◆ setInitTime()

template<class DataTypes >
void TranslationConstraint< DataTypes >::setInitTime ( double  time)

set initial time (context->getTime() remind the same when simulation is rewind)

Referenced by SofaSimulator::buildConstraints().

+ Here is the caller graph for this function:

◆ update()

template<class DataTypes >
void TranslationConstraint< DataTypes >::update ( )
inline

Member Data Documentation

◆ atomToDOFIndexes

template<class DataTypes >
std::map<unsigned int, unsigned int> TranslationConstraint< DataTypes >::atomToDOFIndexes
private

link between PML object indexes and sofa Dofs Indexes

◆ directionsNULLs

template<class DataTypes >
VecDeriv TranslationConstraint< DataTypes >::directionsNULLs
private

list of fixed directions

◆ initPos

template<class DataTypes >
VecDeriv TranslationConstraint< DataTypes >::initPos
private

initial positions

◆ initTime

template<class DataTypes >
double TranslationConstraint< DataTypes >::initTime
private

initial time

◆ loads

template<class DataTypes >
std::vector<Load*> TranslationConstraint< DataTypes >::loads
private

the lml loads

◆ mmodel

template<class DataTypes >
sofa::core::behavior::MechanicalState<DataTypes>* TranslationConstraint< DataTypes >::mmodel
private

the mechanical model

◆ targets

template<class DataTypes >
std::vector<unsigned int> TranslationConstraint< DataTypes >::targets
private

the set of vertex targets

◆ translations

template<class DataTypes >
VecDeriv TranslationConstraint< DataTypes >::translations
private

list of translations


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