OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
AxisCenterCross.h
Go to the documentation of this file.
1#pragma once
2
3#include "OTCore/Point3D.h"
4#include "OTCore/Color.h"
5#include <osg/Geode>
6
7namespace osg {
8 class Group;
9 class MatrixTransform;
10 class Node;
11}
12
14public:
15 AxisCenterCross(osg::Node * _geometryNode, osg::Group * _parentGroup);
16
17 virtual ~AxisCenterCross();
18
19 // #########################################################################################
20
21 void setVisible(bool _isVisible);
22
23 bool isVisible(void) const { return m_isVisible; }
24
26
28
29 void setTransformation(osg::Matrix &matrix);
30
31 // #########################################################################################
32
33
34private:
35 enum eOrientation {
36 oX,
37 oY,
38 oZ
39 };
40
41 void rebuildNode(void);
42
43 void createArrow(osg::Geode * _geode, const ot::Color& _color, float _lineWidth, eOrientation _o);
44
45 void createDashedLine(osg::Geode * _geode, const ot::Color& _color, float _lineWidth, eOrientation _o);
46
47 void finalizeGeode(osg::Geode * _geode);
48
49 bool m_isVisible;
50
51 osg::Group * m_parentGroup;
52 osg::Node * m_geometryNode;
53
54 osg::ref_ptr<osg::Geode> m_xNode;
55 osg::ref_ptr<osg::Geode> m_yNode;
56 osg::ref_ptr<osg::Geode> m_zNode;
57 osg::ref_ptr<osg::Geode> m_centerPoint;
58
59 osg::ref_ptr<osg::MatrixTransform> m_axisCrossNode;
60
61
62 float m_lineLength;
63
64 AxisCenterCross() = delete;
66 AxisCenterCross& operator = (AxisCenterCross&) = delete;
67};
Definition AxisCenterCross.h:13
void setTransformation(osg::Matrix &matrix)
Definition AxisCenterCross.cpp:37
void refreshAfterSettingsChange(void)
Definition AxisCenterCross.cpp:69
void setVisible(bool _isVisible)
Definition AxisCenterCross.cpp:42
bool isVisible(void) const
Definition AxisCenterCross.h:23
void refreshAfterGeometryChange(void)
Definition AxisCenterCross.cpp:55
virtual ~AxisCenterCross()
Definition AxisCenterCross.cpp:27
Definition Group.h:20
The Color class is used to represent RGBA colors with integer values.
Definition Color.h:72
Definition RubberbandOsgWrapper.h:22