Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SVTK_SelectorDef Class Reference

#include <SVTK_SelectorDef.h>

Inheritance diagram for SVTK_SelectorDef:
Inheritance graph

Classes

struct  TIndexedMapOfInteger
 
struct  TIOLessThan
 

Public Member Functions

 SVTK_SelectorDef ()
 
virtual ~SVTK_SelectorDef ()
 
virtual void SetSelectionMode (Selection_Mode theMode)
 
virtual Selection_Mode SelectionMode () const
 Get current Selection_Mode. More...
 
virtual void ClearIObjects ()
 
virtual SALOME_ActorGetActor (const Handle(SALOME_InteractiveObject)&theIO) const
 
virtual bool IsSelected (const Handle(SALOME_InteractiveObject)&theIO) const
 
virtual bool IsSelected (SALOME_Actor *theActor) const
 
virtual bool AddIObject (const Handle(SALOME_InteractiveObject)&theIO)
 
virtual bool AddIObject (SALOME_Actor *theActor)
 
virtual bool RemoveIObject (const Handle(SALOME_InteractiveObject)&theIO)
 
virtual bool RemoveIObject (SALOME_Actor *theActor)
 
virtual const SALOME_ListIOStoredIObjects () const
 
virtual int IObjectCount () const
 
virtual bool HasIndex (const Handle(SALOME_InteractiveObject)&theIO) const
 
virtual void GetIndex (const Handle(SALOME_InteractiveObject)&theIO, TColStd_IndexedMapOfInteger &theIndex)
 
virtual bool AddOrRemoveIndex (const Handle(SALOME_InteractiveObject)&theIO, const TColStd_IndexedMapOfInteger &theIndices, bool theIsModeShift)
 
virtual bool AddOrRemoveIndex (const Handle(SALOME_InteractiveObject)&theIO, const TColStd_MapOfInteger &theIndices, bool theIsModeShift)
 
virtual bool AddOrRemoveIndex (const Handle(SALOME_InteractiveObject)&theIO, int theIndex, bool theIsModeShift)
 
virtual void RemoveIndex (const Handle(SALOME_InteractiveObject)&theIO, int theIndex)
 
virtual bool IsIndexSelected (const Handle(SALOME_InteractiveObject)&theIO, int theIndex) const
 
virtual void ClearIndex ()
 
virtual void SetFilter (const Handle(VTKViewer_Filter)&theFilter)
 
virtual Handle (VTKViewer_Filter) GetFilter(const TFilterID theId) const
 To get a section filter by its number. More...
 
virtual bool IsFilterPresent (const TFilterID theId) const
 
virtual void RemoveFilter (const int theId)
 
virtual bool IsValid (SALOME_Actor *theActor, const TFilterID theId, const bool theIsNode=false) const
 
virtual void StartPickCallback ()
 
virtual void EndPickCallback ()
 
virtual vtkActorCollection * Pick (const SVTK_SelectionEvent *theEvent, vtkRenderer *theRenderer) const
 
virtual void SetTolerance (const double &theTolerance)
 
virtual void SetDynamicPreSelection (bool theIsDynPreselect)
 
virtual bool GetDynamicPreSelection () const
 
virtual void SetPreSelectionEnabled (bool theEnabled)
 
virtual bool IsPreSelectionEnabled () const
 
virtual void SetSelectionEnabled (bool theEnabled)
 
virtual bool IsSelectionEnabled () const
 
- Public Member Functions inherited from SVTK_Selector
 vtkTypeMacro (SVTK_Selector, vtkObject)
 

Private Types

typedef std::set< Handle(SALOME_InteractiveObject),
TIOLessThan
TIObjects
 
typedef std::map< Handle(SALOME_InteractiveObject),
vtkSmartPointer< SALOME_Actor >
, TIOLessThan
TIO2Actors
 
typedef std::map< Handle(SALOME_InteractiveObject),
TIndexedMapOfInteger,
TIOLessThan
TMapIOSubIndex
 
typedef std::map< TFilterID,
Handle(VTKViewer_Filter)> 
TFilters
 

Private Attributes

int mySelectionMode
 
bool myDynamicPreselection
 
bool myPreselectionEnabled
 
bool mySelectionEnabled
 
SALOME_ListIO myIObjectList
 
TIObjects myIObjects
 
TIO2Actors myIO2Actors
 
TMapIOSubIndex myMapIOSubIndex
 
TFilters myFilters
 
vtkSmartPointer< vtkPicker > myPicker
 
vtkSmartPointer< vtkCellPicker > myCellPicker
 

Additional Inherited Members

- Public Types inherited from SVTK_Selector
typedef int TFilterID
 
