SOFA API  b3f2f2a4
Open source framework for multi-physics simuation
sofa::component::mapping::nonlinear::RigidMapping< TIn, TOut >::Loader Class Reference
Inheritance diagram for sofa::component::mapping::nonlinear::RigidMapping< TIn, TOut >::Loader:

Public Attributes

RigidMapping< TIn, TOut > * dest
 
helper::WriteAccessor< Data< OutVecCoord > > points
 

Public Member Functions

 Loader (RigidMapping< TIn, TOut > *dest)
 
void addMass (SReal px, SReal py, SReal pz, SReal, SReal, SReal, SReal, SReal, bool, bool) override
 Add a new mass. More...
 
void addSphere (SReal px, SReal py, SReal pz, SReal) override
 Called by the Loader to specify the number of Spheres before actual loading. More...
 
- Public Member Functions inherited from sofa::helper::io::XspLoaderDataHook
virtual ~XspLoaderDataHook ()
 Destructor, does nothing special. More...
 
virtual void finalizeLoading (bool isOk)
 Called by the XspLoader when the loading is done. More...
 
virtual void setNumMasses (size_t)
 Called by the XspLoader to specify before loading the number of masses. More...
 
virtual void setNumSprings (size_t)
 Called by the XspLoader to specify before loading the number of springs. More...
 
virtual void setGravity (SReal, SReal, SReal)
 Called by the XspLoader to specify the directional gravity. More...
 
virtual void setViscosity (SReal)
 Called by the XspLoader to specify the viscosity. More...
 
virtual void addSpring (size_t, size_t, SReal, SReal, SReal)
 Add a new spring. More...
 
virtual void addVectorSpring (size_t m1, size_t m2, SReal ks, SReal kd, SReal initpos, SReal, SReal, SReal)
 Add an extended spring. More...
 
- Public Member Functions inherited from sofa::helper::io::SphereLoaderDataHook
virtual ~SphereLoaderDataHook ()
 
virtual void finalizeLoading (const bool isOk)
 Called by the XspLoader when the loading is done. More...
 
virtual void setNumSpheres (const int n)
 Called by the XspLoader to specify before loading the number of spheres. More...
 

Attribute details

◆ dest

template<class TIn , class TOut >
RigidMapping<TIn, TOut>* sofa::component::mapping::nonlinear::RigidMapping< TIn, TOut >::Loader::dest

◆ points

template<class TIn , class TOut >
helper::WriteAccessor<Data<OutVecCoord> > sofa::component::mapping::nonlinear::RigidMapping< TIn, TOut >::Loader::points

Constructor details

◆ Loader()

template<class TIn , class TOut >
sofa::component::mapping::nonlinear::RigidMapping< TIn, TOut >::Loader::Loader ( RigidMapping< TIn, TOut > *  dest)
inline

Function details

◆ addMass()

template<class TIn , class TOut >
void sofa::component::mapping::nonlinear::RigidMapping< TIn, TOut >::Loader::addMass ( SReal  ,
SReal  ,
SReal  ,
SReal  ,
SReal  ,
SReal  ,
SReal  ,
SReal  ,
bool  ,
bool   
)
inlineoverridevirtual

Add a new mass.

Parameters
px,py,pz3D position.
vx,vz,vz3D velocity.
mass.
elasticproperty.
fixedboolean indicates that the mass is "static".
surfaceindicates that the mass is on the surface.

Reimplemented from sofa::helper::io::XspLoaderDataHook.

◆ addSphere()

template<class TIn , class TOut >
void sofa::component::mapping::nonlinear::RigidMapping< TIn, TOut >::Loader::addSphere ( SReal  SReal,
SReal  SReal,
SReal  SReal,
SReal  SReal 
)
inlineoverridevirtual

Called by the Loader to specify the number of Spheres before actual loading.

Parameters
px,py,pz3D position of the center.
rthe radius of the sphere.

Reimplemented from sofa::helper::io::SphereLoaderDataHook.