Medical Imaging Interaction Toolkit  2024.06.00
Medical Imaging Interaction Toolkit
mitkSurface.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 mitkSurface_h
14 #define mitkSurface_h
15 
16 #include "itkImageRegion.h"
17 #include "mitkBaseData.h"
18 #include <vtkSmartPointer.h>
19 
20 class vtkPolyData;
21 
22 namespace mitk
23 {
29  {
30  public:
31  typedef itk::ImageRegion<5> RegionType;
32 
34  itkFactorylessNewMacro(Self);
35  itkCloneMacro(Self);
36 
37  void CalculateBoundingBox();
38  void CopyInformation(const itk::DataObject *data) override;
39  void ExecuteOperation(Operation *operation) override;
40  void Expand(unsigned int timeSteps = 1) override;
41  const RegionType &GetLargestPossibleRegion() const;
42  virtual const RegionType &GetRequestedRegion() const;
43  unsigned int GetSizeOfPolyDataSeries() const;
44  virtual vtkPolyData *GetVtkPolyData(unsigned int t = 0) const;
45  void Graft(const DataObject *data) override;
46  bool IsEmptyTimeStep(unsigned int t) const override;
47  void PrintSelf(std::ostream &os, itk::Indent indent) const override;
48  bool RequestedRegionIsOutsideOfTheBufferedRegion() override;
49  void SetRequestedRegion(const itk::DataObject *data) override;
50  virtual void SetRequestedRegion(Surface::RegionType *region);
51  void SetRequestedRegionToLargestPossibleRegion() override;
52  virtual void SetVtkPolyData(vtkPolyData *polydata, unsigned int t = 0);
53  virtual void Swap(Surface &other);
54  void Update() override;
55  void UpdateOutputInformation() override;
56  bool VerifyRequestedRegion() override;
57 
58  protected:
60 
61  Surface();
62  ~Surface() override;
63 
64  Surface(const Surface &other);
65  Surface &operator=(Surface other);
66 
67  void ClearData() override;
68  void InitializeEmpty() override;
69 
70  private:
71  std::vector<vtkSmartPointer<vtkPolyData>> m_PolyDatas;
72  mutable RegionType m_LargestPossibleRegion;
73  mutable RegionType m_RequestedRegion;
74  bool m_CalculateBoundingBox;
75  };
76 
89  mitk::Surface *leftHandSide, mitk::Surface *rightHandSide, mitk::ScalarType eps, bool verbose));
90 
100  MITKCORE_EXPORT bool Equal(mitk::Surface &leftHandSide,
101  mitk::Surface &rightHandSide,
103  bool verbose);
104 
121  vtkPolyData *leftHandSide, vtkPolyData *rightHandSide, mitk::ScalarType eps, bool verbose));
122 
136  MITKCORE_EXPORT bool Equal(vtkPolyData &leftHandSide, vtkPolyData &rightHandSide, mitk::ScalarType eps, bool verbose);
137 }
138 
139 #endif
mitk::eps
const MITKCORE_EXPORT ScalarType eps
mitk::Operation
Base class of all Operation-classes.
Definition: mitkOperation.h:29
DEPRECATED
#define DEPRECATED(func)
Definition: mitkCommon.h:175
mitk::Equal
MITKNEWMODULE_EXPORT bool Equal(mitk::ExampleDataStructure *leftHandSide, mitk::ExampleDataStructure *rightHandSide, mitk::ScalarType eps, bool verbose)
Returns true if the example data structures are considered equal.
mitk::Surface
Class for storing surfaces (vtkPolyData).
Definition: mitkSurface.h:28
mitk
Find image slices visible on a given plane.
Definition: RenderingTests.dox:1
mitk::BaseData
Base of all data objects.
Definition: mitkBaseData.h:42
mitkCloneMacro
#define mitkCloneMacro(classname)
Definition: mitkCommon.h:154
mitkBaseData.h
mitkClassMacro
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:36
MITKCORE_EXPORT
#define MITKCORE_EXPORT
Definition: MitkCoreExports.h:15
mitk::Surface::RegionType
itk::ImageRegion< 5 > RegionType
Definition: mitkSurface.h:31
mitk::ScalarType
double ScalarType
Definition: mitkNumericConstants.h:20