- Static Public Member Functions inherited from SVTK_Selector
static SVTK_SelectorNew ()
 

Member Typedef Documentation

Constructor & Destructor Documentation

SVTK_SelectorDef::SVTK_SelectorDef ( )

Default constructor

References ActorSelection.

SVTK_SelectorDef::~SVTK_SelectorDef ( )
virtual

Destructor

Member Function Documentation

bool SVTK_SelectorDef::AddIObject ( const Handle(SALOME_InteractiveObject)&  theIO)
virtual

Adds SALOME_InteractiveObject into selection

Parameters
theIO- SALOME_InteractiveObject

Implements SVTK_Selector.

bool SVTK_SelectorDef::AddIObject ( SALOME_Actor theActor)
virtual

Adds SALOME_Actor into selection

Parameters
theActor- SALOME_Actor

Implements SVTK_Selector.

References Handle().

bool SVTK_SelectorDef::AddOrRemoveIndex ( const Handle(SALOME_InteractiveObject)&  theIO,
const TColStd_IndexedMapOfInteger &  theIndices,
bool  theIsModeShift 
)
virtual

Changes indices of subselection for SALOME_InteractiveObject

Parameters
theIO- SALOME_InteractiveObject
theIndices- indices
theIsModeShift- if it is false, then map will be cleared before indices are added

Implements SVTK_Selector.

References SVTK_SelectorDef::TIndexedMapOfInteger::myMap.

bool SVTK_SelectorDef::AddOrRemoveIndex ( const Handle(SALOME_InteractiveObject)&  theIO,
const TColStd_MapOfInteger &  theIndices,
bool  theIsModeShift 
)
virtual

Changes indices of subselection for SALOME_InteractiveObject

Parameters
theIO- SALOME_InteractiveObject
theIndices- indices
theIsModeShift- if it is false, then map will be cleared before indices are added

Implements SVTK_Selector.

References SVTK_SelectorDef::TIndexedMapOfInteger::myMap.

bool SVTK_SelectorDef::AddOrRemoveIndex ( const Handle(SALOME_InteractiveObject)&  theIO,
int  theIndex,
bool  theIsModeShift 
)
virtual

Changes indices of subselection for SALOME_InteractiveObject

Parameters
theIO- SALOME_InteractiveObject
theIndex- index
theIsModeShift- if it is false, then map will be cleared before indices are added

Implements SVTK_Selector.

References SVTK_SelectorDef::TIndexedMapOfInteger::myMap, and removeIndex().

void SVTK_SelectorDef::ClearIndex ( )
virtual

Clears all indices of subselection

Implements SVTK_Selector.

void SVTK_SelectorDef::ClearIObjects ( )
virtual

Clear selection

Implements SVTK_Selector.

void SVTK_SelectorDef::EndPickCallback ( )
virtual

To invoke selectionChanged signals

Implements SVTK_Selector.

SALOME_Actor * SVTK_SelectorDef::GetActor ( const Handle(SALOME_InteractiveObject)&  theIO) const
virtual
Returns
corresponding SALOME_Actor for SALOME_InteractiveObject
Parameters
theIO- SALOME_InteractiveObject

Implements SVTK_Selector.

bool SVTK_SelectorDef::GetDynamicPreSelection ( ) const
virtual

Implements SVTK_Selector.

void SVTK_SelectorDef::GetIndex ( const Handle(SALOME_InteractiveObject)&  theIO,
TColStd_IndexedMapOfInteger &  theIndex 
)
virtual

Gets indices of subselection for SALOME_InteractiveObject

Parameters
theIO- SALOME_InteractiveObject

Implements SVTK_Selector.

virtual SVTK_SelectorDef::Handle ( VTKViewer_Filter  ) const
virtual

Implements SVTK_Selector.

bool SVTK_SelectorDef::HasIndex ( const Handle(SALOME_InteractiveObject)&  theIO) const
virtual
Returns
true if the SALOME_InteractiveObject has a subselection
Parameters
theIO- SALOME_InteractiveObject

Implements SVTK_Selector.

int SVTK_SelectorDef::IObjectCount ( ) const
virtual
Returns
number of selected objects

Implements SVTK_Selector.

bool SVTK_SelectorDef::IsFilterPresent ( const TFilterID  theId) const
virtual
Returns
true if filter with given number is applyed
Parameters
theId- filter id

Implements SVTK_Selector.

bool SVTK_SelectorDef::IsIndexSelected ( const Handle(SALOME_InteractiveObject)&  theIO,
int  theIndex 
) const
virtual
Returns
true if the index presents in subselection
Parameters
theIO- SALOME_InteractiveObject
theIndex- index

