NifTK
16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
|
Public Member Functions | |
BaseController (IBaseView *view) | |
Constructs a BaseController object. More... | |
virtual | ~BaseController () |
Destructs the BaseController object. More... | |
ImageOrientation | GetOrientation () const |
Returns the orientation of the selected render window. Returns IMAGE_ORIENTATION_UNKNOWN if no window is selected or the selected window is a 3D window. More... | |
int | GetSliceIndex () const |
Returns the index of the displayed slice in the currently selected window. Returns -1 if no window is selected or the selected window is a 3D window. More... | |
mitk::Point3D | GetSelectedPosition () const |
Returns the selected position in the current editor (render window part). The selected position is the voxel at the intersection of the crosshair planes. More... | |
virtual void | SetupGUI (QWidget *parent) |
Sets up the GUI. This function has to be called from the CreateQtPartControl function of the view. More... | |
virtual void | OnViewGetsActivated () |
Called when the BlueBerry view that hosts the GUI for this controller gets activated. More... | |
virtual void | OnViewGetsDeactivated () |
Called when the BlueBerry view that hosts the GUI for this controller gets deactivated. More... | |
virtual void | OnViewGetsVisible () |
Called when the BlueBerry view that hosts the GUI for this controller becomes visible. More... | |
virtual void | OnViewGetsHidden () |
Called when the BlueBerry view that hosts the GUI for this controller becomes hidden. More... | |
Protected Member Functions | |
mitk::DataStorage * | GetDataStorage () const |
void | RequestRenderWindowUpdate () const |
QList< mitk::DataNode::Pointer > | GetDataManagerSelection () const |
mitk::SliceNavigationController * | GetSliceNavigationController () const |
virtual void | OnSelectedSliceChanged (niftk::ImageOrientation orientation, int sliceIndex) |
Called when the selected slice changes. This happens when selected window changes in the current editor (render window part) or when the focus is on a 2D render window in the current editor and the selected slice changes, either through interaction (e.g. by scrolling with the mouse wheel) or through an API call. More... | |
virtual BaseGUI * | CreateGUI (QWidget *parent)=0 |
Creates the widget that holds the GUI components of the view. This function is called from CreateQtPartControl. Derived classes should provide their implementation that returns an object whose class derives from niftk::BaseGUI. More... | |
BaseGUI * | GetGUI () const |
Gets the widget that holds the GUI components of the view. More... | |
IBaseView * | GetView () const |
Gets the segmentor BlueBerry view. More... | |
virtual void | OnFocusChanged () |
Called when the window focus changes, and tracks the current mitk::BaseRenderer*. More... | |
virtual mitk::BaseRenderer * | GetFocused2DRenderer () const |
Returns the currently focused renderer, as this class is tracking the focus changes. More... | |
virtual void | OnNodeAdded (const mitk::DataNode *node) |
Called when a data node is added to the data storage. Empty implementation. Derived classes can override it. More... | |
virtual void | OnNodeChanged (const mitk::DataNode *node) |
Called when a data node in the data storage has changed. Empty implementation. Derived classes can override it. More... | |
virtual void | OnNodeRemoved (const mitk::DataNode *node) |
Called when a data node has been removed from the data storage. Empty implementation. Derived classes can override it. More... | |
virtual void | OnNodeDeleted (const mitk::DataNode *node) |
Called when a data node has been deleted that has previously been in the data storage. Empty implementation. Derived classes can override it. More... | |
virtual void | OnNodeVisibilityChanged (const mitk::DataNode *node, const mitk::BaseRenderer *renderer) |
Called when the visibility of a data node in the data storage has changed. The renderer is nullptr if the global visibility has changed. Empty implementation. Derived classes can override it. More... | |
void | WaitCursorOn () |
Convenient method to set and reset a wait cursor ("hourglass") More... | |
void | WaitCursorOff () |
Convenient method to restore the standard cursor. More... | |
void | BusyCursorOn () |
Convenient method to set and reset a busy cursor. More... | |
void | BusyCursorOff () |
Convenient method to restore the standard cursor. More... | |
niftk::BaseController::BaseController | ( | IBaseView * | view | ) |
Constructs a BaseController object.
|
virtual |
Destructs the BaseController object.
|
protected |
Convenient method to restore the standard cursor.
|
protected |
Convenient method to set and reset a busy cursor.
|
protectedpure virtual |
Creates the widget that holds the GUI components of the view. This function is called from CreateQtPartControl. Derived classes should provide their implementation that returns an object whose class derives from niftk::BaseGUI.
Implemented in niftk::GeneralSegmentorController, and niftk::MorphologicalSegmentorController.
|
protected |
Returns the current selection made in the datamanager bundle or an empty list if there is no selection or if it is empty.
|
protected |
|
protectedvirtual |
Returns the currently focused renderer, as this class is tracking the focus changes.
|
protected |
Gets the widget that holds the GUI components of the view.
ImageOrientation niftk::BaseController::GetOrientation | ( | ) | const |
Returns the orientation of the selected render window. Returns IMAGE_ORIENTATION_UNKNOWN if no window is selected or the selected window is a 3D window.
mitk::Point3D niftk::BaseController::GetSelectedPosition | ( | ) | const |
Returns the selected position in the current editor (render window part). The selected position is the voxel at the intersection of the crosshair planes.
int niftk::BaseController::GetSliceIndex | ( | ) | const |
Returns the index of the displayed slice in the currently selected window. Returns -1 if no window is selected or the selected window is a 3D window.
|
protected |
|
protected |
Gets the segmentor BlueBerry view.
|
protectedvirtual |
Called when the window focus changes, and tracks the current mitk::BaseRenderer*.
|
protectedvirtual |
Called when a data node is added to the data storage. Empty implementation. Derived classes can override it.
|
protectedvirtual |
Called when a data node in the data storage has changed. Empty implementation. Derived classes can override it.
|
protectedvirtual |
Called when a data node has been deleted that has previously been in the data storage. Empty implementation. Derived classes can override it.
|
protectedvirtual |
Called when a data node has been removed from the data storage. Empty implementation. Derived classes can override it.
Reimplemented in niftk::MorphologicalSegmentorController.
|
protectedvirtual |
Called when the visibility of a data node in the data storage has changed. The renderer is nullptr if the global visibility has changed. Empty implementation. Derived classes can override it.
Reimplemented in niftk::GeneralSegmentorController, and niftk::MorphologicalSegmentorController.
|
protectedvirtual |
Called when the selected slice changes. This happens when selected window changes in the current editor (render window part) or when the focus is on a 2D render window in the current editor and the selected slice changes, either through interaction (e.g. by scrolling with the mouse wheel) or through an API call.
orientation | The orientation of the 2D window or IMAGE_ORIENTATION_UNKNOWN if a 3D window is selected. |
sliceIndex | The index of the current slice or -1 if a 3D window is selected. |
Reimplemented in niftk::GeneralSegmentorController.
|
virtual |
Called when the BlueBerry view that hosts the GUI for this controller gets activated.
Reimplemented in niftk::BaseSegmentorController.
|
virtual |
Called when the BlueBerry view that hosts the GUI for this controller gets deactivated.
|
virtual |
Called when the BlueBerry view that hosts the GUI for this controller becomes hidden.
|
virtual |
Called when the BlueBerry view that hosts the GUI for this controller becomes visible.
|
protected |
|
virtual |
Sets up the GUI. This function has to be called from the CreateQtPartControl function of the view.
Reimplemented in niftk::GeneralSegmentorController, niftk::BaseSegmentorController, and niftk::MorphologicalSegmentorController.
|
protected |
Convenient method to restore the standard cursor.
|
protected |
Convenient method to set and reset a wait cursor ("hourglass")