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

#include <albaInteractor2DMeasure.h>

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

Classes

struct  Measure2D
 

Public Types

enum  MEASURE_INTERACTIONS {
  ID_MEASURE_STARTED = MINID , ID_MEASURE_FINISHED , ID_MEASURE_ADDED , ID_MEASURE_CHANGED ,
  ID_MEASURE_MOVED , ID_MEASURE_SELECTED , ID_MEASURE_RCLICK
}
 
enum  MEASURE_ACTIONS { ACTION_NONE = 0 , ACTION_ADD_MEASURE , ACTION_EDIT_MEASURE , ACTION_MOVE_MEASURE }
 
enum  LINE_POINT {
  NO_POINT = 0 , POINT_1 , POINT_2 , POINT_3 ,
  POINT_4
}
 
- Public Types inherited from albaInteractorPER
enum  modalities { SINGLE_BUTTON =0 , MULTI_BUTTON }
 
- Public Types inherited from albaInteractor
enum  modalities { SINGLE_BUTTON_MODE =0 , MULTI_BUTTON_MODE }
 

Public Member Functions

 albaTypeMacro (albaInteractor2DMeasure, albaInteractorPER)
 
virtual void OnEvent (albaEventBase *event)
 
virtual void AddMeasure (double *point1, double *point2=NULL)
 
virtual void RemoveMeasure (int index)
 
virtual void RemoveAllMeasures ()
 
virtual void SelectMeasure (int index)
 
virtual void ActivateMeasure (int index=-1, bool activate=true)
 
void Enable (bool enable=true)
 
void EnableAddMeasure (bool move=true)
 
void EnableEditMeasure (bool edit=true)
 
void EnableMoveMeasure (bool move=true)
 
virtual void Update (int index=-1)
 
virtual bool Load (albaVME *input, wxString tag)
 
virtual bool Save (albaVME *input, wxString tag)
 
double GetMeasureValue (int index)
 
albaString GetMeasureText (int index)
 
albaString GetMeasureLabel (int index)
 
albaString GetMeasureType ()
 
int GetMaxMeasures ()
 
int GetMeasureCount ()
 
int GetLastEditedMeasureIndex ()
 
int GetSelectedMeasureIndex ()
 
bool IsEnabled ()
 
double GetPointSize ()
 
double GetLineWidth ()
 
void SetMaxMeasures (int maxMeasures)
 
void SetMeasureLabel (int index, albaString text)
 
void SetColorDefault (double r, double g, double b, double a=1.0)
 
void SetColorSelection (double r, double g, double b, double a=1.0)
 
void SetColorEdit (double r, double g, double b, double a=1.0)
 
void SetColorDisable (double r, double g, double b, double a=1.0)
 
void SetColorText (double r, double g, double b, double a=1.0)
 
virtual void SetPointSize (double size)
 
virtual void SetLineWidth (double width)
 
virtual void Show (bool show)
 
void ShowText (bool show)
 
void ShowText (int measure, bool show)
 
void SetRendererByView (albaView *view)
 
void Render ()
 
int GetCurreasureIdx () const
 
albaRWIBaseGetCurrentRwi ()
 
albaRWIBaseGetCurrentRwi (int m)
 
int GetCurrPlane ()
 
void SetCurrPlane (int plane)
 
virtual void ReDrawAll ()
 
void SetUpdateDistance (double dist)
 
void SetAction (MEASURE_ACTIONS action)
 
- Public Member Functions inherited from albaInteractorPER
 albaTypeMacro (albaInteractorPER, albaInteractor)
 
virtual void EnableSelect (bool enable)
 
virtual void FlyToMode ()
 
bool IsInteracting (albaDevice *device, int button=-1)
 
virtual int StartInteraction (albaDevice *device, int button)
 
virtual int StopInteraction (albaDevice *device, int button)
 
virtual void OnEvent (albaEventBase *event)
 
void OnVmeSelected (albaVME *vme)
 
void SetMode (int mode)
 
int GetMode ()
 
void SetModeToSingleButton ()
 
void SetModeToMultiButton ()
 
albaInteractorGetCameraMouseInteractor ()
 
albaInteractorGetCameraInteractor ()
 
- Public Member Functions inherited from albaInteractor
 albaInteractor ()
 
virtual ~albaInteractor ()
 
 ALBA_ID_DEC (INTERACTION_STARTED)
 
 ALBA_ID_DEC (INTERACTION_STOPPED)
 
 ALBA_ID_DEC (BUTTON_DOWN)
 
 ALBA_ID_DEC (BUTTON_UP)
 
 albaAbstractTypeMacro (albaInteractor, albaAgent)
 
virtual void SetRendererAndView (vtkRenderer *ren, albaView *view)
 
vtkRenderer * GetRenderer ()
 
albaViewGetView ()
 
albaDeviceGetDevice ()
 
virtual void SetDevice (albaDevice *)
 
virtual void SetVME (albaVME *vme)
 
void SetProp (vtkProp3D *prop)
 
void SetIgnoreTriggerEvents (bool flag)
 
int GetIgnoreTriggerEvents (bool flag)
 
