Marine systems simulation
CDistArrow.h
1#ifndef CDISTARROW_H
2#define CDISTARROW_H
3
54#ifdef FH_VISUALIZATION
55# pragma warning(push)
56# pragma warning(disable : 4251)
57# pragma warning(disable : 4267)
58# include "CFhCamera.h"
59# pragma warning(pop)
60# include "sfh/ogre/CDynamicLines.h"
61# include "sfh/ogre/CMovableText.h"
62#endif
63
64#include "SimObject.h"
65
66#include <string>
67
68class CDistArrow : public SimObject
69{
70 public:
72 CDistArrow(std::string sSimObjectName, ISimObjectCreator* pCreator);
73 ~CDistArrow(void);
74#ifdef FH_VISUALIZATION
76 void RenderInit(Ogre::Root* const ogreRoot, ISimObjectCreator* const creator);
77
79 void RenderUpdate(const double T, const double* const X);
80#endif
81
83 virtual void OdeFcn(const double dTime, const double* const adX, double* const adXDot, const bool bIsMajorTimeStep){};
84
85
86 private:
87 ISignalPort* m_pInVisible;
88 ISignalPort* m_pInPosA;
89 ISignalPort* m_pInPosB;
90
91 double m_dTxtSize;
92 int m_iValPrecision;
93 std::string m_sSuffix;
94
95 long* m_iPosTxt;
96 double m_dDistance;
97
98#ifdef FH_VISUALIZATION
99 Ogre::SceneNode* m_RenderNode;
100 Ogre::CMovableText* m_BBTxt;
101 Ogre::Entity* m_ArrowA;
102 Ogre::Entity* m_ArrowB;
103 Ogre::SceneNode* m_RenderArrowNodeA;
104 Ogre::SceneNode* m_RenderArrowNodeB;
105 Ogre::SceneNode* m_LineNode;
106 CDynamicLines* m_line;
107#endif
108};
109
110#endif
Definition: CDistArrow.h:69
virtual void OdeFcn(const double dTime, const double *const adX, double *const adXDot, const bool bIsMajorTimeStep)
Calculates the state derivatives.
Definition: CDistArrow.h:83
CDistArrow(std::string sSimObjectName, ISimObjectCreator *pCreator)
The constructor sets the pointer to the output object and the parser object.