15 #ifndef niftkMorphologicalSegmentorPipelineManager_h
16 #define niftkMorphologicalSegmentorPipelineManager_h
18 #include "niftkMIDASExports.h"
20 #include <itkLightObject.h>
22 #include <mitkDataStorage.h>
23 #include <mitkImage.h>
24 #include <mitkToolManager.h>
65 void SetDataStorage(
mitk::DataStorage::Pointer dataStorage);
68 mitk::DataStorage::Pointer GetDataStorage() const;
71 void SetToolManager(
mitk::ToolManager::Pointer toolManager);
74 mitk::ToolManager::Pointer GetToolManager() const;
84 void OnThresholdingValuesChanged(
double lowerThreshold,
double upperThreshold,
int axialSliceNumber);
90 void OnErosionsValuesChanged(
double upperThreshold,
int numberOfErosions);
97 void OnDilationsValuesChanged(
double lowerPercentage,
double upperPercentage,
int numberOfDilations);
102 void OnRethresholdingValuesChanged(
int boxSize);
107 void OnTabChanged(
int tabIndex);
110 bool HasSegmentationNode() const;
113 mitk::
Image::ConstPointer GetReferenceImage() const;
116 mitk::
Image::Pointer GetWorkingImage(
unsigned int dataIndex) const;
119 mitk::DataNode::Pointer GetSegmentationNode() const;
122 mitk::
Image::Pointer GetSegmentationImage() const;
128 virtual
bool IsNodeASegmentationImage(const
mitk::DataNode::Pointer node) const;
131 virtual
bool IsNodeAWorkingImage(const
mitk::DataNode::Pointer node) const;
134 virtual
bool CanStartSegmentationForBinaryNode(const
mitk::DataNode::Pointer node) const;
137 virtual
std::vector<
mitk::DataNode*> GetWorkingDataFromSegmentationNode(const
mitk::DataNode::Pointer node) const;
140 virtual
mitk::DataNode* GetSegmentationNodeFromWorkingData(const
mitk::DataNode::Pointer node) const;
143 void SetSegmentationNodePropsFromReferenceImage();
146 void UpdateSegmentation();
149 void FinalizeSegmentation();
152 void ClearWorkingData();
155 void RemoveWorkingData();
158 void DestroyPipeline(
mitk::
Image::Pointer segmentation);
163 virtual ~MorphologicalSegmentorPipelineManager();
165 MorphologicalSegmentorPipelineManager(const MorphologicalSegmentorPipelineManager&);
166 MorphologicalSegmentorPipelineManager& operator=(const MorphologicalSegmentorPipelineManager&);
171 template<typename TPixel,
unsigned int VImageDimension>
172 void InvokeITKPipeline(
173 const
itk::
Image<TPixel, VImageDimension>* referenceImage,
174 const
std::vector<typename
itk::
Image<
unsigned char, VImageDimension>::ConstPointer>& workingImages,
176 const
std::vector<
int>& editingRegion,
177 const
std::vector<
bool>& editingFlags,
183 template<typename TPixel,
unsigned int VImageDimension>
184 void FinalizeITKPipeline(
185 const
itk::
Image<TPixel, VImageDimension>* referenceImage,
190 template<typename TPixel,
unsigned int VImageDimension>
192 itk::
Image<TPixel, VImageDimension>* itkImage
199 mitk::DataStorage::Pointer m_DataStorage;
202 mitk::ToolManager::Pointer m_ToolManager;
Definition: niftkMeshSmoother.cxx:19
const GLfloat * params
Definition: glew.h:1515
Definition: ReceptorMemberCommandTest.cxx:25
Abstract interface to plug ITK pipeline into MITK framework to represent the MIDAS Morphological Segm...
Definition: MorphologicalSegmentorPipelineInterface.h:26
Definition: niftkITKAffineResampleImage.cxx:74
static const std::string SEGMENTATION_OF_LAST_STAGE_NAME
The output of the previous stage of the segmentation pipeline.
Definition: niftkMorphologicalSegmentorPipelineManager.h:58
Class to contain all the ITK/MITK logic for the MIDAS Morphological Segmentor pipeline, to separate from MorphologicalSegmentationView to make unit testing easier.
Definition: niftkMorphologicalSegmentorPipelineManager.h:49
The parameters for the MorphologicalSegmentorPipeline, which closely resemble the GUI controls...
Definition: MorphologicalSegmentorPipelineParams.h:25
static const std::string PROPERTY_MIDAS_MORPH_SEGMENTATION_FINISHED
A static string, (to avoid code duplication), to hold the name of the property that determines if a m...
Definition: niftkMorphologicalSegmentorPipelineManager.h:55
Simultaneous itk::Image and itk::Array (and hence vnl_vector) class.
Definition: niftkExceptionObject.h:21
GLsizei const GLcharARB ** string
Definition: glew.h:5194