void IgnoreTriggerEventsOn ()
 
void IgnoreTriggerEventsOff ()
 
void SetStartInteractionEvent (albaID event)
 
albaID GetStartInteractionEvent ()
 
void SetStopInteractionEvent (albaID event)
 
albaID GetStopInteractionEvent ()
 
void SetStartButton (int btn)
 
int GetStartButton ()
 
void SetModifiers (int mod)
 
int GetModifiers ()
 
int GetCurrentButton ()
 
unsigned long GetCurrentModifier ()
 
virtual int StartInteraction (albaDevice *device)
 
virtual int StopInteraction (albaDevice *device)
 
virtual bool IsInteracting ()
 
virtual bool IsInteracting (albaDevice *device)
 
void SetButtonMode (int mode)
 
int GetButtonMode ()
 
void SetButtonModeToSingleButton ()
 
void SetButtonModeToMultiButton ()
 
virtual void OnEvent (albaEventBase *event)
 
void TestModeOn ()
 
void TestModeOff ()
 
bool GetTestMode ()
 
- Public Member Functions inherited from albaAgent
 albaAbstractTypeMacro (albaAgent, albaReferenceCounted)
 
 ALBA_ID_DEC (AGENT_INITIALIZE)
 
void AddObserver (albaObserver *listener, albaID channel=MCH_UP)
 
void RemoveObserver (albaObserver *listener)
 
void RemoveAllObservers ()
 
virtual void OnEvent (albaEventBase *event)
 
bool HasObservers (albaID channel)
 
void GetObservers (albaID channel, std::vector< albaObserver * > &olist)
 
int Initialize ()
 
void Shutdown ()
 
int IsInitialized ()
 
virtual void SetName (const char *name)
 
const char * GetName ()
 
- Public Member Functions inherited from albaReferenceCounted
 albaReferenceCounted ()
 
virtual ~albaReferenceCounted ()
 
 albaAbstractTypeMacro (albaReferenceCounted, albaObject)
 
virtual void Delete ()
 
void Register (void *obj)
 
virtual void UnRegister (void *obj)
 
int GetReferenceCount ()
 
void SetReferenceCount (int)
 
- Public Member Functions inherited from albaObject
 albaObject ()
 
virtual ~albaObject ()
 
virtual void Delete ()
 
virtual const char * GetTypeName () const
 
virtual bool IsA (const char *type_name) const
 
virtual bool IsA (const albaTypeID &type_id) const
 
virtual albaObjectNewObjectInstance () const =0
 
virtual const albaTypeIDGetTypeId () const
 
virtual void Print (std::ostream &os, const int indent=0) const
 
 albaObject (const albaObject &c)
 
- Public Member Functions inherited from albaObserver
 albaObserver ()
 
virtual ~albaObserver ()
 
virtual void OnEvent (albaEventBase *e)=0
 
- Public Member Functions inherited from albaEventBroadcaster
 albaEventBroadcaster (void *owner=NULL)
 
virtual ~albaEventBroadcaster ()
 
 albaEventBroadcaster (const albaEventBroadcaster &c)
 
void AddObserver (albaObserver *obj)
 
void AddObserver (albaObserver &obj)
 
albaObserverCallbackAddObserverCallback (void(*f)(void *sender, albaID eid, void *clientdata, void *calldata))
 
bool RemoveObserver (albaObserver *obj)
 
void RemoveAllObservers ()
 
bool IsObserver (albaObserver *obj)
 
bool HasObservers ()
 
void GetObservers (std::vector< albaObserver * > &olist)
 
void InvokeEvent (albaEventBase &e)
 
void InvokeEvent (albaEventBase *e)
 
void InvokeEvent (void *sender, albaID id=ID_NO_EVENT, void *data=NULL)
 
void SetChannel (albaID ch)
 
albaID GetChannel ()
 
virtual void SetListener (albaObserver *o)
 
- Public Member Functions inherited from albaEventSender
 albaEventSender ()
 
virtual void SetListener (albaObserver *o)
 
virtual albaObserverGetListener ()
 
virtual bool HasListener ()
 
virtual void InvokeEvent (albaEventBase &e)
 
virtual void InvokeEvent (albaEventBase *e)
 
virtual void InvokeEvent (void *sender, albaID id=ID_NO_EVENT, void *data=NULL)
 

Protected Types

enum  AXIS { X , Y , Z }
 
enum  Colors {
  COLOR_DEFAULT , COLOR_EDIT , COLOR_SELECTION , COLOR_DISABLE ,
  COLOR_TEXT
}
 
- Protected Types inherited from albaEventBroadcaster
typedef std::list< albaObserver * > albaObserversList
 

Protected Member Functions

 albaInteractor2DMeasure ()
 
virtual ~albaInteractor2DMeasure ()
 
void InitRenderer (albaEventInteraction *e)
 
virtual void OnLeftButtonDown (albaEventInteraction *e)
 
virtual void OnLeftButtonUp (albaEventInteraction *e)
 
virtual void OnRightButtonUp (albaEventInteraction *e)
 
virtual void OnMove (albaEventInteraction *e)
 
