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

#include <albaGizmoTranslatePlane.h>

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

Public Types

enum  PLANE { YZ = 0 , XZ , XY }
 
- Public Types inherited from albaGizmoInterface
enum  MODALITY { G_LOCAL = 0 , G_GLOBAL }
 

Public Member Functions

 albaGizmoTranslatePlane (albaVME *input, albaObserver *listener=NULL)
 
virtual ~albaGizmoTranslatePlane ()
 
void SetInput (albaVME *vme)
 
albaVME * GetInput ()
 
void SetListener (albaObserver *Listener)
 
virtual void OnEvent (albaEventBase *alba_event)
 
void SetPlane (int axis)
 
int GetPlane ()
 
void Highlight (bool highlight)
 
void Show (bool show)
 
void SetSizeLength (double length)
 
double GetSizeLength ()
 
void SetIsActive (bool highlight)
 
bool GetIsActive ()
 
void SetAbsPose (albaMatrix *absPose)
 
albaMatrix * GetAbsPose ()
 
void SetConstrainRefSys (albaMatrix *constrain)
 
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)
 
albaVME * GetInput ()
 
void SetMediator (albaObserver *mediator)
 
albaObserver * GetMediator ()
 
void SetAutoscale (bool autoscale)
 
bool GetAutoscale ()
 
void SetRenderWindowHeightPercentage (double percentage)
 
double GetRenderWindowHeightPercentage ()
 
void SetAlwaysVisible (bool alwaysVisible)
 
bool GetAlwaysVisible ()
 
void SetListener (albaObserver *listener)
 
albaObserver * GetListener ()
 
virtual void OnEvent (albaEventBase *alba_event)
 
virtual void Show (bool show)
 
void SetModalityToLocal ()
 
void SetModalityToGlobal ()
 
int GetModality ()
 
virtual void SetAbsPose (albaMatrix *absPose)
 
virtual albaMatrix * GetAbsPose ()
 
virtual albaGUI * GetGui ()
 
- Public Member Functions inherited from albaObserver
 albaObserver ()
 
virtual ~albaObserver ()
 
virtual void OnEvent (albaEventBase *e)=0
 

Protected Types

enum  GIZMOPARTS { S1 = 0 , S2 , SQ }
 
enum  GIZMO_STATUS { SELECTED = 0 , NOT_SELECTED }
 

Protected Member Functions

void CreatePipeline ()
 
void CreateISA ()
 
void SetColor (int part, double col[3])
 
void SetColor (int part, double colR, double colG, double colB)
 
void ShowSquare (bool show)
 
- 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_Gizmo [3]
 
albaVME * m_InputVme
 
int m_ActivePlane
 
double m_Length
 
vtkLineSource * m_Line [2]
 
vtkTubeFilter * m_LineTF [2]
 
vtkPlaneSource * m_Plane
 
vtkTransformPolyDataFilter * m_RotatePDF [3]
 
vtkTransform * m_RotationTr
 
albaBehaviorTransform * m_IsaGen [2]
 
vtkTransform * m_PivotTransform
 
albaObserver * m_Listener
 
bool m_IsActive
 
- Protected Attributes inherited from albaGizmoInterface
albaObserver * m_Mediator
 
albaString m_Name
 
albaVME * m_InputVME
 
int m_Modality
 
albaObserver * m_Listener
 
albaVME * m_RefSysVME
 
bool m_Visibility
 
double m_RenderWindowHeightPercentage
 
bool m_AlwaysVisible
 
bool m_Autoscale
 

Friends

class albaGizmoTranslatePlaneTest
 

Detailed Description

Basic gizmo component used to perform constrained translation on a plane.

See also
albaGizmoTranslate

Definition at line 44 of file albaGizmoTranslatePlane.h.

Member Enumeration Documentation

◆ PLANE

Plane enum.

Enumerator
YZ 
XZ 
XY 

Definition at line 70 of file albaGizmoTranslatePlane.h.

◆ GIZMOPARTS

z z y ^ ^ ^

----—> y ----—>x ----—> x

YZ XZ XY

z ^ S2 |--— | |
| SQ |S1
| |
-----—> y

Enumerator
S1 
S2 
SQ 

Definition at line 151 of file albaGizmoTranslatePlane.h.

◆ GIZMO_STATUS

Enumerator
SELECTED 
NOT_SELECTED 

Definition at line 152 of file albaGizmoTranslatePlane.h.

Constructor & Destructor Documentation

◆ albaGizmoTranslatePlane()

albaGizmoTranslatePlane::albaGizmoTranslatePlane ( albaVME *  input,
albaObserver *  listener = NULL 
)

◆ ~albaGizmoTranslatePlane()

virtual albaGizmoTranslatePlane::~albaGizmoTranslatePlane ( )
virtual

Member Function Documentation

◆ SetInput()

void albaGizmoTranslatePlane::SetInput ( albaVME *  vme)
virtual

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

Reimplemented from albaGizmoInterface.

◆ GetInput()

albaVME * albaGizmoTranslatePlane::GetInput ( )
inline

Definition at line 53 of file albaGizmoTranslatePlane.h.

◆ SetListener()

void albaGizmoTranslatePlane::SetListener ( albaObserver *  Listener)
inline

Set the event receiver object.

Definition at line 60 of file albaGizmoTranslatePlane.h.

◆ OnEvent()

virtual void albaGizmoTranslatePlane::OnEvent ( albaEventBase *  alba_event)
virtual

Events handling.

Reimplemented from albaGizmoInterface.

