Basic Image AlgorithmS Library
2.8.0
Main Page
Related Pages
Modules
Classes
Examples
All
Classes
Namespaces
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Groups
Pages
GLviewer
Controller
DistanceMeasureControl.hh
1
#ifndef __DistanceMeasureControl_HH__
2
#define __DistanceMeasureControl_HH__
3
4
#include <bias_config.h>
5
6
#ifndef BIAS_HAVE_OPENGL
7
# error You need BIAS with USE_OpenGL Please recompile BIAS.
8
#endif // BUILD_GLviewer
9
10
11
#ifdef BIAS_HAVE_FONTGL
12
#include <Base/Common/BIASpragmaStart.hh>
13
#include <Utils/DrawTextGL.hh>
14
#include <Base/Common/BIASpragmaEnd.hh>
15
#endif
16
17
#include <Base/Math/Vector3.hh>
18
#include <GLviewer/Controller/TrackballControl.hh>
19
#include <GLviewer/Scenes/SceneBase.hh>
20
21
namespace
BIAS {
22
/**
23
\class DistanceMeasureControl
24
\author Ingo Schiller
25
\date 02/2010
26
\ingroup g_glviewer
27
\brief class for distance measurements in 3d model, derives from TrackballControl and SceneBase
28
*/
29
class
BIASGLviewer_EXPORT
DistanceMeasureControl
:
public
TrackballControl
,
public
SceneBase
30
{
31
public
:
32
DistanceMeasureControl
();
33
~DistanceMeasureControl
() {};
34
35
36
/**
37
* @brief Sets first or second click measurement positions
38
*/
39
bool
LeftMouseDoubleClicked(
int
x,
int
y,
int
m);
40
41
/**
42
* @brief Sets intermediate coords
43
*/
44
bool
MouseMoved(
int
x,
int
y);
45
46
/**
47
* @brief Activate or deactivate distance measurement
48
* @param [in] bool on, activates or deactivates distance measurement
49
*/
50
void
SetDistanceMeasure(
bool
on);
51
52
/**
53
* @brief Return if the measurement mode is activated
54
*/
55
bool
GetDistanceMeasure();
56
57
/**
58
* @brief overloaded method from SceneBase. Here the line in 3D is drawn.
59
*/
60
virtual
void
Draw();
61
62
protected
:
63
bool
bDistMeasureActivated_
;
64
unsigned
dNumClick_
;
65
BIAS::HomgPoint3D
firstHomgPoint_,
secondHomgPoint_
;
66
int
x_,
y_
;
67
bool
bIsInitialized_
;
68
69
#ifdef BIAS_HAVE_FONTGL
70
BIAS::DrawTextGL
drawer_
;
71
#endif
72
73
};
74
}
//end of namespace
75
#endif //__TrackballControl_HH__
BIAS::DistanceMeasureControl::dNumClick_
unsigned dNumClick_
Definition:
DistanceMeasureControl.hh:64
BIAS::DistanceMeasureControl
class for distance measurements in 3d model, derives from TrackballControl and SceneBase ...
Definition:
DistanceMeasureControl.hh:29
BIAS::DistanceMeasureControl::bDistMeasureActivated_
bool bDistMeasureActivated_
Definition:
DistanceMeasureControl.hh:63
BIAS::DistanceMeasureControl::drawer_
BIAS::DrawTextGL drawer_
Definition:
DistanceMeasureControl.hh:70
BIAS::DistanceMeasureControl::y_
int y_
Definition:
DistanceMeasureControl.hh:66
BIAS::HomgPoint3D
class HomgPoint3D describes a point with 3 degrees of freedom in projective coordinates.
Definition:
HomgPoint3D.hh:61
BIAS::DistanceMeasureControl::bIsInitialized_
bool bIsInitialized_
Definition:
DistanceMeasureControl.hh:67
BIAS::SceneBase
Base class for all scenes.
Definition:
SceneBase.hh:68
BIAS::DistanceMeasureControl::~DistanceMeasureControl
~DistanceMeasureControl()
Definition:
DistanceMeasureControl.hh:33
BIAS::DistanceMeasureControl::secondHomgPoint_
BIAS::HomgPoint3D secondHomgPoint_
Definition:
DistanceMeasureControl.hh:65
BIAS::TrackballControl
class for camera movement in trackball mode.
Definition:
TrackballControl.hh:20
BIAS::DrawTextGL
Draw text to OpenGL as 2D bitmap font.
Definition:
DrawTextGL.hh:71
Generated on Tue Feb 6 2018 02:01:37 for Basic Image AlgorithmS Library by
1.8.5