virtual void DrawNewMeasure (double *wp)
 
virtual void MoveMeasure (int index, double *pointCoord)
 
virtual void EditMeasure (int index, double *point)
 
virtual void FindAndHighlight (double *pointCoord)
 
virtual void UpdateEditActors (double *point1, double *point2=NULL)
 
virtual void UpdatePointActor (double *point)
 
virtual void UpdateTextActor (int index, double *point)
 
virtual void ShowEditLineActors ()
 
virtual void HideEditActors ()
 
void SetColor (vtkActor2D *actor, Color *color)
 
MEASURE_ACTIONS GetAction ()
 
void iSetColor (int color, double r, double g, double b, double a)
 
bool IsInBound (double *pos)
 
void ScreenToWorld (double screen[2], double world[3])
 
double PixelSizeInWorld ()
 
void WorldToScreen (double world[3], double screen[2])
 
vtkPointSource * GetNewPointSource ()
 
double DistanceBetweenPoints (double *point1, double *point2)
 
double DistancePointToLine (double *point, double *lineP1, double *lineP2)
 
void GetMidPoint (double(&midPoint)[3], double *point1, double *point2)
 
bool FindPointOnLine (double(&point)[3], double *linePoint1, double *linePoint2, double distance)
 
double GetAngle (double *point1, double *point2, double *origin)
 
void RotatePoint (double *point, double *origin, double angle)
 
int PointUpDownLine (double *point, double *lp1, double *lp2)
 
void GetParallelLine (double(&point1)[3], double(&point2)[3], double *linePoint1, double *linePoint2, double distance)
 
- Protected Member Functions inherited from albaInteractorPER
 albaInteractorPER ()
 
virtual ~albaInteractorPER ()
 
virtual int OnStartInteraction (albaEventInteraction *e)
 
virtual int OnStopInteraction (albaEventInteraction *e)
 
virtual void OnButtonDown (albaEventInteraction *e)
 
virtual void OnButtonUp (albaEventInteraction *e)
 
virtual void OnLeftButtonDown (albaEventInteraction *e)
 
virtual void OnLeftButtonUp (albaEventInteraction *e)
 
virtual void OnMiddleButtonDown (albaEventInteraction *e)
 
virtual void OnMiddleButtonUp (albaEventInteraction *e)
 
virtual void OnRightButtonDown (albaEventInteraction *e)
 
virtual void OnRightButtonUp (albaEventInteraction *e)
 
virtual void OnMove (albaEventInteraction *e)
 
virtual void OnChar (albaEventInteraction *e)
 
virtual void FlyTo (albaEventInteraction *e, int numstep=20, double zoom=1)
 
void InsertDevice (albaDevice *device, int button)
 
void RemoveDevice (albaDevice *device)
 
void SetCurrentBehavior (albaDevice *device, albaInteractor *inter)
 
albaInteractorGetCurrentBehavior (albaDevice *device)
 
void SetPickedVME (albaDevice *device, albaVME *vme)
 
albaVMEGetPickedVME (albaDevice *device)
 
- Protected Member Functions inherited from albaInteractor
virtual int OnStartInteraction (albaEventInteraction *e)
 
virtual int OnStopInteraction (albaEventInteraction *e)
 
virtual void OnButtonDown (albaEventInteraction *e)
 
virtual void OnButtonUp (albaEventInteraction *e)
 
void ComputeDisplayToWorld (double x, double y, double z, double worldPt[4])
 
void ComputeWorldToDisplay (double x, double y, double z, double displayPt[3])
 
- Protected Member Functions inherited from albaAgent
 albaAgent ()
 
virtual ~albaAgent ()
 
virtual int InternalInitialize ()
 
virtual void InternalShutdown ()
 
void InvokeEvent (albaEventBase &event, albaID channel=-1)
 
void InvokeEvent (albaEventBase *event, albaID channel=-1)
 
void InvokeEvent (void *sender, int id, albaID channel=MCH_UP, void *data=NULL)
 

Protected Attributes

std::vector< Measure2Dm_Measure2DVector
 
int m_MaxMeasures
 
albaDeviceButtonsPadMousem_Mouse
 
vtkRenderer * m_Renderer
 
vtkRenderer * m_CurrentRenderer
 
std::vector< vtkRenderer * > m_AllRenderersVector
 
albaViewm_View
 
vtkCoordinate * m_Coordinate
 
albaRWIBasem_CurrentRwi
 
std::vector< vtkALBATextActorMeter * > m_TextActorVector
 
albaString m_MeasureTypeText
 
int m_AltPressed
 
int m_ShiftPressed
 
Color m_Colors [5]
 
int m_CurrMeasure
 
int m_CurrPoint
 
double m_OldLineP1 [3]
 
double m_OldLineP2 [3]
 
double * m_Bounds
 
bool m_IsInBound
 
bool m_ButtonDownInside
 
double m_StartMousePosition [3]
 
bool m_EndMeasure
 
bool m_ParallelView
 
double m_ViewPlaneNormal [3]
 
int m_CurrPlane
 
double m_ParallelScale_OnStart
 