◆ SetPlane()

void albaGizmoTranslatePlane::SetPlane ( int  axis)

Set/Get gizmo plane, default plane is YZ.

◆ GetPlane()

int albaGizmoTranslatePlane::GetPlane ( )
inline

Get gizmo Plane.

Definition at line 76 of file albaGizmoTranslatePlane.h.

◆ Highlight()

void albaGizmoTranslatePlane::Highlight ( bool  highlight)

Highlight gizmo.

◆ Show()

void albaGizmoTranslatePlane::Show ( bool  show)
virtual

Show gizmo.

Reimplemented from albaGizmoInterface.

◆ SetSizeLength()

void albaGizmoTranslatePlane::SetSizeLength ( double  length)

Set/Get the side length of the gizmo.

◆ GetSizeLength()

double albaGizmoTranslatePlane::GetSizeLength ( )
inline

Definition at line 95 of file albaGizmoTranslatePlane.h.

◆ SetIsActive()

void albaGizmoTranslatePlane::SetIsActive ( bool  highlight)
inline

Set/Get the activation status of the gizmo, When the gizmo is active it is sending pose matrices to the listener.

Definition at line 104 of file albaGizmoTranslatePlane.h.

◆ GetIsActive()

bool albaGizmoTranslatePlane::GetIsActive ( )
inline

Definition at line 105 of file albaGizmoTranslatePlane.h.

◆ SetAbsPose()

void albaGizmoTranslatePlane::SetAbsPose ( albaMatrix *  absPose)
virtual

Set the abs pose.

Reimplemented from albaGizmoInterface.

◆ GetAbsPose()

albaMatrix * albaGizmoTranslatePlane::GetAbsPose ( )
virtual

Get the gizmo abs pose.

Reimplemented from albaGizmoInterface.

◆ SetConstrainRefSys()

void albaGizmoTranslatePlane::SetConstrainRefSys ( albaMatrix *  constrain)

Set the constrain ref sys.

◆ SetConstraintModality()

void albaGizmoTranslatePlane::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 albaGizmoTranslatePlane::SetStep ( int  axis,
double  step 
)

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

◆ CreatePipeline()

void albaGizmoTranslatePlane::CreatePipeline ( )
protected

Create vtk objects needed.

◆ CreateISA()

void albaGizmoTranslatePlane::CreateISA ( )
protected

Create isa stuff.

◆ SetColor() [1/2]

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

Gizmo color setting facilities for gizmo segments;.

◆ SetColor() [2/2]

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

◆ ShowSquare()

void albaGizmoTranslatePlane::ShowSquare ( bool  show)
protected

Hide/show the square.

Friends And Related Function Documentation

◆ albaGizmoTranslatePlaneTest

friend class albaGizmoTranslatePlaneTest
friend

Definition at line 204 of file albaGizmoTranslatePlane.h.

Member Data Documentation

◆ m_Gizmo

albaVMEGizmo* albaGizmoTranslatePlane::m_Gizmo[3]
protected

Segments gizmo.

Definition at line 126 of file albaGizmoTranslatePlane.h.

◆ m_InputVme

albaVME* albaGizmoTranslatePlane::m_InputVme
protected

Register input vme.

Definition at line 129 of file albaGizmoTranslatePlane.h.

◆ m_ActivePlane

int albaGizmoTranslatePlane::m_ActivePlane
protected

Register the gizmo plane.

Definition at line 155 of file albaGizmoTranslatePlane.h.

◆ m_Length

double albaGizmoTranslatePlane::m_Length
protected

Register the gizmo square plane side length.

Definition at line 158 of file albaGizmoTranslatePlane.h.

◆ m_Line

vtkLineSource* albaGizmoTranslatePlane::m_Line[2]
protected

Line source.

Definition at line 161 of file albaGizmoTranslatePlane.h.

◆ m_LineTF

vtkTubeFilter* albaGizmoTranslatePlane::m_LineTF[2]
protected

Tube filter for lines.

Definition at line 164 of file albaGizmoTranslatePlane.h.

◆ m_Plane

vtkPlaneSource* albaGizmoTranslatePlane::m_Plane
protected

Plane source.

Definition at line 167 of file albaGizmoTranslatePlane.h.

◆ m_RotatePDF

vtkTransformPolyDataFilter* albaGizmoTranslatePlane::m_RotatePDF[3]
protected

S1, S2 and SQ gizmo data.

rotate PDF for gizmo parts

Definition at line 173 of file albaGizmoTranslatePlane.h.

◆ m_RotationTr

vtkTransform* albaGizmoTranslatePlane::m_RotationTr
protected

rotation transform for cylinder and cone

Definition at line 176 of file albaGizmoTranslatePlane.h.

◆ m_IsaGen

albaBehaviorTransform* albaGizmoTranslatePlane::m_IsaGen[2]
protected

isa generic

Definition at line 186 of file albaGizmoTranslatePlane.h.

◆ m_PivotTransform

vtkTransform* albaGizmoTranslatePlane::m_PivotTransform
protected

Used by albaBehaviorTransform.

Definition at line 189 of file albaGizmoTranslatePlane.h.

◆ m_Listener

albaObserver* albaGizmoTranslatePlane::m_Listener
protected

Register the event receiver object.

Definition at line 196 of file albaGizmoTranslatePlane.h.

◆ m_IsActive

bool albaGizmoTranslatePlane::m_IsActive
protected

Register Gizmo status.

Definition at line 202 of file albaGizmoTranslatePlane.h.


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