ALBA
Public Types | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Friends | List of all members
albaGizmoTranslateAxis Class Reference

#include <albaGizmoTranslateAxis.h>

Inheritance diagram for albaGizmoTranslateAxis:
Inheritance graph
[legend]
Collaboration diagram for albaGizmoTranslateAxis:
Collaboration graph
[legend]

Public Types

enum  AXIS { X = 0 , Y , Z }
 
- Public Types inherited from albaGizmoInterface
enum  MODALITY { G_LOCAL = 0 , G_GLOBAL }
 

Public Member Functions

 albaGizmoTranslateAxis (albaVME *input, albaObserver *listener=NULL, albaString name="")
 
virtual ~albaGizmoTranslateAxis ()
 
void SetInput (albaVME *vme)
 
albaVMEGetInput ()
 
void SetListener (albaObserver *Listener)
 
virtual void OnEvent (albaEventBase *alba_event)
 
void SetAxis (int axis)
 
int GetAxis ()
 
void Highlight (bool highlight)
 
void Show (bool show)
 
void SetConeLength (double length)
 
double GetConeLength ()
 
void SetCylinderLength (double length)
 
double GetCylinderLength ()
 
void SetAbsPose (albaMatrix *absPose)
 
albaMatrixGetAbsPose ()
 
void SetConstraintModality (int axis, int constrainModality)
 
void SetStep (int axis, double step)
 
- Public Member Functions inherited from albaGizmoInterface
void SetName (albaString name)
 
albaString GetName ()
 
virtual void SetInput (albaVME *vme)
 
albaVMEGetInput ()
 
void SetMediator (albaObserver *mediator)
 
albaObserverGetMediator ()
 
void SetAutoscale (bool autoscale)
 
bool GetAutoscale ()
 
void SetRenderWindowHeightPercentage (double percentage)
 
double GetRenderWindowHeightPercentage ()
 
void SetAlwaysVisible (bool alwaysVisible)
 
bool GetAlwaysVisible ()
 
void SetListener (albaObserver *listener)
 
albaObserverGetListener ()
 
virtual void OnEvent (albaEventBase *alba_event)
 
virtual void Show (bool show)
 
void SetModalityToLocal ()
 
void SetModalityToGlobal ()
 
int GetModality ()
 
virtual void SetAbsPose (albaMatrix *absPose)
 
virtual albaMatrixGetAbsPose ()
 
virtual albaGUIGetGui ()
 
- Public Member Functions inherited from albaObserver
 albaObserver ()
 
virtual ~albaObserver ()
 
virtual void OnEvent (albaEventBase *e)=0
 

Protected Types

enum  GIZMOPARTS { CYLINDER = 0 , CONE }
 

Protected Member Functions

void SetRefSysMatrix (albaMatrix *constrain)
 
void CreatePipeline ()
 
void CreateISA ()
 
void SetColor (int part, double col[3])
 
void SetColor (int part, double colR, double colG, double colB)
 
void SetColor (double cylCol[3], double coneCol[3])
 
void SetColor (double cylR, double cylG, double cylB, double coneR, double coneG, double coneB)
 
- Protected Member Functions inherited from albaGizmoInterface
 albaGizmoInterface ()
 
virtual ~albaGizmoInterface ()
 
void SendTransformMatrix (albaMatrix *matrix, int eventId, long arg)
 
virtual void OnEventGizmoGui (albaEventBase *alba_event)
 
virtual void OnEventGizmoComponents (albaEventBase *alba_event)
 

Protected Attributes

albaVMEGizmo * m_ConeGizmo
 
albaVMEGizmo * m_CylGizmo
 
albaVMEm_InputVme
 
int m_Axis
 
vtkConeSource * m_Cone
 
double m_ConeLength
 
vtkCylinderSource * m_Cylinder
 
double m_CylinderLength
 
vtkTransformPolyDataFilter * m_TranslatePDF [2]
 
vtkTransform * m_TranslateTr [2]
 
vtkTransformPolyDataFilter * m_RotatePDF [2]
 
vtkTransform * m_RotationTr
 
albaInteractorCompositorMousem_IsaComp [2]
 
albaInteractorGenericMousem_IsaGen [2]
 
albaObserverm_Listener
 
- Protected Attributes inherited from albaGizmoInterface
albaObserverm_Mediator
 
