Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitkGrowCutSegmentationFilter.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef mitkGrowCutSegmentationFilter_h
14 #define mitkGrowCutSegmentationFilter_h
15 
16 #include <itkImage.h>
17 #include <mitkITKImageImport.h>
18 #include <mitkImage.h>
19 #include <mitkImageToImageFilter.h>
21 
22 namespace mitk
23 {
34  {
35  public:
37  itkFactorylessNewMacro(Self);
38  itkCloneMacro(Self);
39 
44  void SetSeedImage(itk::Image<mitk::Label::PixelType, 3>::Pointer itkSeedImage) { m_itkSeedImage = itkSeedImage; }
45 
50  void SetDistancePenalty(double distancePenalty) { m_DistancePenalty = distancePenalty; }
51 
52  protected:
55  void GenerateData() override;
56 
57  private:
58  itk::Image<mitk::Label::PixelType, 3>::Pointer m_itkSeedImage = nullptr;
59  double m_DistancePenalty;
60 
61  }; // class
62 
63 } // namespace mitk
64 
65 #endif
#define MITKSEGMENTATION_EXPORT
A filter that performs a growcut image segmentation.
mitkClassMacro(GrowCutSegmentationFilter, ImageToImageFilter)
void SetDistancePenalty(double distancePenalty)
Sets the distance penalty factor used in the GrowCut algorithm.
void SetSeedImage(itk::Image< mitk::Label::PixelType, 3 >::Pointer itkSeedImage)
Sets the seed image that contains the initial label assignments for GrowCut.
Superclass of all classes having one or more Images as input and generating Images as output.
Find image slices visible on a given plane.