17#ifndef __albaInteractorGenericMouse_h
18#define __albaInteractorGenericMouse_h
88 { this->m_ResultMatrixConcatenationSemantic = POSTMULTIPLY; }
90 { this->m_ResultMatrixConcatenationSemantic = POSTMULTIPLY; }
92 {
return this->m_ResultMatrixConcatenationSemantic; }
121 void Rotate(
double *p1,
double *p2,
double *viewup);
124 void Scale(
double *p1,
double *p2,
double *viewup);
140 int BinarySearch(
double pos, vtkDoubleArray *array,
int& helper_point_status);
205 int m_MousePointer2DPosition[2];
206 int m_LastMousePointer2DPosition[2];
210 double m_LastPickPosition[3];
214 double m_ButtonDownPickPosition[3];
228 double m_ProjectionAccumulator;
238 void SendTransformMatrix(
double *versor,
double translation,
int mouseAction =
MOUSE_MOVE);
239 void SendTransformMatrix(
double *vector,
int mouseAction =
MOUSE_MOVE);
243 void ConcatenateToResultMatrix(
const albaMatrix &matrix);
245 bool m_ResultMatrixConcatenation;
Abstract class for general purpose interactor.
Constrained interaction with mouse device.
void ResultMatrixConcatenationOff()
albaMatrix * m_ConstrainRefSys
virtual void SetCurrentCamera(vtkCamera *camera)
Set the current camera.
void EnableTranslationInternal(bool enable)
Superclass override; only one flag can be true.
void OnButtonDownAction(int X, int Y)
Action to be performed on button down event.
void SetResultMatrixConcatenationSemanticToPreMultiply()
virtual void TrackballRoll()
vtkCamera * m_CurrentCamera
Stores camera to which the interaction is currently assigned.
void SetResultMatrixConcatenationSemanticToPostMultiply()
Set the semantic of the concatenation, default is postmultiply ie the transform is concatenated after...
void EnableRotationInternal(bool enable)
void Translate(double *p1, double *p2)
Perform translation.
bool m_ButtonDownPickSet
True if the button down picking has been set by the caller.
void SetResultMatrixConcatenation(bool active)
Set/Get if the concatenation is active.
virtual void TrackballTranslate()
int BinarySearch(double pos, vtkDoubleArray *array, int &helper_point_status)
Binary search for pos into array.
void SetButtonDownPick(bool picked, double pickedPos[3])
Set the picking already performed by the caller at the button down position: the next OnButtonDownAct...
void Rotate(double *p1, double *p2, double *viewup)
Perform rotation.
bool m_ButtonDownPicked
Result of the picking set by the caller.
void OnMouseMoveAction(int X, int Y)
Action to be performed on mouse move event.
albaTypeMacro(albaInteractorGenericMouse, albaInteractor)
bool GetResultMatrixConcatenation()
void EnableUniformScalingInternal(bool enable)
void EnableScalingInternal(bool enable)
virtual void TrackballRotate()
albaInteractorGenericMouse()
void SendTransformMatrix(const albaMatrix &matrix, int mouseAction=MOUSE_MOVE, double rotationAngle=0)
MouseAction
Used to notify the listener about the current mouse action performed; event Id field is set with this...
void Scale(double *p1, double *p2, double *viewup)
Perform scaling.
void ResultMatrixConcatenationOn()
Enable/Disable the concatenation of the transform matrix to be sent to the result matrix
int m_ResultMatrixConcatenationSemantic
albaMatrix * m_ResultMatrix
int GetResultMatrixConcatenationSemantic()
void OnButtonUpAction()
Action to be performed on button up action.
~albaInteractorGenericMouse()
Abstract class for ALBA interactors This class provides base interface and features of ALBA continuou...
albaMatrix - Time stamped 4x4 Matrix.