Public Types | Public Member Functions | Protected Attributes

OpenTissue::psys::Spring< types > Class Template Reference

#include <psys_spring.h>

List of all members.

Public Types

typedef types::math_types math_types
typedef math_types::real_type real_type
typedef math_types::vector3_type vector3_type
typedef types::particle_type particle_type
typedef types::system_type system_type

Public Member Functions

particle_typeA ()
particle_typeB ()
particle_type const * A () const
particle_type const * B () const
real_typedamping ()
real_type const & damping () const
real_typestiffness ()
real_type const & stiffness () const
real_type const & rest_length () const
 Spring ()
virtual ~Spring ()
void init (particle_type *A, particle_type *B)
void set_rest_length (real_type l)
void set_critical_damped (real_type const &tau)
void apply ()

Protected Attributes

particle_typem_A
 Pointer to one of the affected particles.
particle_typem_B
 Pointer to one other affected particle.
real_type m_length
 Rest length between the two particles.
real_type m_length_sqr
 Rest length squared.
real_type m_k
 Spring Constant.
real_type m_c
 Damping Constant.

template<typename types>
class OpenTissue::psys::Spring< types >


Member Typedef Documentation

template<typename types >
typedef types::math_types OpenTissue::psys::Spring< types >::math_types
template<typename types >
typedef types::particle_type OpenTissue::psys::Spring< types >::particle_type
template<typename types >
typedef math_types::real_type OpenTissue::psys::Spring< types >::real_type
template<typename types >
typedef types::system_type OpenTissue::psys::Spring< types >::system_type

Constructor & Destructor Documentation

template<typename types >
OpenTissue::psys::Spring< types >::Spring (  )  [inline]
template<typename types >
virtual OpenTissue::psys::Spring< types >::~Spring (  )  [inline, virtual]

Member Function Documentation

template<typename types >
particle_type* OpenTissue::psys::Spring< types >::A (  )  [inline]
template<typename types >
particle_type const* OpenTissue::psys::Spring< types >::A (  )  const [inline]
template<typename types >
void OpenTissue::psys::Spring< types >::apply (  )  [inline]
template<typename types >
particle_type* OpenTissue::psys::Spring< types >::B (  )  [inline]
template<typename types >
particle_type const* OpenTissue::psys::Spring< types >::B (  )  const [inline]
template<typename types >
real_type& OpenTissue::psys::Spring< types >::damping (  )  [inline]
template<typename types >
real_type const& OpenTissue::psys::Spring< types >::damping (  )  const [inline]
template<typename types >
void OpenTissue::psys::Spring< types >::init ( particle_type A,
particle_type B 
) [inline]

Init Spring.

Parameters:
A 
B 
template<typename types >
real_type const& OpenTissue::psys::Spring< types >::rest_length (  )  const [inline]
template<typename types >
void OpenTissue::psys::Spring< types >::set_critical_damped ( real_type const &  tau  )  [inline]
Parameters:
tau 
template<typename types >
void OpenTissue::psys::Spring< types >::set_rest_length ( real_type  l  )  [inline]

Set Rest Length.

Parameters:
length 
template<typename types >
real_type const& OpenTissue::psys::Spring< types >::stiffness (  )  const [inline]
template<typename types >
real_type& OpenTissue::psys::Spring< types >::stiffness (  )  [inline]

Member Data Documentation

template<typename types >
particle_type* OpenTissue::psys::Spring< types >::m_A [protected]

Pointer to one of the affected particles.

template<typename types >
particle_type* OpenTissue::psys::Spring< types >::m_B [protected]

Pointer to one other affected particle.

template<typename types >
real_type OpenTissue::psys::Spring< types >::m_c [protected]

Damping Constant.

template<typename types >
real_type OpenTissue::psys::Spring< types >::m_k [protected]

Spring Constant.

template<typename types >
real_type OpenTissue::psys::Spring< types >::m_length [protected]

Rest length between the two particles.

template<typename types >
real_type OpenTissue::psys::Spring< types >::m_length_sqr [protected]

Rest length squared.


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