long m_AddMeasurePhase_Counter
 
bool m_ActorAdded
 
double m_MeasureValue
 
int m_LastSelection
 
int m_LastEditing
 
bool m_IsEnabled
 
bool m_MovingMeasure
 
bool m_AddMeasureEnable
 
bool m_EditMeasureEnable
 
bool m_MoveMeasureEnable
 
bool m_ShowText
 
bool m_ShowPoint
 
double m_PointSize
 
double m_LineWidth
 
int m_TextSide
 
double m_PointUpdateDist
 
double m_PointUpdateDist2
 
- Protected Attributes inherited from albaInteractorPER
bool m_FlyToFlag
 
bool m_DraggingLeft
 
bool m_CanSelect
 
bool m_ShowContextMenu
 
int m_Mode
 
int m_FirstTime
 
albaInteractorm_CameraBehavior
 
albaInteractorm_CameraMouseBehavior
 
std::map< albaID, DeviceItemm_Devices
 
- Protected Attributes inherited from albaInteractor
albaDevicem_Device
 
bool m_DeviceIsSet
 
albaID m_StartInteractionEvent
 
albaID m_StopInteractionEvent
 
int m_IgnoreTriggerEvents
 
int m_InteractionFlag
 
int m_StartButton
 
unsigned long m_Modifiers
 
int m_CurrentButton
 
unsigned long m_CurrentModifier
 
int m_ButtonMode
 
int m_ButtonsCounter
 
albaVMEm_VME
 
albaViewm_View
 
vtkALBASmartPointer< vtkRenderer > m_Renderer
 
vtkALBASmartPointer< vtkProp3D > m_Prop
 
bool m_TestMode
 
- Protected Attributes inherited from albaAgent
albaString m_Name
 
bool m_Initialized
 
std::vector< albaEventBroadcaster * > m_Channels
 
- Protected Attributes inherited from albaReferenceCounted
int m_ReferenceCount
 
- Protected Attributes inherited from albaObject
bool m_HeapFlag
 
- Protected Attributes inherited from albaEventBroadcaster
albaObserversList m_Observers
 
albaID m_Channel
 
- Protected Attributes inherited from albaEventSender
albaObserverm_Listener
 

Friends

class albaInteractor2DMeasureTest
 

Additional Inherited Members

- Static Public Member Functions inherited from albaObject
static const char * GetStaticTypeName ()
 
static bool IsStaticType (const char *type_name)
 
static bool IsStaticType (const albaTypeID &type_id)
 
static const albaTypeIDGetStaticTypeId ()
 
static albaObjectSafeDownCast (albaObject *o)
 

Detailed Description

Definition at line 53 of file albaInteractor2DMeasure.h.

Member Enumeration Documentation

◆ MEASURE_INTERACTIONS

Enumerator
ID_MEASURE_STARTED 
ID_MEASURE_FINISHED 
ID_MEASURE_ADDED 
ID_MEASURE_CHANGED 
ID_MEASURE_MOVED 
ID_MEASURE_SELECTED 
ID_MEASURE_RCLICK 

Definition at line 59 of file albaInteractor2DMeasure.h.

◆ MEASURE_ACTIONS

Enumerator
ACTION_NONE 
ACTION_ADD_MEASURE 
ACTION_EDIT_MEASURE 
ACTION_MOVE_MEASURE 

Definition at line 70 of file albaInteractor2DMeasure.h.

◆ LINE_POINT

Enumerator
NO_POINT 
POINT_1 
POINT_2 
POINT_3 
POINT_4 

Definition at line 78 of file albaInteractor2DMeasure.h.

◆ AXIS

Enumerator

Definition at line 210 of file albaInteractor2DMeasure.h.

◆ Colors

Enumerator
COLOR_DEFAULT 
COLOR_EDIT 
COLOR_SELECTION 
COLOR_DISABLE 
COLOR_TEXT 

Definition at line 211 of file albaInteractor2DMeasure.h.

Constructor & Destructor Documentation

◆ albaInteractor2DMeasure()

albaInteractor2DMeasure::albaInteractor2DMeasure ( )
protected

◆ ~albaInteractor2DMeasure()

virtual albaInteractor2DMeasure::~albaInteractor2DMeasure ( )
protectedvirtual

Member Function Documentation

◆ albaTypeMacro()

albaInteractor2DMeasure::albaTypeMacro ( albaInteractor2DMeasure  ,
albaInteractorPER   
)

◆ OnEvent()

virtual void albaInteractor2DMeasure::OnEvent ( albaEventBase event)
virtual

Process events coming from input device.

Reimplemented from albaInteractorPER.

◆ AddMeasure()

virtual void albaInteractor2DMeasure::AddMeasure ( double *  point1,
double *  point2 = NULL 
)
virtual

◆ RemoveMeasure()

virtual void albaInteractor2DMeasure::RemoveMeasure ( int  index)
virtual

◆ RemoveAllMeasures()

virtual void albaInteractor2DMeasure::RemoveAllMeasures ( )
virtual

Delete all Measures.

◆ SelectMeasure()

virtual void albaInteractor2DMeasure::SelectMeasure ( int  index)
virtual