albaString m_Name
 
albaVMEm_InputVME
 
int m_Modality
 
albaObserverm_Listener
 
albaVMEm_RefSysVME
 
bool m_Visibility
 
double m_RenderWindowHeightPercentage
 
bool m_AlwaysVisible
 
bool m_Autoscale
 

Friends

class albaGizmoTranslateAxisTest
 

Detailed Description

Basic gizmo component used to perform constrained translation on one axis.

See also
albaGizmoTranslate

Definition at line 43 of file albaGizmoTranslateAxis.h.

Member Enumeration Documentation

◆ AXIS

Axis enum.

Enumerator

Definition at line 69 of file albaGizmoTranslateAxis.h.

◆ GIZMOPARTS

Enumerator
CYLINDER 
CONE 

Definition at line 128 of file albaGizmoTranslateAxis.h.

Constructor & Destructor Documentation

◆ albaGizmoTranslateAxis()

albaGizmoTranslateAxis::albaGizmoTranslateAxis ( albaVME input,
albaObserver listener = NULL,
albaString  name = "" 
)

◆ ~albaGizmoTranslateAxis()

virtual albaGizmoTranslateAxis::~albaGizmoTranslateAxis ( )
virtual

Member Function Documentation

◆ SetInput()

void albaGizmoTranslateAxis::SetInput ( albaVME vme)
virtual

Set the gizmo generating vme; the gizmo will be centered on this vme.

Reimplemented from albaGizmoInterface.

◆ GetInput()

albaVME * albaGizmoTranslateAxis::GetInput ( )
inline

Definition at line 52 of file albaGizmoTranslateAxis.h.

◆ SetListener()

void albaGizmoTranslateAxis::SetListener ( albaObserver Listener)
inline

Set the event receiver object.

Definition at line 59 of file albaGizmoTranslateAxis.h.

◆ OnEvent()

virtual void albaGizmoTranslateAxis::OnEvent ( albaEventBase alba_event)
virtual

Events handling.

Reimplemented from albaGizmoInterface.

◆ SetAxis()

void albaGizmoTranslateAxis::SetAxis ( int  axis)

Set/Get gizmo axis, default axis is X.

◆ GetAxis()

int albaGizmoTranslateAxis::GetAxis ( )
inline

Definition at line 73 of file albaGizmoTranslateAxis.h.

◆ Highlight()

void albaGizmoTranslateAxis::Highlight ( bool  highlight)

Highlight the gizmo.

◆ Show()

void albaGizmoTranslateAxis::Show ( bool  show)
virtual

Show the gizmo.

Reimplemented from albaGizmoInterface.

◆ SetConeLength()

void albaGizmoTranslateAxis::SetConeLength ( double  length)

Set/Get the length of the cone.

◆ GetConeLength()

double albaGizmoTranslateAxis::GetConeLength ( )
inline

Definition at line 91 of file albaGizmoTranslateAxis.h.

◆ SetCylinderLength()

void albaGizmoTranslateAxis::SetCylinderLength ( double  length)

Set/Get the length of the cylinder.

◆ GetCylinderLength()

double albaGizmoTranslateAxis::GetCylinderLength ( )
inline

Definition at line 99 of file albaGizmoTranslateAxis.h.

◆ SetAbsPose()

void albaGizmoTranslateAxis::SetAbsPose ( albaMatrix absPose)
virtual

Set the abs pose.

Reimplemented from albaGizmoInterface.

◆ GetAbsPose()

albaMatrix * albaGizmoTranslateAxis::GetAbsPose ( )
virtual

Get the gizmo abs pose.

Reimplemented from albaGizmoInterface.

◆ SetConstraintModality()

void albaGizmoTranslateAxis::SetConstraintModality ( int  axis,
int  constrainModality 
)

Set the constraint modality for the given axis; allowed constraint modality are: LOCK, FREE, BOUNDS, SNAP_STEP, SNAP_ARRAY.

◆ SetStep()

void albaGizmoTranslateAxis::SetStep ( int  axis,
double  step 
)

Set the step value for snap step constraint type for the given axis.

◆ SetRefSysMatrix()

void albaGizmoTranslateAxis::SetRefSysMatrix ( albaMatrix constrain)
protected

Set the constrain ref sys.

◆ CreatePipeline()

