Difference between revisions of "Documentation/4.5/Modules/SubjectHierarchy"
(Added info about implementing new plugins) |
m (Text replacement - "slicerWiki/index.php" to "wiki") |
||
Line 105: | Line 105: | ||
{{documentation/{{documentation/version}}/module-section|References}} | {{documentation/{{documentation/version}}/module-section|References}} | ||
* Additional information on [[Documentation/Labs/SubjectHierarchy|Subject hierarchy labs page]] | * Additional information on [[Documentation/Labs/SubjectHierarchy|Subject hierarchy labs page]] | ||
− | * Manual editing of segmentations can be done in the [http://www.slicer.org/ | + | * Manual editing of segmentations can be done in the [http://www.slicer.org/wiki/Documentation/Nightly/Modules/Segmentations Segmentations module] |
<!-- ---------------------------- --> | <!-- ---------------------------- --> |
Latest revision as of 17:34, 21 November 2019
Home < Documentation < 4.5 < Modules < SubjectHierarchy
For the latest Slicer documentation, visit the read-the-docs. |
Introduction and Acknowledgements
| |||||||
|
Module Description
The SubjectHierarchy module acts as a central data-organizing point in Slicer. All DICOM data is automatically added to the tree. Non-DICOM data can be parsed if loaded from a local directory structure, or has to be manually added (non-SH nodes are the ones on the bottom with no icons). Subject hierarchy nodes provide features for the underlying data nodes, including cloning, bulk transforming, bulk show/hide, type-specific features, and basic node operations such as delete or rename. Additional plugins can provide other type-specific features and general operations, see Subject hierarchy labs page
Use Cases
Tutorials
Panels and their use
Contains all the objects in the Subject hierarchy in a tree representation
How to
|
Similar Modules
References
- Additional information on Subject hierarchy labs page
- Manual editing of segmentations can be done in the Segmentations module
Information for Developers
- Important note: Instead of the usual New function, vtkMRMLSubjectHierarchyNode::CreateSubjectHierarchyNode should be used for instantiating an SH node. The reason is that when SH auto creation is turned on, then there is no need to create an SH node, but only to set up its properties (parent, level, name, association), but when it is turned off, then creating an SH node is necessary if the module relies on it. The CreateSubjectHierarchyNode function takes care of this, and only creates a node if it doesn't exist, otherwise just updates its properties.
- Implementing new plugins: Plugins are the real power of subject hierarchy, as they provide support for data node types, and add functionality to the context menu items.
To create a C++ plugin, implement a child class of qSlicerSubjectHierarchyAbstractPlugin, for python plugin see below. Many examples can be found in Slicer core and in the SlicerRT extension, look for folders named SubjectHierarchyPlugins.- Role plugins: add support for new data node types
- Defines: ownership, icon, tooltip, edit properties, help text (in the yellow question mark popup), visibility icon, set/get display visibility, displayed node name (if different than name of the node object)
- Existing plugins in Slicer core: Markups, Models, SceneViews, Charts, Folder, Tables, Transforms, LabelMaps, Volumes
- Function plugins: add feature in right-click context menu for certain types of nodes
- Defines: list of contect menu actions for nodes and the scene, types of nodes for which the action shows up, functions handling the defined action
- Existing plugins in Slicer core: CloneNode, ParseLocalData, Register, Segment, DICOM
- Writing plugins in python:
- Child class of AbstractScriptedSubjectHierarchyPlugin which is a python adaptor of the C++ qSlicerSubjectHierarchyScriptedPlugin class
- Example: https://subversion.assembla.com/svn/slicerrt/trunk/VolumeClip/src/SubjectHierarchyPlugins
- Role plugins: add support for new data node types
- Glossary of all the used terms in SlicerRT