ITK  6.0.0
Insight Toolkit
itkLevelSetDenseImage.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright NumFOCUS
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * https://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 
19 #ifndef itkLevelSetDenseImage_h
20 #define itkLevelSetDenseImage_h
21 
23 
24 namespace itk
25 {
40 template <typename TImage>
41 class ITK_TEMPLATE_EXPORT LevelSetDenseImage
42  : public DiscreteLevelSetImage<typename TImage::PixelType, TImage::ImageDimension>
43 {
44 public:
45  ITK_DISALLOW_COPY_AND_MOVE(LevelSetDenseImage);
46 
47  using ImageType = TImage;
48  using ImagePointer = typename ImageType::Pointer;
49  using IndexType = typename ImageType::IndexType;
50  using PixelType = typename ImageType::PixelType;
52 
57 
59  itkNewMacro(Self);
60 
62  itkOverrideGetNameOfClassMacro(LevelSetDenseImage);
63 
64  static constexpr unsigned int Dimension = Superclass::Dimension;
65 
66  using typename Superclass::InputType;
67  using typename Superclass::OutputType;
68  using typename Superclass::OutputRealType;
69  using typename Superclass::GradientType;
70  using typename Superclass::HessianType;
71  using typename Superclass::LevelSetDataType;
72 
73  virtual void
74  SetImage(ImageType * inputImage);
75  itkGetModifiableObjectMacro(Image, ImageType);
76 
79  Evaluate(const InputType & inputIndex) const override;
80  void
81  Evaluate(const InputType & inputIndex, LevelSetDataType & data) const override;
84 protected:
85  LevelSetDenseImage() = default;
86 
87  ~LevelSetDenseImage() override = default;
88 
89  ImagePointer m_Image{};
90 
91  bool
92  IsInsideDomain(const InputType & inputIndex) const override;
93 
95  void
96  Initialize() override;
97 
99  void
100  CopyInformation(const DataObject * data) override;
101 
103  void
104  Graft(const DataObject * data) override;
105 
106 private:
107 };
108 } // namespace itk
109 
110 #ifndef ITK_MANUAL_INSTANTIATION
111 # include "itkLevelSetDenseImage.hxx"
112 #endif
113 
114 #endif // itkLevelSetDenseImage_h
Pointer
SmartPointer< Self > Pointer
Definition: itkAddImageFilter.h:93
itk::Index
Represent a n-dimensional index in a n-dimensional image.
Definition: itkIndex.h:68
itk::LevelSetDenseImage
Base class for the "dense" representation of a level-set function on one image.
Definition: itkLevelSetDenseImage.h:41
itk::LevelSetDenseImage::ImageType
TImage ImageType
Definition: itkLevelSetDenseImage.h:47
itk::LevelSetDenseImage::ImagePointer
typename ImageType::Pointer ImagePointer
Definition: itkLevelSetDenseImage.h:48
itk::LevelSetDenseImage::RegionType
typename ImageType::RegionType RegionType
Definition: itkLevelSetDenseImage.h:51
itkDiscreteLevelSetImage.h
itk::SmartPointer< Self >
itk::GTest::TypedefsAndConstructors::Dimension2::IndexType
ImageBaseType::IndexType IndexType
Definition: itkGTestTypedefsAndConstructors.h:50
itk::LevelSetDenseImage::IndexType
typename ImageType::IndexType IndexType
Definition: itkLevelSetDenseImage.h:49
itk::GTest::TypedefsAndConstructors::Dimension2::RegionType
ImageBaseType::RegionType RegionType
Definition: itkGTestTypedefsAndConstructors.h:54
itk::DiscreteLevelSetImage
Abstract class for a level-set function on one Image.
Definition: itkDiscreteLevelSetImage.h:36
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnatomicalOrientation.h:29
itk::LevelSetDenseImage::PixelType
typename ImageType::PixelType PixelType
Definition: itkLevelSetDenseImage.h:50
itk::Object
Base class for most ITK classes.
Definition: itkObject.h:61
itk::Image
Templated n-dimensional image class.
Definition: itkImage.h:88
itk::LevelSetBase< Index< VDimension >, VDimension, TImage::PixelType, ImageBase< VDimension > >::OutputType
TImage::PixelType OutputType
Definition: itkLevelSetBase.h:59
itk::GTest::TypedefsAndConstructors::Dimension2::Dimension
constexpr unsigned int Dimension
Definition: itkGTestTypedefsAndConstructors.h:44
itk::DataObject
Base class for all data objects in ITK.
Definition: itkDataObject.h:293