void albaGizmoTranslateAxis::CreatePipeline ( )
protected

Create vtk objects needed.

◆ CreateISA()

void albaGizmoTranslateAxis::CreateISA ( )
protected

Create isa stuff.

◆ SetColor() [1/4]

void albaGizmoTranslateAxis::SetColor ( int  part,
double  col[3] 
)
protected

Gizmo color setting facilities; part can be CYLINDER or CONE.

◆ SetColor() [2/4]

void albaGizmoTranslateAxis::SetColor ( int  part,
double  colR,
double  colG,
double  colB 
)
protected

◆ SetColor() [3/4]

void albaGizmoTranslateAxis::SetColor ( double  cylCol[3],
double  coneCol[3] 
)
protected

◆ SetColor() [4/4]

void albaGizmoTranslateAxis::SetColor ( double  cylR,
double  cylG,
double  cylB,
double  coneR,
double  coneG,
double  coneB 
)
protected

Friends And Related Function Documentation

◆ albaGizmoTranslateAxisTest

friend class albaGizmoTranslateAxisTest
friend

test friend

Definition at line 183 of file albaGizmoTranslateAxis.h.

Member Data Documentation

◆ m_ConeGizmo

albaVMEGizmo* albaGizmoTranslateAxis::m_ConeGizmo
protected

Cone gizmo.

Definition at line 120 of file albaGizmoTranslateAxis.h.

◆ m_CylGizmo

albaVMEGizmo* albaGizmoTranslateAxis::m_CylGizmo
protected

cylinder gizmo

Definition at line 123 of file albaGizmoTranslateAxis.h.

◆ m_InputVme

albaVME* albaGizmoTranslateAxis::m_InputVme
protected

Register input vme.

Definition at line 126 of file albaGizmoTranslateAxis.h.

◆ m_Axis

int albaGizmoTranslateAxis::m_Axis
protected

Register the gizmo axis.

Definition at line 131 of file albaGizmoTranslateAxis.h.

◆ m_Cone

vtkConeSource* albaGizmoTranslateAxis::m_Cone
protected

Cone source.

Definition at line 134 of file albaGizmoTranslateAxis.h.

◆ m_ConeLength

double albaGizmoTranslateAxis::m_ConeLength
protected

Cone length.

Definition at line 137 of file albaGizmoTranslateAxis.h.

◆ m_Cylinder

vtkCylinderSource* albaGizmoTranslateAxis::m_Cylinder
protected

Cylinder source.

Definition at line 140 of file albaGizmoTranslateAxis.h.

◆ m_CylinderLength

double albaGizmoTranslateAxis::m_CylinderLength
protected

Cylinder length.

Definition at line 143 of file albaGizmoTranslateAxis.h.

◆ m_TranslatePDF

vtkTransformPolyDataFilter* albaGizmoTranslateAxis::m_TranslatePDF[2]
protected

Cylinder and cone gizmo vme data.

translate PDF for cylinder and cone

Definition at line 149 of file albaGizmoTranslateAxis.h.

◆ m_TranslateTr

vtkTransform* albaGizmoTranslateAxis::m_TranslateTr[2]
protected

translation transform for cylinder and cone

Definition at line 152 of file albaGizmoTranslateAxis.h.

◆ m_RotatePDF

vtkTransformPolyDataFilter* albaGizmoTranslateAxis::m_RotatePDF[2]
protected

rotate PDF for cylinder and cone

Definition at line 155 of file albaGizmoTranslateAxis.h.

◆ m_RotationTr

vtkTransform* albaGizmoTranslateAxis::m_RotationTr
protected

rotation transform for cylinder and cone

Definition at line 158 of file albaGizmoTranslateAxis.h.

◆ m_IsaComp

albaInteractorCompositorMouse* albaGizmoTranslateAxis::m_IsaComp[2]
protected

isa compositor

Definition at line 167 of file albaGizmoTranslateAxis.h.

◆ m_IsaGen

albaInteractorGenericMouse* albaGizmoTranslateAxis::m_IsaGen[2]
protected

isa generic

Definition at line 170 of file albaGizmoTranslateAxis.h.

◆ m_Listener

albaObserver* albaGizmoTranslateAxis::m_Listener
protected

Register the event receiver object.

Definition at line 180 of file albaGizmoTranslateAxis.h.


The documentation for this class was generated from the following file: