ALBA
albaGizmoCrossRotate.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: ALBA (Agile Library for Biomedical Applications)
4 Module: albaGizmoCrossRotate
5 Authors: Stefano Perticoni
6
7 Copyright (c) BIC
8 All rights reserved. See Copyright.txt or
9
10
11 This software is distributed WITHOUT ANY WARRANTY; without even
12 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
13 PURPOSE. See the above copyright notice for more information.
14
15=========================================================================*/
16
17
18//======================== WORK IN PROGRESS !!!!! ========================
19//======================== WORK IN PROGRESS !!!!! ========================
20//======================== WORK IN PROGRESS !!!!! ========================
21//======================== WORK IN PROGRESS !!!!! ========================
22//======================== WORK IN PROGRESS !!!!! ========================
23//======================== WORK IN PROGRESS !!!!! ========================
24//======================== WORK IN PROGRESS !!!!! ========================
25//======================== WORK IN PROGRESS !!!!! ========================
26//======================== WORK IN PROGRESS !!!!! ========================
27
28
29#ifndef __albaGizmoCrossRotate_H__
30#define __albaGizmoCrossRotate_H__
31
32//----------------------------------------------------------------------------
33// Include:
34//----------------------------------------------------------------------------
35#include "albaEvent.h"
36#include "albaGizmoInterface.h"
37#include "albaGUIGizmoRotate.h"
38
39//----------------------------------------------------------------------------
40// forward references :
41//----------------------------------------------------------------------------
45class albaMatrix;
46
47//----------------------------------------------------------------------------
54{
55public:
56 albaGizmoCrossRotate(albaVME *input, albaObserver* listener = NULL, bool buildGUI = true, int axis = X);
58
61 void SetInput(albaVME *vme);
62
64 void SetRenderWindowHeightPercentage(double percentage);
65
67 void SetAutoscale(bool autoscale);
68
70 void SetAlwaysVisible(bool alwaysVisible);
71
72 //----------------------------------------------------------------------------
73 // events handling
74 //----------------------------------------------------------------------------
75
78 void OnEvent(albaEventBase *alba_event);
79
80 //----------------------------------------------------------------------------
81 // show
82 //----------------------------------------------------------------------------
83
86 void Show(bool show);
87
88 //----------------------------------------------------------------------------
89
92 void SetAbsPose(albaMatrix *absPose, bool applyPoseToFans = true);
94
98
99 //----------------------------------------------------------------------------
100 // RefSys
101 //----------------------------------------------------------------------------
102
104 void SetRefSys(albaVME *refSys);
106
108
110 void SetCircleFanRadius(double radius);
112
115
116protected:
118
121
124
127
130 enum AXIS {X = 0, Y, Z};
131
133
136 void Highlight(bool highlight);
137
141
144
147
148
150
151};
152#endif
Implementation of the message object for the Subject/Observer design pattern.
Definition: albaEventBase.h:49
albaGUI * GetGui()
Return the gui to be plugged.
gui class for rotation gizmo
albaGUI is a panel with function to easily create GUI.
Definition: albaGUI.h:110
Basic gizmo component used to perform constrained rotation around an axis.
Basic gizmo component used to give rotation angle feedback.
Gizmo used to perform constrained rotation around an axis.
void SendTransformMatrixFromGui(albaEventBase *alba_event)
Send matrix to postmultiply to listener.
albaVME * GetRefSys()
albaGizmoCrossRotateAxis * m_GizmoCrossRotateAxisEW
albaGizmoCrossRotateAxis * GetGizmoCrossRotateAxisNS()
void Show(bool show)
Show the gizmo.
double GetCircleFanRadius()
void OnEvent(albaEventBase *alba_event)
Events handling.
albaInteractorGenericInterface * GetInteractor(int axis)
Get the Interactor asscociated to each axis.
void SetAbsPose(albaMatrix *absPose, bool applyPoseToFans=true)
Set the gizmo pose.
albaGizmoCrossRotateAxis * GetGizmoCrossRotateAxisEW()
void SetInput(albaVME *vme)
Set input vme for the gizmo.
void SetRefSys(albaVME *refSys)
Set the vme to be used as reference system, the vme is referenced; default ref sys is vme abs matrix.
void SetAlwaysVisible(bool alwaysVisible)
Superclass override.
albaMatrix * GetAbsPose()
Get the gizmo abs pose.
void OnEventGizmoComponents(albaEventBase *alba_event)
Gizmo components events handling.
void Highlight(bool highlight)
Highlight one component and dehighlight other components.
void SetAutoscale(bool autoscale)
Superclass override.
albaGUI * GetGui()
Return gui owned by the gizmo.
albaGizmoCrossRotateAxis * m_GizmoCrossRotateAxisNS
Array holding the three gizmo that performs rotation.
albaGizmoCrossRotateFan * m_GizmoCrossRotateFan
The rotating fan gizmo.
void SetRenderWindowHeightPercentage(double percentage)
Superclass override.
virtual ~albaGizmoCrossRotate()
void SetCircleFanRadius(double radius)
Modify radius of circles.
albaGUIGizmoRotate * m_GuiGizmoRotate
AXIS
gizmo components enum
bool m_BuildGUI
Build Gizmo GUI.
void OnEventGizmoGui(albaEventBase *alba_event)
Gizmo components events handling.
albaGizmoCrossRotate(albaVME *input, albaObserver *listener=NULL, bool buildGUI=true, int axis=X)
Base class for operations and views gizmos.
Abstract class for general purpose interactor.
albaMatrix - Time stamped 4x4 Matrix.
Definition: albaMatrix.h:44
Interface implementing the Observer of the Subject/Observer design pattern.
Definition: albaObserver.h:36
albaVME -
Definition: albaVME.h:150