#ifndef CMass_H
#define CMass_H
#include <string>
#include "SimObject.h"
class CMass :
public SimObject
{
public:
CMass(std::string sSimObjectName, ISimObjectCreator* pCreator );
#ifdef FH_VISUALIZATION
virtual void RenderInit(Ogre::Root* const ogreRoot, ISimObjectCreator* const creator);
virtual void RenderUpdate(const double T, const double* const X);
#endif
virtual void OdeFcn(
const double dT,
const double*
const adX,
double* const adXDot, const bool bIsMajorTimeStep);
protected:
virtual const double* Position(const double dT, const double* const adX);
virtual const double* Velocity(const double dT, const double* const adX);
#ifdef FH_VISUALIZATION
std::string m_sMaterial;
std::string m_sMeshName;
double m_dScale;
Ogre::Entity* m_pRenderEntity;
Ogre::SceneNode* m_pRenderNode;
Ogre::SceneManager* m_pSceneMgr;
#endif
};
#endif
Class containing a 3dof mass simObjec without gravity.
Definition: CMass.h:19
double m_dg
The acceleration of gravity.
Definition: CMass.h:41
int m_IStateVel
The index of the velocity state.
Definition: CMass.h:44
double m_dMass
The mass of the object.
Definition: CMass.h:40
virtual void OdeFcn(const double dT, const double *const adX, double *const adXDot, const bool bIsMajorTimeStep)
Calculates the state derivatives.
CMass(std::string sSimObjectName, ISimObjectCreator *pCreator)
The constructor sets the pointer to the output object and the parser object.
int m_IStatePos
The index of the position state.
Definition: CMass.h:43
ISignalPort * m_pInForce
A pointer to the input force.
Definition: CMass.h:42