![]() |
Slicer 5.9
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
|
Displayable manager for showing segmentations in slice (2D) views. More...
#include <Modules/Loadable/Segmentations/MRMLDM/vtkMRMLSegmentationsDisplayableManager2D.h>
Public Types | |
typedef vtkMRMLAbstractSliceViewDisplayableManager | Superclass |
![]() | |
typedef vtkMRMLAbstractSliceViewDisplayableManager | Self |
typedef vtkMRMLAbstractDisplayableManager | Superclass |
![]() | |
typedef vtkMRMLAbstractLogic | Superclass |
![]() | |
typedef vtkObject | Superclass |
typedef void(vtkMRMLAbstractLogic::* | TaskFunctionPointer) (void *clientdata) |
Public Member Functions | |
int | AddCustomSegmentRenderer (const std::string &segmentationDisplayNodeID, const std::string &segmentID) |
virtual const char * | GetClassName () |
std::string | GetCustomSegmentRendererSegmentationDisplayNodeID (int index) |
std::string | GetCustomSegmentRendererSegmentID (int index) |
int | GetCustomSegmentRendererTag (const std::string &segmentationDisplayNodeID, const std::string &segmentID) |
int | GetCustomSegmentRendererTag (int index) |
std::string | GetDataProbeInfoStringForPosition (double xyz[3]) override |
int | GetNumberOfCustomSegmentsRenderers () |
Get information on custom segment renderers. Intended for troubleshooting. | |
virtual void | GetVisibleSegmentsForPosition (double ras[3], vtkMRMLSegmentationDisplayNode *displayNode, vtkStringArray *segmentIDs, vtkDoubleArray *segmentValues=nullptr) |
bool | HasCustomSegmentRenderer (const std::string &segmentationDisplayNodeID, const std::string &segmentID) |
virtual int | IsA (const char *type) |
void | PrintSelf (ostream &os, vtkIndent indent) override |
bool | RemoveCustomSegmentRenderer (int tag) |
![]() | |
void | ConvertDeviceToXYZ (double x, double y, double xyz[3]) |
void | ConvertRASToXYZ (double ras[3], double xyz[3]) |
void | ConvertXYZToRAS (double xyz[3], double ras[3]) |
vtkMRMLSliceNode * | GetMRMLSliceNode () |
Get MRML SliceNode. | |
void | PrintSelf (ostream &os, vtkIndent indent) override |
![]() | |
virtual bool | CanProcessInteractionEvent (vtkMRMLInteractionEventData *eventData, double &distance2) |
virtual std::string | GetDataProbeInfoStringForPosition (double vtkNotUsed(xyz)[3]) |
virtual bool | GetGrabFocus () |
Displayable manager can indicate that it would like to get all events (even when mouse pointer is outside the window). | |
vtkMRMLInteractionNode * | GetInteractionNode () |
Convenient method to get the current InteractionNode. | |
virtual bool | GetInteractive () |
Displayable manager can indicate that the window is in interactive mode (faster updates). | |
vtkRenderWindowInteractor * | GetInteractor () |
Convenient method to get the WindowInteractor associated with the Renderer. | |
virtual vtkMRMLLightBoxRendererManagerProxy * | GetLightBoxRendererManagerProxy () |
virtual int | GetMouseCursor () |
Displayable manager returns ID of the mouse cursor shape that should be displayed. | |
vtkRenderer * | GetRenderer () |
Get the default renderer for this displayable manager. | |
vtkRenderer * | GetRenderer (int idx) |
vtkMRMLSelectionNode * | GetSelectionNode () |
Convenient method to get the current SelectionNode. | |
bool | IsCreated () |
void | PrintSelf (ostream &os, vtkIndent indent) override |
virtual bool | ProcessInteractionEvent (vtkMRMLInteractionEventData *eventData) |
virtual void | SetHasFocus (bool hasFocus, vtkMRMLInteractionEventData *eventData) |
Set if the widget gets/loses focus (interaction events are processed by this displayable manager). | |
virtual void | SetLightBoxRendererManagerProxy (vtkMRMLLightBoxRendererManagerProxy *) |
void | SetMouseCursor (int cursor) |
![]() | |
virtual vtkMRMLApplicationLogic * | GetMRMLApplicationLogic () const |
Get access to overall application state. | |
vtkMRMLScene * | GetMRMLScene () const |
Return a reference to the current MRML scene. | |
void | PrintSelf (ostream &os, vtkIndent indent) override |
virtual void | SetMRMLApplicationLogic (vtkMRMLApplicationLogic *logic) |
void | SetMRMLScene (vtkMRMLScene *newScene) |
Set and observe the MRMLScene. | |
Static Public Member Functions | |
static int | IsTypeOf (const char *type) |
static vtkMRMLSegmentationsDisplayableManager2D * | New () |
static vtkMRMLSegmentationsDisplayableManager2D * | SafeDownCast (vtkObject *o) |
![]() | |
static void | ConvertDeviceToXYZ (vtkRenderer *renderer, vtkMRMLSliceNode *sliceNode, double x, double y, double xyz[3]) |
static void | ConvertDeviceToXYZ (vtkRenderWindowInteractor *interactor, vtkMRMLSliceNode *sliceNode, double x, double y, double xyz[3]) |
static void | ConvertRASToXYZ (vtkMRMLSliceNode *sliceNode, double ras[3], double xyz[3]) |
static void | ConvertXYZToRAS (vtkMRMLSliceNode *sliceNode, double xyz[3], double ras[3]) |
static int | IsTypeOf (const char *type) |
static vtkMRMLAbstractSliceViewDisplayableManager * | New () |
static vtkMRMLAbstractSliceViewDisplayableManager * | SafeDownCast (vtkObject *o) |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkMRMLAbstractDisplayableManager * | New () |
static vtkMRMLAbstractDisplayableManager * | SafeDownCast (vtkObject *o) |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkMRMLAbstractLogic * | New () |
static vtkMRMLAbstractLogic * | SafeDownCast (vtkObject *o) |
Protected Member Functions | |
void | Create () override |
Initialize the displayable manager based on its associated vtkMRMLSliceNode. | |
void | OnMRMLSceneEndBatchProcess () override |
void | OnMRMLSceneEndClose () override |
void | OnMRMLSceneNodeAdded (vtkMRMLNode *node) override |
void | OnMRMLSceneNodeRemoved (vtkMRMLNode *node) override |
void | OnMRMLSceneStartClose () override |
void | ProcessMRMLNodesEvents (vtkObject *caller, unsigned long event, void *callData) override |
void | UnobserveMRMLScene () override |
void | UpdateFromMRML () override |
Update Actors based on transforms in the scene. | |
vtkMRMLSegmentationsDisplayableManager2D () | |
~vtkMRMLSegmentationsDisplayableManager2D () override | |
![]() | |
void | OnMRMLDisplayableNodeModifiedEvent (vtkObject *caller) override |
virtual void | OnMRMLSliceNodeModifiedEvent () |
Could be overloaded if DisplayableManager subclass. | |
vtkMRMLAbstractSliceViewDisplayableManager () | |
~vtkMRMLAbstractSliceViewDisplayableManager () override | |
![]() | |
virtual int | ActiveInteractionModes () |
void | AddInteractorObservableEvent (int eventid, float priority=0.0) |
void | AddInteractorStyleObservableEvent (int eventid, float priority=0.0) |
virtual void | AdditionalInitializeStep () |
void | AddMRMLDisplayableManagerEvent (int eventId) |
Allow to specify additional events that the DisplayableNode will observe. | |
void | CreateIfPossible () |
vtkMRMLDisplayableManagerGroup * | GetMRMLDisplayableManagerGroup () |
Get associated DisplayableManager group. | |
vtkMRMLNode * | GetMRMLDisplayableNode () |
Get MRML Displayable Node. | |
vtkCallbackCommand * | GetWidgetsCallbackCommand () |
Get vtkWidget callbackCommand. | |
vtkObserverManager * | GetWidgetsObserverManager () const |
Get widget observerManager. | |
virtual void | OnInteractorEvent (int eventid) |
virtual void | OnInteractorStyleEvent (int eventid) |
virtual void | ProcessWidgetsEvents (vtkObject *caller, unsigned long event, void *callData) |
void | RemoveInteractorObservableEvent (int eventid) |
void | RemoveInteractorStyleObservableEvent (int eventid) |
virtual void | RemoveMRMLObservers () |
Remove MRML observers. | |
void | RequestRender () |
void | SetAndObserveMRMLDisplayableNode (vtkMRMLNode *newMRMLDisplayableNode) |
virtual void | SetMRMLDisplayableManagerGroup (vtkMRMLDisplayableManagerGroup *group) |
void | SetMRMLSceneInternal (vtkMRMLScene *newScene) override |
virtual void | SetRenderer (vtkRenderer *newRenderer) |
void | SetUpdateFromMRMLRequested (bool requested) |
vtkMRMLAbstractDisplayableManager () | |
~vtkMRMLAbstractDisplayableManager () override | |
![]() | |
int | EndModify (bool wasModifying) |
virtual bool | EnterMRMLLogicsCallback () const |
virtual bool | EnterMRMLNodesCallback () const |
virtual bool | EnterMRMLSceneCallback () const |
bool | GetDisableModifiedEvent () const |
int | GetInMRMLLogicsCallbackFlag () const |
int | GetInMRMLNodesCallbackFlag () const |
int | GetInMRMLSceneCallbackFlag () const |
vtkCallbackCommand * | GetMRMLLogicsCallbackCommand () |
vtkObserverManager * | GetMRMLLogicsObserverManager () const |
vtkCallbackCommand * | GetMRMLNodesCallbackCommand () |
vtkObserverManager * | GetMRMLNodesObserverManager () const |
vtkCallbackCommand * | GetMRMLSceneCallbackCommand () |
vtkObserverManager * | GetMRMLSceneObserverManager () const |
int | GetPendingModifiedEventCount () const |
int | GetProcessingMRMLSceneEvent () const |
Return the event id currently processed or 0 if any. | |
int | InvokePendingModifiedEvent () |
void | Modified () override |
virtual void | ObserveMRMLScene () |
virtual void | OnMRMLNodeModified (vtkMRMLNode *) |
virtual void | OnMRMLSceneEndImport () |
virtual void | OnMRMLSceneEndRestore () |
virtual void | OnMRMLSceneNew () |
virtual void | OnMRMLSceneStartBatchProcess () |
virtual void | OnMRMLSceneStartImport () |
virtual void | OnMRMLSceneStartRestore () |
virtual void | ProcessMRMLLogicsEvents (vtkObject *caller, unsigned long event, void *callData) |
virtual void | ProcessMRMLSceneEvents (vtkObject *caller, unsigned long event, void *callData) |
virtual void | RegisterNodes () |
void | SetAndObserveMRMLSceneEventsInternal (vtkMRMLScene *newScene, vtkIntArray *events, vtkFloatArray *priorities=nullptr) |
void | SetDisableModifiedEvent (bool onOff) |
void | SetInMRMLLogicsCallbackFlag (int flag) |
void | SetInMRMLNodesCallbackFlag (int flag) |
void | SetInMRMLSceneCallbackFlag (int flag) |
void | SetProcessingMRMLSceneEvent (int event) |
bool | StartModify () |
virtual void | UpdateFromMRMLScene () |
vtkMRMLAbstractLogic () | |
~vtkMRMLAbstractLogic () override | |
Friends | |
class | vtkInternal |
Additional Inherited Members | |
![]() | |
static void | WidgetsCallback (vtkObject *caller, unsigned long eid, void *clientData, void *callData) |
WidgetsCallback is a static function to relay modified events from the vtk widgets. | |
![]() | |
static void | MRMLLogicsCallback (vtkObject *caller, unsigned long eid, void *clientData, void *callData) |
MRMLLogicCallback is a static function to relay modified events from the logics. | |
static void | MRMLNodesCallback (vtkObject *caller, unsigned long eid, void *clientData, void *callData) |
MRMLNodesCallback is a static function to relay modified events from the nodes. | |
static void | MRMLSceneCallback (vtkObject *caller, unsigned long eid, void *clientData, void *callData) |
Displayable manager for showing segmentations in slice (2D) views.
Displays segmentations in slice viewers as labelmaps or contour lines
Definition at line 37 of file vtkMRMLSegmentationsDisplayableManager2D.h.
typedef vtkMRMLAbstractSliceViewDisplayableManager vtkMRMLSegmentationsDisplayableManager2D::Superclass |
Definition at line 43 of file vtkMRMLSegmentationsDisplayableManager2D.h.
|
protected |
|
overrideprotected |
int vtkMRMLSegmentationsDisplayableManager2D::AddCustomSegmentRenderer | ( | const std::string & | segmentationDisplayNodeID, |
const std::string & | segmentID ) |
Specify that a segment is temporarily displayed with a custom renderer, so that this displayable manager should not display it. Only one custom renderer can be added for a specific segment for each segmentation display node.
|
overrideprotectedvirtual |
Initialize the displayable manager based on its associated vtkMRMLSliceNode.
Reimplemented from vtkMRMLAbstractDisplayableManager.
|
virtual |
Reimplemented from vtkMRMLAbstractSliceViewDisplayableManager.
std::string vtkMRMLSegmentationsDisplayableManager2D::GetCustomSegmentRendererSegmentationDisplayNodeID | ( | int | index | ) |
std::string vtkMRMLSegmentationsDisplayableManager2D::GetCustomSegmentRendererSegmentID | ( | int | index | ) |
int vtkMRMLSegmentationsDisplayableManager2D::GetCustomSegmentRendererTag | ( | const std::string & | segmentationDisplayNodeID, |
const std::string & | segmentID ) |
int vtkMRMLSegmentationsDisplayableManager2D::GetCustomSegmentRendererTag | ( | int | index | ) |
|
override |
Assemble and return info string to display in Data probe for a given viewer XYZ position.
int vtkMRMLSegmentationsDisplayableManager2D::GetNumberOfCustomSegmentsRenderers | ( | ) |
Get information on custom segment renderers. Intended for troubleshooting.
|
virtual |
Get list of segments visible at selected display position. segmentValues is optional, if not nullptr then it returns value for each segment for fractional representations
bool vtkMRMLSegmentationsDisplayableManager2D::HasCustomSegmentRenderer | ( | const std::string & | segmentationDisplayNodeID, |
const std::string & | segmentID ) |
|
virtual |
Reimplemented from vtkMRMLAbstractSliceViewDisplayableManager.
|
static |
|
static |
|
overrideprotectedvirtual |
If vtkMRMLScene::EndBatchProcessEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event Internally calls UpdateFromMRMLScene. Can be reimplemented to change the default behavior.
Reimplemented from vtkMRMLAbstractLogic.
|
overrideprotectedvirtual |
If vtkMRMLScene::EndCloseEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event
Reimplemented from vtkMRMLAbstractLogic.
|
overrideprotectedvirtual |
If vtkMRMLScene::NodeAddedEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event
Reimplemented from vtkMRMLAbstractLogic.
|
overrideprotectedvirtual |
If vtkMRMLScene::NodeRemovedEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event
Reimplemented from vtkMRMLAbstractLogic.
|
overrideprotectedvirtual |
If vtkMRMLScene::StartCloseEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event
Reimplemented from vtkMRMLAbstractLogic.
|
override |
|
overrideprotectedvirtual |
Receives all the events fired by the nodes. To listen to a node, you can add an observer using GetMRMLNodesCallbackCommand() or use the utility macros vtk[SetAndObserve|Observe]MRMLNode[Event]Macro ProcessMRMLNodesEvents calls OnMRMLNodeModified when event is vtkCommand::ModifiedEvent.
Reimplemented from vtkMRMLAbstractDisplayableManager.
bool vtkMRMLSegmentationsDisplayableManager2D::RemoveCustomSegmentRenderer | ( | int | tag | ) |
Remove custom renderer that was added using AddCustomSegmentRenderer()
|
static |
|
overrideprotectedvirtual |
Called anytime a scene is not set to the logic anymore (e.g. a new or no scene is set) Reimplement the method to delete all the scene specific information such as a node IDs, pointers...
Reimplemented from vtkMRMLAbstractLogic.
|
overrideprotectedvirtual |
Update Actors based on transforms in the scene.
Reimplemented from vtkMRMLAbstractDisplayableManager.
|
friend |
Definition at line 109 of file vtkMRMLSegmentationsDisplayableManager2D.h.