Implements SVTK_Selector.

bool SVTK_SelectorDef::IsPreSelectionEnabled ( ) const
virtual

Implements SVTK_Selector.

bool SVTK_SelectorDef::IsSelected ( const Handle(SALOME_InteractiveObject)&  theIO) const
virtual
Returns
true if the SALOME_InteractiveObject presents into selection

Implements SVTK_Selector.

bool SVTK_SelectorDef::IsSelected ( SALOME_Actor theActor) const
virtual
Returns
true if the SALOME_Actor presents into selection

Implements SVTK_Selector.

References Handle().

bool SVTK_SelectorDef::IsSelectionEnabled ( ) const
virtual

Implements SVTK_Selector.

bool SVTK_SelectorDef::IsValid ( SALOME_Actor theActor,
const TFilterID  theId,
const bool  theIsNode = false 
) const
virtual
Returns
true if the index satisfy installed filters
Parameters
theActor- actor
theId- filter id
theIsNode- whether it is node

Implements SVTK_Selector.

References Handle().

vtkActorCollection * SVTK_SelectorDef::Pick ( const SVTK_SelectionEvent theEvent,
vtkRenderer *  theRenderer 
) const
virtual
void SVTK_SelectorDef::RemoveFilter ( const int  theId)
virtual

To remove a filter from the selection

Parameters
theId- filter id

Implements SVTK_Selector.

void SVTK_SelectorDef::RemoveIndex ( const Handle(SALOME_InteractiveObject)&  theIO,
int  theIndex 
)
virtual

Removes index of subselection for SALOME_InteractiveObject

Parameters
theIO- SALOME_InteractiveObject
theIndex- index

Implements SVTK_Selector.

References removeIndex().

bool SVTK_SelectorDef::RemoveIObject ( const Handle(SALOME_InteractiveObject)&  theIO)
virtual

Removes SALOME_InteractiveObject from selection

Parameters
theIO- SALOME_InteractiveObject

Implements SVTK_Selector.

bool SVTK_SelectorDef::RemoveIObject ( SALOME_Actor theActor)
virtual

Removes SALOME_Actor from selection

Parameters
theActor- SALOME_Actor

Implements SVTK_Selector.

References Handle().

virtual Selection_Mode SVTK_SelectorDef::SelectionMode ( ) const
inlinevirtual

Implements SVTK_Selector.

References mySelectionMode.

void SVTK_SelectorDef::SetDynamicPreSelection ( bool  theIsDynPreselect)
virtual

Implements SVTK_Selector.

void SVTK_SelectorDef::SetFilter ( const Handle(VTKViewer_Filter)&  theFilter)
virtual

To apply a filter on the selection

Parameters
theFilter- new filter

Implements SVTK_Selector.

References VTKViewer_Filter::GetId().

void SVTK_SelectorDef::SetPreSelectionEnabled ( bool  theEnabled)
virtual

Implements SVTK_Selector.

void SVTK_SelectorDef::SetSelectionEnabled ( bool  theEnabled)
virtual

Implements SVTK_Selector.

void SVTK_SelectorDef::SetSelectionMode ( Selection_Mode  theMode)
virtual

To change current Selection_Mode (as outside effect, it invokes selectionChange signal)

Implements SVTK_Selector.

void SVTK_SelectorDef::SetTolerance ( const double &  theTolerance)
virtual

Implements SVTK_Selector.

void SVTK_SelectorDef::StartPickCallback ( )
virtual

To invoke selectionChanged signals

Implements SVTK_Selector.

const SALOME_ListIO & SVTK_SelectorDef::StoredIObjects ( ) const
virtual
Returns
list of all SALOME_InteractiveObject presenting in selection

Implements SVTK_Selector.

Member Data Documentation

vtkSmartPointer<vtkCellPicker> SVTK_SelectorDef::myCellPicker
private
bool SVTK_SelectorDef::myDynamicPreselection
private
TFilters SVTK_SelectorDef::myFilters
private
TIO2Actors SVTK_SelectorDef::myIO2Actors
private
SALOME_ListIO SVTK_SelectorDef::myIObjectList
mutableprivate
TIObjects SVTK_SelectorDef::myIObjects
private
TMapIOSubIndex SVTK_SelectorDef::myMapIOSubIndex
private
vtkSmartPointer<vtkPicker> SVTK_SelectorDef::myPicker
private
bool SVTK_SelectorDef::myPreselectionEnabled
private
bool SVTK_SelectorDef::mySelectionEnabled
private
int SVTK_SelectorDef::mySelectionMode
private

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