◆ ActivateMeasure()

virtual void albaInteractor2DMeasure::ActivateMeasure ( int  index = -1,
bool  activate = true 
)
virtual

Disable Measure.

◆ Enable()

void albaInteractor2DMeasure::Enable ( bool  enable = true)
inline

Enable/Disable Measure Interactor.

Definition at line 102 of file albaInteractor2DMeasure.h.

◆ EnableAddMeasure()

void albaInteractor2DMeasure::EnableAddMeasure ( bool  move = true)
inline

Enable/Disable Add Mode.

Definition at line 105 of file albaInteractor2DMeasure.h.

◆ EnableEditMeasure()

void albaInteractor2DMeasure::EnableEditMeasure ( bool  edit = true)
inline

Enable/Disable Editing Mode.

Definition at line 107 of file albaInteractor2DMeasure.h.

◆ EnableMoveMeasure()

void albaInteractor2DMeasure::EnableMoveMeasure ( bool  move = true)
inline

Enable/Disable Moving Mode.

Definition at line 109 of file albaInteractor2DMeasure.h.

◆ Update()

virtual void albaInteractor2DMeasure::Update ( int  index = -1)
inlinevirtual

Update All Actors.

Definition at line 112 of file albaInteractor2DMeasure.h.

◆ Load()

virtual bool albaInteractor2DMeasure::Load ( albaVME input,
wxString  tag 
)
inlinevirtual

◆ Save()

virtual bool albaInteractor2DMeasure::Save ( albaVME input,
wxString  tag 
)
inlinevirtual

◆ GetMeasureValue()

double albaInteractor2DMeasure::GetMeasureValue ( int  index)

GET.

Get Measure Value

◆ GetMeasureText()

albaString albaInteractor2DMeasure::GetMeasureText ( int  index)

Get Measure Text Value.

◆ GetMeasureLabel()

albaString albaInteractor2DMeasure::GetMeasureLabel ( int  index)

Get Measure Extra Label.

◆ GetMeasureType()

albaString albaInteractor2DMeasure::GetMeasureType ( )
inline

Get a string type of measure.

Definition at line 126 of file albaInteractor2DMeasure.h.

◆ GetMaxMeasures()

int albaInteractor2DMeasure::GetMaxMeasures ( )
inline

Get Max Measures.

Definition at line 129 of file albaInteractor2DMeasure.h.

◆ GetMeasureCount()

int albaInteractor2DMeasure::GetMeasureCount ( )
inline

Get Number of Measures.

Definition at line 131 of file albaInteractor2DMeasure.h.

◆ GetLastEditedMeasureIndex()

int albaInteractor2DMeasure::GetLastEditedMeasureIndex ( )
inline

Returns the last Edited Measure index.

Definition at line 133 of file albaInteractor2DMeasure.h.

◆ GetSelectedMeasureIndex()

int albaInteractor2DMeasure::GetSelectedMeasureIndex ( )
inline

Returns the Current Measure Selected index.

Definition at line 135 of file albaInteractor2DMeasure.h.

◆ IsEnabled()

bool albaInteractor2DMeasure::IsEnabled ( )
inline

Measure Interactor Is Enabled.

Definition at line 137 of file albaInteractor2DMeasure.h.

◆ GetPointSize()

double albaInteractor2DMeasure::GetPointSize ( )
inline

Definition at line 139 of file albaInteractor2DMeasure.h.

◆ GetLineWidth()

double albaInteractor2DMeasure::GetLineWidth ( )
inline

Definition at line 140 of file albaInteractor2DMeasure.h.

◆ SetMaxMeasures()

void albaInteractor2DMeasure::SetMaxMeasures ( int  maxMeasures)
inline

SET.

Set Max Measures

Definition at line 144 of file albaInteractor2DMeasure.h.

◆ SetMeasureLabel()

void albaInteractor2DMeasure::SetMeasureLabel ( int  index,
albaString  text 
)

Set Measure Extra Label.

◆ SetColorDefault()

void albaInteractor2DMeasure::SetColorDefault ( double  r,
double  g,
double  b,
double  a = 1.0 
)
inline

Set Color Default.

Definition at line 149 of file albaInteractor2DMeasure.h.

◆ SetColorSelection()

void albaInteractor2DMeasure::SetColorSelection ( double  r,
double  g,
double  b,
double  a = 1.0 
)
inline

Set Color Selection.

Definition at line 151 of file albaInteractor2DMeasure.h.

◆ SetColorEdit()

void albaInteractor2DMeasure::SetColorEdit ( double  r,
double  g,
double  b,
double  a = 1.0 
)
inline

Set Color Edit.

Definition at line 153 of file albaInteractor2DMeasure.h.

◆ SetColorDisable()

void albaInteractor2DMeasure::SetColorDisable ( double  r,
double  g,
double  b,
double  a = 1.0 
)
inline

Set Color For Disable Measure.

Definition at line 155 of file albaInteractor2DMeasure.h.

◆ SetColorText()

void albaInteractor2DMeasure::SetColorText ( double  r,
double  g,
double  b,
double  a = 1.0 
)
inline

