Medical Imaging Interaction Toolkit  2024.12.99-0da743f6
Medical Imaging Interaction Toolkit
mitkHeightFieldSurfaceClipImageFilter.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 mitkHeightFieldSurfaceClipImageFilter_h
14 #define mitkHeightFieldSurfaceClipImageFilter_h
15 
17 #include "mitkCommon.h"
18 #include "mitkGeometry3D.h"
19 #include "mitkImageTimeSelector.h"
20 #include "mitkImageToImageFilter.h"
21 #include "mitkSurface.h"
22 
23 namespace itk
24 {
25  template <class TPixel, unsigned int VImageDimension>
26  class ITK_EXPORT Image;
27 }
28 
29 namespace mitk
30 {
44  {
45  public:
46  typedef std::vector<mitk::Surface *> ClippingPlaneList;
47 
49 
50  itkFactorylessNewMacro(Self);
51 
52  itkCloneMacro(Self);
53 
55  void SetClippingSurface(Surface *clippingSurface);
56 
58  void SetClippingSurfaces(ClippingPlaneList planeList);
59 
61  const Surface *GetClippingSurface() const;
62 
63  enum
64  {
65  CLIPPING_MODE_CONSTANT = 0,
67  CLIPPING_MODE_MULTIPLANE
68  };
69 
72  void SetClippingMode(int mode);
73 
76  int GetClippingMode();
77 
80  void SetClippingModeToConstant();
81 
84  void SetClippingModeToMultiplyByFactor();
85 
86  void SetClippingModeToMultiPlaneValue();
87 
89  itkSetMacro(ClippingConstant, ScalarType);
90 
92  itkGetConstMacro(ClippingConstant, ScalarType);
93 
95  itkSetMacro(MultiplicationFactor, ScalarType);
96 
98  itkGetConstMacro(MultiplicationFactor, ScalarType);
99 
101  itkSetMacro(HeightFieldResolutionX, unsigned int);
102 
104  itkGetConstMacro(HeightFieldResolutionX, unsigned int);
105 
107  itkSetMacro(HeightFieldResolutionY, unsigned int);
108 
110  itkGetConstMacro(HeightFieldResolutionY, unsigned int);
111 
112  protected:
114 
116 
117  void GenerateInputRequestedRegion() override;
118 
119  void GenerateOutputInformation() override;
120 
121  void GenerateData() override;
122 
123  template <typename TPixel, unsigned int VImageDimension>
124  void _InternalComputeClippedImage(itk::Image<TPixel, VImageDimension> *itkImage,
125  HeightFieldSurfaceClipImageFilter *clipImageFilter,
126  vtkPolyData *clippingPolyData,
127  AffineTransform3D *imageToPlaneTransform);
128 
131 
133 
137 
140 
141  double m_MaxHeight;
142 
145  };
146 
147 } // namespace mitk
148 
149 #endif
mitk::HeightFieldSurfaceClipImageFilter::ClippingPlaneList
std::vector< mitk::Surface * > ClippingPlaneList
Definition: mitkHeightFieldSurfaceClipImageFilter.h:46
mitkImageToImageFilter.h
mitkImageTimeSelector.h
mitk::HeightFieldSurfaceClipImageFilter::m_ClippingConstant
ScalarType m_ClippingConstant
Definition: mitkHeightFieldSurfaceClipImageFilter.h:134
mitk::HeightFieldSurfaceClipImageFilter::m_HeightFieldResolutionY
unsigned int m_HeightFieldResolutionY
Definition: mitkHeightFieldSurfaceClipImageFilter.h:139
itk::SmartPointer< Self >
MitkAlgorithmsExtExports.h
mitkGeometry3D.h
mitk::HeightFieldSurfaceClipImageFilter::m_ClippingMode
int m_ClippingMode
Definition: mitkHeightFieldSurfaceClipImageFilter.h:132
MITKALGORITHMSEXT_EXPORT
#define MITKALGORITHMSEXT_EXPORT
Definition: MitkAlgorithmsExtExports.h:15
mitk::AffineTransform3D
itk::ScalableAffineTransform< ScalarType, 3 > AffineTransform3D
Definition: mitkAffineTransform3D.h:23
mitk::Surface
Class for storing surfaces (vtkPolyData).
Definition: mitkSurface.h:28
mitk
Find image slices visible on a given plane.
Definition: RenderingTests.dox:1
mitkSurface.h
mitk::HeightFieldSurfaceClipImageFilter::m_MultiplicationFactor
ScalarType m_MultiplicationFactor
Definition: mitkHeightFieldSurfaceClipImageFilter.h:135
mitk::HeightFieldSurfaceClipImageFilter::m_OutputTimeSelector
ImageTimeSelector::Pointer m_OutputTimeSelector
Definition: mitkHeightFieldSurfaceClipImageFilter.h:130
mitk::HeightFieldSurfaceClipImageFilter
Filter for clipping an image with an height-field represented by an mitk::Surface.
Definition: mitkHeightFieldSurfaceClipImageFilter.h:43
mitk::BaseDataSource
Superclass of all classes generating some kind of mitk::BaseData.
Definition: mitkBaseDataSource.h:71
mitk::HeightFieldSurfaceClipImageFilter::m_MaxHeight
double m_MaxHeight
Definition: mitkHeightFieldSurfaceClipImageFilter.h:141
mitkCommon.h
mitk::HeightFieldSurfaceClipImageFilter::m_TimeOfHeaderInitialization
itk::TimeStamp m_TimeOfHeaderInitialization
Time when Header was last initialized.
Definition: mitkHeightFieldSurfaceClipImageFilter.h:144
itk
SET FUNCTIONS.
Definition: itkIntelligentBinaryClosingFilter.h:30
mitk::HeightFieldSurfaceClipImageFilter::m_InputTimeSelector
ImageTimeSelector::Pointer m_InputTimeSelector
Definition: mitkHeightFieldSurfaceClipImageFilter.h:129
mitkClassMacro
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:36
itk::Image
class ITK_EXPORT Image
Definition: mitkGeometryClipImageFilter.h:25
mitk::HeightFieldSurfaceClipImageFilter::m_HeightFieldResolutionX
unsigned int m_HeightFieldResolutionX
Definition: mitkHeightFieldSurfaceClipImageFilter.h:138
mitk::HeightFieldSurfaceClipImageFilter::CLIPPING_MODE_MULTIPLYBYFACTOR
@ CLIPPING_MODE_MULTIPLYBYFACTOR
Definition: mitkHeightFieldSurfaceClipImageFilter.h:66
mitk::ImageToImageFilter
Superclass of all classes having one or more Images as input and generating Images as output.
Definition: mitkImageToImageFilter.h:25
mitk::HeightFieldSurfaceClipImageFilter::m_MultiPlaneValue
unsigned m_MultiPlaneValue
Definition: mitkHeightFieldSurfaceClipImageFilter.h:136
mitk::ScalarType
double ScalarType
Definition: mitkNumericConstants.h:20