ITK  5.3.0
Insight Toolkit
itkBinaryImageToLevelSetImageAdaptorBase.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  * http://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 itkBinaryImageToLevelSetImageAdaptorBase_h
20 #define itkBinaryImageToLevelSetImageAdaptorBase_h
21 
22 #include "itkImage.h"
23 #include "itkObject.h"
24 
25 namespace itk
26 {
31 template <typename TInputImage, typename TLevelSet>
33 {
34 public:
35  ITK_DISALLOW_COPY_AND_MOVE(BinaryImageToLevelSetImageAdaptorBase);
36 
40  using Superclass = Object;
41 
44 
45  using InputImageType = TInputImage;
46  using InputImagePixelType = typename InputImageType::PixelType;
48  using InputImagePointer = typename InputImageType::Pointer;
51 
52  static constexpr unsigned int ImageDimension = InputImageType::ImageDimension;
53 
54  using LevelSetType = TLevelSet;
56 
60  virtual void
61  Initialize() = 0;
62 
64  itkGetModifiableObjectMacro(LevelSet, LevelSetType);
65 
67  itkSetObjectMacro(InputImage, InputImageType);
68  itkGetModifiableObjectMacro(InputImage, InputImageType);
70 
71 protected:
73  BinaryImageToLevelSetImageAdaptorBase() { this->m_LevelSet = LevelSetType::New(); }
74 
76  ~BinaryImageToLevelSetImageAdaptorBase() override = default;
77 
80 };
81 } // namespace itk
82 
83 #endif // itkBinaryImageToLevelSetImageAdaptorBase_h
itk::BinaryImageToLevelSetImageAdaptorBase< TInput, ShiSparseLevelSetImage< TInput::ImageDimension > >::InputImageType
TInput InputImageType
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:45
itk::BinaryImageToLevelSetImageAdaptorBase::m_InputImage
InputImagePointer m_InputImage
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:78
itk::BinaryImageToLevelSetImageAdaptorBase::Initialize
virtual void Initialize()=0
itk::BinaryImageToLevelSetImageAdaptorBase::~BinaryImageToLevelSetImageAdaptorBase
~BinaryImageToLevelSetImageAdaptorBase() override=default
itkImage.h
itk::SmartPointer< Self >
itk::BinaryImageToLevelSetImageAdaptorBase< TInput, ShiSparseLevelSetImage< TInput::ImageDimension > >::InputImageIndexType
typename InputImageType::IndexType InputImageIndexType
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:47
itk::BinaryImageToLevelSetImageAdaptorBase::BinaryImageToLevelSetImageAdaptorBase
BinaryImageToLevelSetImageAdaptorBase()
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:73
itk::GTest::TypedefsAndConstructors::Dimension2::IndexType
ImageBaseType::IndexType IndexType
Definition: itkGTestTypedefsAndConstructors.h:50
itk::BinaryImageToLevelSetImageAdaptorBase::ImageDimension
static constexpr unsigned int ImageDimension
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:52
itk::LightObject
Light weight base class for most itk classes.
Definition: itkLightObject.h:59
itk::BinaryImageToLevelSetImageAdaptorBase< TInput, ShiSparseLevelSetImage< TInput::ImageDimension > >::LevelSetPointer
typename LevelSetType::Pointer LevelSetPointer
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:55
itk::GTest::TypedefsAndConstructors::Dimension2::RegionType
ImageBaseType::RegionType RegionType
Definition: itkGTestTypedefsAndConstructors.h:54
itk::BinaryImageToLevelSetImageAdaptorBase< TInput, ShiSparseLevelSetImage< TInput::ImageDimension > >::InputImagePixelType
typename InputImageType::PixelType InputImagePixelType
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:46
itk::BinaryImageToLevelSetImageAdaptorBase::m_LevelSet
LevelSetPointer m_LevelSet
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:79
itk::NumericTraits
Define additional traits for native types such as int or float.
Definition: itkNumericTraits.h:58
itkObject.h
itk::BinaryImageToLevelSetImageAdaptorBase< TInput, ShiSparseLevelSetImage< TInput::ImageDimension > >::InputImageRegionType
typename InputImageType::RegionType InputImageRegionType
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:49
itk::ShiSparseLevelSetImage
Derived class for the shi representation of level-set function.
Definition: itkShiSparseLevelSetImage.h:37
itk
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Definition: itkAnnulusOperator.h:24
itk::Object
Base class for most ITK classes.
Definition: itkObject.h:62
itk::BinaryImageToLevelSetImageAdaptorBase< TInput, ShiSparseLevelSetImage< TInput::ImageDimension > >::InputImagePointer
typename InputImageType::Pointer InputImagePointer
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:48
itk::BinaryImageToLevelSetImageAdaptorBase< TInput, ShiSparseLevelSetImage< TInput::ImageDimension > >::InputPixelRealType
typename NumericTraits< InputImagePixelType >::RealType InputPixelRealType
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:50
itk::Object::Object
Object()
itk::BinaryImageToLevelSetImageAdaptorBase
Definition: itkBinaryImageToLevelSetImageAdaptorBase.h:32