13 #ifndef mitkImageLiveWireContourModelFilter_h
14 #define mitkImageLiveWireContourModelFilter_h
52 itkFactorylessNewMacro(Self);
76 itkSetMacro(UseDynamicCostMap,
bool);
77 itkGetMacro(UseDynamicCostMap,
bool);
97 using Superclass::SetInput;
111 void SetUseCostFunction(
bool doUseCostFunction) { m_ShortestPathFilter->SetUseCostFunction(doUseCostFunction); };
147 template <
typename TPixel,
unsigned int VImageDimension>
150 template <
typename TPixel,
unsigned int VImageDimension>
#define MITKSEGMENTATION_EXPORT
Cost function for LiveWire purposes. Specific features are considered to calculate cumulative costs o...
Superclass of all classes generating ContourModels.
ContourModel is a structure of linked vertices defining a contour in 3D space. The vertices are store...
Calculates a LiveWire contour between two points in an image.
mitk::Point3D m_StartPoint
start point in worldcoordinates
void CreateDynamicCostMapByITK(const itk::Image< TPixel, VImageDimension > *inputImage, mitk::ContourModel *path=nullptr)
virtual void DumpMaskImage()
void RemoveRepulsivePoint(const itk::Index< 2 > &idx)
Remove a single repulsive point from the cost function.
CostFunctionType::Pointer m_CostFunction
The cost function to compute costs between two pixels.
ImageLiveWireContourModelFilter()
const InputType * GetInput(void)
mitk::Point3D m_EndPointInIndex
End point in index.
~ImageLiveWireContourModelFilter() override
InternalImageType::Pointer m_InternalImage
mitkClassMacro(ImageLiveWireContourModelFilter, ContourModelSource)
void ItkPreProcessImage(const itk::Image< TPixel, VImageDimension > *inputImage)
const InputType * GetInput(unsigned int idx)
virtual void SetInput(const InputType *input)
void SetRepulsivePoints(const ShortestPathType &points)
Set a vector with repulsive points to use in the cost function.
mitk::Point3D m_EndPoint
end point in woorldcoordinates
OutputType::Pointer OutputTypePointer
virtual void SetInput(unsigned int idx, const InputType *input)
ShortestPathImageFilterType::Pointer m_ShortestPathFilter
Shortest path filter according to cost function m_CostFunction.
void ClearRepulsivePoints()
Clear all repulsive points used in the cost function.
void AddRepulsivePoint(const itk::Index< 2 > &idx)
Add a single repulsive point to the cost function.
std::vector< itk::Index< 2 > > ShortestPathType
mitk::Point3D m_StartPointInIndex
Start point in index.
void GenerateData() override
bool CreateDynamicCostMap(mitk::ContourModel *path=nullptr)
Create dynamic cost transfer map - on the fly training.
itk::ShortestPathImageFilter< InternalImageType, InternalImageType > ShortestPathImageFilterType
itk::ShortestPathCostFunctionLiveWire< InternalImageType > CostFunctionType
virtual OutputType * GetOutput()
void SetUseCostFunction(bool doUseCostFunction)
bool m_UseDynamicCostMap
Flag to use a dynamic cost map or not.
itk::Image< float, 2 > InternalImageType
void GenerateOutputInformation() override
Image class for storing images.
Find image slices visible on a given plane.