Set Color For Disable Measure.

Definition at line 157 of file albaInteractor2DMeasure.h.

◆ SetPointSize()

virtual void albaInteractor2DMeasure::SetPointSize ( double  size)
inlinevirtual

◆ SetLineWidth()

virtual void albaInteractor2DMeasure::SetLineWidth ( double  width)
inlinevirtual

◆ Show()

virtual void albaInteractor2DMeasure::Show ( bool  show)
inlinevirtual

◆ ShowText() [1/2]

void albaInteractor2DMeasure::ShowText ( bool  show)

Show/Hide Text Labels.

◆ ShowText() [2/2]

void albaInteractor2DMeasure::ShowText ( int  measure,
bool  show 
)

◆ SetRendererByView()

void albaInteractor2DMeasure::SetRendererByView ( albaView view)

Set Renderer by View needed.

◆ Render()

void albaInteractor2DMeasure::Render ( )

◆ GetCurreasureIdx()

int albaInteractor2DMeasure::GetCurreasureIdx ( ) const
inline

Returns current measure index.

Definition at line 175 of file albaInteractor2DMeasure.h.

◆ GetCurrentRwi() [1/2]

albaRWIBase * albaInteractor2DMeasure::GetCurrentRwi ( )
inline

return the current rwi

Definition at line 178 of file albaInteractor2DMeasure.h.

◆ GetCurrentRwi() [2/2]

albaRWIBase * albaInteractor2DMeasure::GetCurrentRwi ( int  m)
inline

Definition at line 179 of file albaInteractor2DMeasure.h.

◆ GetCurrPlane()

int albaInteractor2DMeasure::GetCurrPlane ( )
inline

Definition at line 181 of file albaInteractor2DMeasure.h.

◆ SetCurrPlane()

void albaInteractor2DMeasure::SetCurrPlane ( int  plane)
inline

Definition at line 182 of file albaInteractor2DMeasure.h.

◆ ReDrawAll()

virtual void albaInteractor2DMeasure::ReDrawAll ( )
inlinevirtual

Reimplemented in albaInteractor2DMeasure_Point.

Definition at line 185 of file albaInteractor2DMeasure.h.

◆ SetUpdateDistance()

void albaInteractor2DMeasure::SetUpdateDistance ( double  dist)

◆ SetAction()

void albaInteractor2DMeasure::SetAction ( MEASURE_ACTIONS  action)

Set Measure Action (None, Add, Edit, Move) and Update mouse Cursor.

◆ InitRenderer()

void albaInteractor2DMeasure::InitRenderer ( albaEventInteraction e)
protected

◆ OnLeftButtonDown()

virtual void albaInteractor2DMeasure::OnLeftButtonDown ( albaEventInteraction e)
protectedvirtual

Mouse Events.

Reimplemented from albaInteractorPER.

◆ OnLeftButtonUp()

virtual void albaInteractor2DMeasure::OnLeftButtonUp ( albaEventInteraction e)
protectedvirtual

Reimplemented from albaInteractorPER.

◆ OnRightButtonUp()

virtual void albaInteractor2DMeasure::OnRightButtonUp ( albaEventInteraction e)
protectedvirtual

Reimplemented from albaInteractorPER.

◆ OnMove()

virtual void albaInteractor2DMeasure::OnMove ( albaEventInteraction e)
protectedvirtual

Reimplemented from albaInteractorPER.

◆ DrawNewMeasure()

virtual void albaInteractor2DMeasure::DrawNewMeasure ( double *  wp)
inlineprotectedvirtual

◆ MoveMeasure()

virtual void albaInteractor2DMeasure::MoveMeasure ( int  index,
double *  pointCoord 
)
inlineprotectedvirtual

◆ EditMeasure()

virtual void albaInteractor2DMeasure::EditMeasure ( int  index,
double *  point 
)
inlineprotectedvirtual

◆ FindAndHighlight()

virtual void albaInteractor2DMeasure::FindAndHighlight ( double *  pointCoord)
inlineprotectedvirtual

◆ UpdateEditActors()

virtual void albaInteractor2DMeasure::UpdateEditActors ( double *  point1,
double *  point2 = NULL 
)
inlineprotectedvirtual

Update.

Definition at line 234 of file albaInteractor2DMeasure.h.

◆ UpdatePointActor()

virtual void albaInteractor2DMeasure::UpdatePointActor ( double *  point)
inlineprotectedvirtual

Definition at line 235 of file albaInteractor2DMeasure.h.

◆ UpdateTextActor()

virtual void albaInteractor2DMeasure::UpdateTextActor ( int  index,
double *  point 
)
protectedvirtual

Reimplemented in albaInteractor2DMeasure_Point.

◆ ShowEditLineActors()

virtual void albaInteractor2DMeasure::ShowEditLineActors ( )
inlineprotectedvirtual

Definition at line 238 of file albaInteractor2DMeasure.h.

◆ HideEditActors()

virtual void albaInteractor2DMeasure::HideEditActors ( )
inlineprotectedvirtual

Definition at line 239 of file albaInteractor2DMeasure.h.

