![]() |
Slicer 5.9
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
|
Manage display nodes with polydata in 3D views. More...
#include <Libs/MRML/DisplayableManager/vtkMRMLModelDisplayableManager.h>
Public Types | |
typedef vtkMRMLAbstractThreeDViewDisplayableManager | Superclass |
![]() | |
typedef vtkMRMLAbstractDisplayableManager | Superclass |
![]() | |
typedef vtkMRMLAbstractLogic | Superclass |
![]() | |
typedef vtkObject | Superclass |
typedef void(vtkMRMLAbstractLogic::* | TaskFunctionPointer) (void *clientdata) |
Public Member Functions | |
vtkProp3D * | GetActorByID (const char *id) |
Return the current model actor corresponding to a give MRML ID. | |
vtkCellPicker * | GetCellPicker () |
Get cell picker. | |
virtual const char * | GetClassName () |
const char * | GetIDByActor (vtkProp3D *actor) |
Return the current node ID corresponding to a given vtkProp3D. | |
vtkIdType | GetPickedCellID () |
Get the picked cell id, returns -1 if no pick. | |
const char * | GetPickedNodeID () override |
Get the MRML ID of the picked node, returns empty string if no pick. | |
vtkIdType | GetPickedPointID () |
Get the picked point id, returns -1 if no pick. | |
double * | GetPickedRAS () VTK_SIZEHINT(3) |
Get the picked RAS point, returns 0,0,0 if no pick. | |
double | GetPickTolerance () |
Get tolerance for Pick() method. It will call vtkCellPicker.GetTolerance() | |
vtkPointPicker * | GetPointPicker () |
Get point picker. | |
vtkPropPicker * | GetPropPicker () |
Get property picker. | |
vtkWorldPointPicker * | GetWorldPointPicker () |
Get world point picker. | |
virtual int | IsA (const char *type) |
bool | IsModelDisplayable (vtkMRMLDisplayableNode *node) const |
Return true if the node can be represented as a model. | |
bool | IsModelDisplayable (vtkMRMLDisplayNode *node) const |
Return true if the display node is a model. | |
int | Pick (int x, int y) |
int | Pick3D (double ras[3]) override |
void | PrintSelf (ostream &os, vtkIndent indent) override |
void | SetPickedCellID (vtkIdType newCellID) |
Set the picked cell id, returns -1 if no pick. | |
void | SetPickedPointID (vtkIdType newPointID) |
Set the picked point id, returns -1 if no pick. | |
void | SetPickedRAS (double *newPickedRAS) |
Set the picked RAS point, returns 0,0,0 if no pick. | |
void | SetPickTolerance (double tolerance) |
Set tolerance for Pick() method. It will call vtkCellPicker.SetTolerance() | |
![]() | |
vtkMRMLViewNode * | GetMRMLViewNode () |
Get MRML ViewNode. | |
virtual int | Pick3D (double vtkNotUsed(ras)[3]) |
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 bool | IsCellScalarsActive (vtkMRMLDisplayNode *displayNode, vtkMRMLModelNode *model=nullptr) |
static int | IsTypeOf (const char *type) |
static vtkMRMLModelDisplayableManager * | New () |
static vtkMRMLModelDisplayableManager * | SafeDownCast (vtkObject *o) |
![]() | |
static double | GetViewScaleFactorAtPosition (vtkRenderer *renderer, double positionWorld[3], vtkMRMLInteractionEventData *interactionEventData=nullptr) |
Get the view scale factor at a given position in world coordinates for a 3D view renderer. | |
static int | IsTypeOf (const char *type) |
static vtkMRMLAbstractThreeDViewDisplayableManager * | New () |
static vtkMRMLAbstractThreeDViewDisplayableManager * | 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) |
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) |
Manage display nodes with polydata in 3D views.
Any display node in the scene that contains a valid output polydata is represented into the view renderer using configured synchronized vtkActors and vtkMappers. Note that the display nodes must be of type vtkMRMLModelDisplayNode (to have an output polydata) but the displayable nodes don't necessarily have to be of type vtkMRMLModelNode.
Definition at line 47 of file vtkMRMLModelDisplayableManager.h.
Definition at line 52 of file vtkMRMLModelDisplayableManager.h.
|
protected |
|
overrideprotected |
|
overrideprotectedvirtual |
Subclass can overload this method to specify under which InteractionNode modes this Displayable Manager InteractorStyle events. By default events only arrive when in Place mode (good for markups) but if you want a continuous read out of, for example, slice positions while the mouse moves set this to include Place and ViewTransform
Reimplemented from vtkMRMLAbstractDisplayableManager.
|
protected |
|
protected |
vtkProp3D * vtkMRMLModelDisplayableManager::GetActorByID | ( | const char * | id | ) |
Return the current model actor corresponding to a give MRML ID.
vtkCellPicker * vtkMRMLModelDisplayableManager::GetCellPicker | ( | ) |
Get cell picker.
|
virtual |
Reimplemented from vtkMRMLAbstractThreeDViewDisplayableManager.
|
protected |
Returns not null if modified.
|
protected |
const char * vtkMRMLModelDisplayableManager::GetIDByActor | ( | vtkProp3D * | actor | ) |
Return the current node ID corresponding to a given vtkProp3D.
vtkIdType vtkMRMLModelDisplayableManager::GetPickedCellID | ( | ) |
Get the picked cell id, returns -1 if no pick.
|
overridevirtual |
Get the MRML ID of the picked node, returns empty string if no pick.
Reimplemented from vtkMRMLAbstractThreeDViewDisplayableManager.
vtkIdType vtkMRMLModelDisplayableManager::GetPickedPointID | ( | ) |
Get the picked point id, returns -1 if no pick.
double * vtkMRMLModelDisplayableManager::GetPickedRAS | ( | ) |
Get the picked RAS point, returns 0,0,0 if no pick.
double vtkMRMLModelDisplayableManager::GetPickTolerance | ( | ) |
Get tolerance for Pick() method. It will call vtkCellPicker.GetTolerance()
vtkPointPicker * vtkMRMLModelDisplayableManager::GetPointPicker | ( | ) |
Get point picker.
vtkPropPicker * vtkMRMLModelDisplayableManager::GetPropPicker | ( | ) |
Get property picker.
vtkWorldPointPicker * vtkMRMLModelDisplayableManager::GetWorldPointPicker | ( | ) |
Get world point picker.
|
virtual |
Reimplemented from vtkMRMLAbstractThreeDViewDisplayableManager.
|
static |
Helper function for determining what type of scalar is active.
bool vtkMRMLModelDisplayableManager::IsModelDisplayable | ( | vtkMRMLDisplayableNode * | node | ) | const |
Return true if the node can be represented as a model.
bool vtkMRMLModelDisplayableManager::IsModelDisplayable | ( | vtkMRMLDisplayNode * | node | ) | const |
Return true if the display node is a model.
|
static |
|
static |
|
overrideprotectedvirtual |
Called after interactor style event specified using AddInteractorStyleObservableEvent are invoked.
Reimplemented from vtkMRMLAbstractDisplayableManager.
|
protected |
Returns true if something visible in modelNode has changed and would require a refresh.
|
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.
int vtkMRMLModelDisplayableManager::Pick | ( | int | x, |
int | y ) |
Convert an x/y location to a MRML node, 3D RAS point, point ID, cell ID, as appropriate depending what's found under the xy.
|
override |
Convert a RAS location to a MRML node, point ID, cell ID, as appropriate depending what's found under the position.
|
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.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
overrideprotectedvirtual |
Remove MRML observers.
Reimplemented from vtkMRMLAbstractDisplayableManager.
|
static |
|
protected |
void vtkMRMLModelDisplayableManager::SetPickedCellID | ( | vtkIdType | newCellID | ) |
Set the picked cell id, returns -1 if no pick.
void vtkMRMLModelDisplayableManager::SetPickedPointID | ( | vtkIdType | newPointID | ) |
Set the picked point id, returns -1 if no pick.
void vtkMRMLModelDisplayableManager::SetPickedRAS | ( | double * | newPickedRAS | ) |
Set the picked RAS point, returns 0,0,0 if no pick.
void vtkMRMLModelDisplayableManager::SetPickTolerance | ( | double | tolerance | ) |
Set tolerance for Pick() method. It will call vtkCellPicker.SetTolerance()
|
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.
|
protected |
|
protected |
|
overrideprotectedvirtual |
Updates Actors based on models in the scene.
Reimplemented from vtkMRMLAbstractDisplayableManager.
|
overrideprotectedvirtual |
Called every time the scene has been significantly changed. If the scene BatchProcessState events are observed (in SetMRMLSceneInternal() ), UpdateFromMRMLScene is called after each batch process (Close, Import, Restore...). It is also being called by default when a new scene is set (SetMRMLScene).
Reimplemented from vtkMRMLAbstractLogic.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |