OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
AxisCross.h
Go to the documentation of this file.
1#pragma once
2
3#include "OTCore/Color.h"
4
5#include <osg/Geode>
6#include <osgText/Text>
7
8namespace osg {
9 class Group;
10 class ShapeDrawable;
11 class MatrixTransform;
12}
13
14class AxisCross {
15public:
16 AxisCross(osg::Group * _parentGroup, osgText::Font *_font);
17 virtual ~AxisCross();
18
19 void setVisible(bool _visible);
20
21 bool isVisible(void) const { return m_isVisible; }
22
24
25 void setTransformation(osg::Matrix matrix);
26
27 void setTextColor(double color[3]);
28private:
29
30 void rebuildNode(void);
31
32 void createArrow(osg::Geode * _geode, const ot::Color& _color);
33 void createText(osg::Geode * _geode, const std::string &label);
34
35 osg::Group * m_parentGroup;
36 osg::ref_ptr<osg::Geode> m_xNode;
37 osg::ref_ptr<osg::Geode> m_yNode;
38 osg::ref_ptr<osg::Geode> m_zNode;
39 osg::ref_ptr<osg::Geode> m_centerPoint;
40 osg::ref_ptr<osg::MatrixTransform> m_xTransform;
41 osg::ref_ptr<osg::MatrixTransform> m_yTransform;
42 osg::ref_ptr<osg::MatrixTransform> m_zTransform;
43
44 osg::ref_ptr<osg::MatrixTransform> m_axisCrossNode;
45
46 double textColor[3];
47
48 osgText::Font *font;
49
50 float m_midpointX;
51 float m_midpointY;
52 float m_midpointZ;
53 float m_size;
54 float m_cylinderRadius;
55
56 bool m_isVisible;
57 bool m_isIdentity;
58};
Definition AxisCross.h:14
bool isVisible(void) const
Definition AxisCross.h:21
void setVisible(bool _visible)
Definition AxisCross.cpp:73
void refreshAfterSettingsChange(void)
Definition AxisCross.cpp:79
void setTextColor(double color[3])
Definition AxisCross.cpp:83
AxisCross(osg::Group *_parentGroup, osgText::Font *_font)
Definition AxisCross.cpp:23
void setTransformation(osg::Matrix matrix)
Definition AxisCross.cpp:43
virtual ~AxisCross()
Definition AxisCross.cpp:39
Definition Group.h:20
The Color class is used to represent RGBA colors with integer values.
Definition Color.h:72
Definition RubberbandOsgWrapper.h:22