◆ SetColor()

void albaInteractor2DMeasure::SetColor ( vtkActor2D *  actor,
Color color 
)
protected

◆ GetAction()

MEASURE_ACTIONS albaInteractor2DMeasure::GetAction ( )
inlineprotected

Get current Measure.

Definition at line 247 of file albaInteractor2DMeasure.h.

◆ iSetColor()

void albaInteractor2DMeasure::iSetColor ( int  color,
double  r,
double  g,
double  b,
double  a 
)
protected

◆ IsInBound()

bool albaInteractor2DMeasure::IsInBound ( double *  pos)
protected

Utilities.

◆ ScreenToWorld()

void albaInteractor2DMeasure::ScreenToWorld ( double  screen[2],
double  world[3] 
)
protected

◆ PixelSizeInWorld()

double albaInteractor2DMeasure::PixelSizeInWorld ( )
protected

◆ WorldToScreen()

void albaInteractor2DMeasure::WorldToScreen ( double  world[3],
double  screen[2] 
)
protected

◆ GetNewPointSource()

vtkPointSource * albaInteractor2DMeasure::GetNewPointSource ( )
protected

◆ DistanceBetweenPoints()

double albaInteractor2DMeasure::DistanceBetweenPoints ( double *  point1,
double *  point2 
)
protected

◆ DistancePointToLine()

double albaInteractor2DMeasure::DistancePointToLine ( double *  point,
double *  lineP1,
double *  lineP2 
)
protected

◆ GetMidPoint()

void albaInteractor2DMeasure::GetMidPoint ( double(&)  midPoint[3],
double *  point1,
double *  point2 
)
protected

◆ FindPointOnLine()

bool albaInteractor2DMeasure::FindPointOnLine ( double(&)  point[3],
double *  linePoint1,
double *  linePoint2,
double  distance 
)
protected

◆ GetAngle()

double albaInteractor2DMeasure::GetAngle ( double *  point1,
double *  point2,
double *  origin 
)
protected

◆ RotatePoint()

void albaInteractor2DMeasure::RotatePoint ( double *  point,
double *  origin,
double  angle 
)
protected

◆ PointUpDownLine()

int albaInteractor2DMeasure::PointUpDownLine ( double *  point,
double *  lp1,
double *  lp2 
)
protected

◆ GetParallelLine()

void albaInteractor2DMeasure::GetParallelLine ( double(&)  point1[3],
double(&)  point2[3],
double *  linePoint1,
double *  linePoint2,
double  distance 
)
protected

Friends And Related Function Documentation

◆ albaInteractor2DMeasureTest

friend class albaInteractor2DMeasureTest
friend

Definition at line 335 of file albaInteractor2DMeasure.h.

Member Data Documentation

◆ m_Measure2DVector

std::vector<Measure2D> albaInteractor2DMeasure::m_Measure2DVector
protected

Definition at line 207 of file albaInteractor2DMeasure.h.

◆ m_MaxMeasures

int albaInteractor2DMeasure::m_MaxMeasures
protected

Definition at line 208 of file albaInteractor2DMeasure.h.

◆ m_Mouse

albaDeviceButtonsPadMouse* albaInteractor2DMeasure::m_Mouse
protected

Definition at line 269 of file albaInteractor2DMeasure.h.

◆ m_Renderer

vtkRenderer* albaInteractor2DMeasure::m_Renderer
protected

Definition at line 270 of file albaInteractor2DMeasure.h.

◆ m_CurrentRenderer

vtkRenderer* albaInteractor2DMeasure::m_CurrentRenderer
protected

Definition at line 271 of file albaInteractor2DMeasure.h.

◆ m_AllRenderersVector

std::vector<vtkRenderer *> albaInteractor2DMeasure::m_AllRenderersVector
protected

Definition at line 272 of file albaInteractor2DMeasure.h.

◆ m_View

albaView* albaInteractor2DMeasure::m_View
protected

Definition at line 273 of file albaInteractor2DMeasure.h.

◆ m_Coordinate

vtkCoordinate* albaInteractor2DMeasure::m_Coordinate
protected

Definition at line 274 of file albaInteractor2DMeasure.h.

◆ m_CurrentRwi

albaRWIBase* albaInteractor2DMeasure::m_CurrentRwi
protected

Definition at line 276 of file albaInteractor2DMeasure.h.

◆ m_TextActorVector

std::vector<vtkALBATextActorMeter *> albaInteractor2DMeasure::m_TextActorVector
protected

Definition at line 279 of file albaInteractor2DMeasure.h.

◆ m_MeasureTypeText

albaString albaInteractor2DMeasure::m_MeasureTypeText
protected

Definition at line 281 of file albaInteractor2DMeasure.h.

◆ m_AltPressed

int albaInteractor2DMeasure::m_AltPressed
protected

Definition at line 283 of file albaInteractor2DMeasure.h.

◆ m_ShiftPressed

int albaInteractor2DMeasure::m_ShiftPressed
protected

Definition at line 284 of file albaInteractor2DMeasure.h.

◆ m_Colors

Color albaInteractor2DMeasure::m_Colors[5]
protected

