Medical Imaging Interaction Toolkit  2025.12.02
Medical Imaging Interaction Toolkit
mitkMaskAndCutRoiImageFilter.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 #ifndef mitkMaskAndCutRoiImageFilter_h
13 #define mitkMaskAndCutRoiImageFilter_h
14 
16 #include "mitkImageToImageFilter.h"
17 
18 #include "itkRegionOfInterestImageFilter.h"
20 #include "mitkBoundingObject.h"
21 #include "mitkDataNode.h"
22 #include "mitkMaskImageFilter.h"
23 
24 namespace mitk
25 {
36  {
37  typedef itk::Image<short, 3> ItkImageType;
38  typedef itk::Image<unsigned char, 3> ItkMaskType;
39  typedef itk::ImageRegion<3> RegionType;
40  typedef itk::RegionOfInterestImageFilter<ItkImageType, ItkImageType> ROIFilterType;
41 
42  public:
44  itkFactorylessNewMacro(Self);
45  itkCloneMacro(Self);
46 
48  // void SetRegionOfInterest(Image::Pointer image);
49  // void SetRegionOfInterest(BoundingObject::Pointer boundingObject);
50  // void SetRegionOfInterestByNode(mitk::DataNode::Pointer node);
51 
52  // temporary fix for bug #
54 
55  protected:
58 
59  void GenerateData() override;
60 
61  ROIFilterType::Pointer m_RoiFilter;
64 
65  // needed for temporary fix
67 
68  }; // class
69 
70 } // namespace
71 
72 #endif
#define MITKALGORITHMSEXT_EXPORT
Base of all data objects.
Definition: mitkBaseData.h:44
Superclass of all classes generating Images (instances of class Image) as output.
Superclass of all classes having one or more Images as input and generating Images as output.
Cuts a region of interest (ROI) out of an image.
mitk::MaskImageFilter::Pointer m_MaskFilter
mitk::AutoCropImageFilter::Pointer m_CropFilter
mitkClassMacro(MaskAndCutRoiImageFilter, ImageToImageFilter)
mitk::Image::Pointer GetOutput()
void SetRegionOfInterest(mitk::BaseData *roi)
Find image slices visible on a given plane.