More and more use cases are defined, where a new (possibly empty) segmentation is needed without using the (MultiLabel-)Segmentation plugins / tools.
In order to guarantee a consistent way of generating segmentation data and segmentation nodes, I propose to gather the different methods of creating a segmentation and put them in a separate file.
- QmitkNewSegmentationDialog is used in
QmitkCreateMultiLabelSegmentationAction, QmitkMultiLabelSegmentationViewand QmitkSegmentationViewto generate a new segmentation on user click
- QmitkLabelSetWidget to rename an existing segmentation
In the MultiLabel classes a plain new DataNode and LabelSetImage are initialized, filled with required information and added to the data storage. In the simple Segmentation class mitkTool is used to create a new empty segmentation.
Here, much more information (properties) are generated by default and a different way of segmentation-initialization is used.
However, I can't seem to find a reason for the functions CreateEmptySegmentationNode and CreateSegmentationNode being put into the mitkTool-class.
So I'd like to create a new file that contains the Create... functions and clean the process of creating new segmentations (including checking relevant properties).
Edit: The mitk::LabelSetImageHelper has been added with D601.