Definition at line 286 of file albaInteractor2DMeasure.h.

◆ m_CurrMeasure

int albaInteractor2DMeasure::m_CurrMeasure
protected

Definition at line 288 of file albaInteractor2DMeasure.h.

◆ m_CurrPoint

int albaInteractor2DMeasure::m_CurrPoint
protected

Definition at line 289 of file albaInteractor2DMeasure.h.

◆ m_OldLineP1

double albaInteractor2DMeasure::m_OldLineP1[3]
protected

Definition at line 291 of file albaInteractor2DMeasure.h.

◆ m_OldLineP2

double albaInteractor2DMeasure::m_OldLineP2[3]
protected

Definition at line 292 of file albaInteractor2DMeasure.h.

◆ m_Bounds

double* albaInteractor2DMeasure::m_Bounds
protected

Definition at line 294 of file albaInteractor2DMeasure.h.

◆ m_IsInBound

bool albaInteractor2DMeasure::m_IsInBound
protected

Definition at line 295 of file albaInteractor2DMeasure.h.

◆ m_ButtonDownInside

bool albaInteractor2DMeasure::m_ButtonDownInside
protected

Definition at line 296 of file albaInteractor2DMeasure.h.

◆ m_StartMousePosition

double albaInteractor2DMeasure::m_StartMousePosition[3]
protected

Definition at line 298 of file albaInteractor2DMeasure.h.

◆ m_EndMeasure

bool albaInteractor2DMeasure::m_EndMeasure
protected

Definition at line 300 of file albaInteractor2DMeasure.h.

◆ m_ParallelView

bool albaInteractor2DMeasure::m_ParallelView
protected

Definition at line 301 of file albaInteractor2DMeasure.h.

◆ m_ViewPlaneNormal

double albaInteractor2DMeasure::m_ViewPlaneNormal[3]
protected

Definition at line 302 of file albaInteractor2DMeasure.h.

◆ m_CurrPlane

int albaInteractor2DMeasure::m_CurrPlane
protected

Definition at line 303 of file albaInteractor2DMeasure.h.

◆ m_ParallelScale_OnStart

double albaInteractor2DMeasure::m_ParallelScale_OnStart
protected

Definition at line 304 of file albaInteractor2DMeasure.h.

◆ m_AddMeasurePhase_Counter

long albaInteractor2DMeasure::m_AddMeasurePhase_Counter
protected

Definition at line 306 of file albaInteractor2DMeasure.h.

◆ m_ActorAdded

bool albaInteractor2DMeasure::m_ActorAdded
protected

Definition at line 307 of file albaInteractor2DMeasure.h.

◆ m_MeasureValue

double albaInteractor2DMeasure::m_MeasureValue
protected

Definition at line 309 of file albaInteractor2DMeasure.h.

◆ m_LastSelection

int albaInteractor2DMeasure::m_LastSelection
protected

Definition at line 310 of file albaInteractor2DMeasure.h.

◆ m_LastEditing

int albaInteractor2DMeasure::m_LastEditing
protected

Definition at line 311 of file albaInteractor2DMeasure.h.

◆ m_IsEnabled

bool albaInteractor2DMeasure::m_IsEnabled
protected

Definition at line 313 of file albaInteractor2DMeasure.h.

◆ m_MovingMeasure

bool albaInteractor2DMeasure::m_MovingMeasure
protected

Definition at line 314 of file albaInteractor2DMeasure.h.

◆ m_AddMeasureEnable

bool albaInteractor2DMeasure::m_AddMeasureEnable
protected

Definition at line 315 of file albaInteractor2DMeasure.h.

◆ m_EditMeasureEnable

bool albaInteractor2DMeasure::m_EditMeasureEnable
protected

Definition at line 316 of file albaInteractor2DMeasure.h.

◆ m_MoveMeasureEnable

bool albaInteractor2DMeasure::m_MoveMeasureEnable
protected

Definition at line 317 of file albaInteractor2DMeasure.h.

◆ m_ShowText

bool albaInteractor2DMeasure::m_ShowText
protected

Definition at line 319 of file albaInteractor2DMeasure.h.

◆ m_ShowPoint

bool albaInteractor2DMeasure::m_ShowPoint
protected

Definition at line 320 of file albaInteractor2DMeasure.h.

◆ m_PointSize

double albaInteractor2DMeasure::m_PointSize
protected

Definition at line 322 of file albaInteractor2DMeasure.h.

◆ m_LineWidth

double albaInteractor2DMeasure::m_LineWidth
protected

Definition at line 323 of file albaInteractor2DMeasure.h.

◆ m_TextSide

int albaInteractor2DMeasure::m_TextSide
protected

Definition at line 324 of file albaInteractor2DMeasure.h.

◆ m_PointUpdateDist

double albaInteractor2DMeasure::m_PointUpdateDist
protected

Definition at line 326 of file albaInteractor2DMeasure.h.

◆ m_PointUpdateDist2

double albaInteractor2DMeasure::m_PointUpdateDist2
protected

Definition at line 327 of file albaInteractor2DMeasure.h.


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