ITK  5.0.0
Insight Segmentation and Registration Toolkit
itkLevelSetEquationPropagationTerm.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
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 itkLevelSetEquationPropagationTerm_h
20 #define itkLevelSetEquationPropagationTerm_h
21 
25 #include "itkVector.h"
26 #include "vnl/vnl_matrix_fixed.h"
27 
28 namespace itk
29 {
46 template< typename TInput, // Input image or mesh
47  typename TLevelSetContainer,
48  typename TPropagationImage = TInput >
49 class ITK_TEMPLATE_EXPORT LevelSetEquationPropagationTerm :
50  public LevelSetEquationTermBase< TInput, TLevelSetContainer >
51 {
52 public:
53  ITK_DISALLOW_COPY_AND_ASSIGN(LevelSetEquationPropagationTerm);
54 
58  using Superclass =
60 
62  itkNewMacro( Self );
63 
65  itkTypeMacro( LevelSetEquationPropagationTerm,
67 
68  using InputImageType = typename Superclass::InputImageType;
69  using InputImagePointer = typename Superclass::InputImagePointer;
70  using InputPixelType = typename Superclass::InputPixelType;
71  using InputPixelRealType = typename Superclass::InputPixelRealType;
72 
73  using LevelSetContainerType = typename Superclass::LevelSetContainerType;
74  using LevelSetContainerPointer = typename Superclass::LevelSetContainerPointer;
75  using LevelSetType = typename Superclass::LevelSetType;
76  using LevelSetPointer = typename Superclass::LevelSetPointer;
77  using LevelSetOutputPixelType = typename Superclass::LevelSetOutputPixelType;
78  using LevelSetOutputRealType = typename Superclass::LevelSetOutputRealType;
79  using LevelSetInputIndexType = typename Superclass::LevelSetInputIndexType;
80  using LevelSetGradientType = typename Superclass::LevelSetGradientType;
81  using LevelSetHessianType = typename Superclass::LevelSetHessianType;
82  using LevelSetIdentifierType = typename Superclass::LevelSetIdentifierType;
83  using LevelSetDataType = typename Superclass::LevelSetDataType;
84 
85  using HeavisideType = typename Superclass::HeavisideType;
86  using HeavisideConstPointer = typename Superclass::HeavisideConstPointer;
87 
88  static constexpr unsigned int ImageDimension = InputImageType::ImageDimension;
89 
90  using PropagationImageType = TPropagationImage;
91  using PropagationImagePointer = typename PropagationImageType::Pointer;
92 
97 
99 
103  itkSetObjectMacro( PropagationImage, PropagationImageType );
104  itkGetModifiableObjectMacro(PropagationImage, PropagationImageType );
106 
108  void Update() override;
109 
111  void InitializeParameters() override;
112 
114  void Initialize( const LevelSetInputIndexType& ) override;
115 
117  void UpdatePixel( const LevelSetInputIndexType& iP,
118  const LevelSetOutputRealType& oldValue,
119  const LevelSetOutputRealType& newValue ) override;
120 
121 protected:
123 
124  ~LevelSetEquationPropagationTerm() override = default;
125 
127 
130  LevelSetOutputRealType PropagationSpeed( const LevelSetInputIndexType& iP ) const;
131 
134  LevelSetOutputRealType Value( const LevelSetInputIndexType& iP ) override;
136  const LevelSetDataType& iData ) override;
137 };
139 
140 }
141 
142 #ifndef ITK_MANUAL_INSTANTIATION
143 #include "itkLevelSetEquationPropagationTerm.hxx"
144 #endif
145 
146 #endif
typename Superclass::LevelSetContainerPointer LevelSetContainerPointer
typename Superclass::LevelSetOutputRealType LevelSetOutputRealType
Light weight base class for most itk classes.
typename PropagationImageType::Pointer PropagationImagePointer
typename Superclass::InputPixelType InputPixelType
typename Superclass::LevelSetContainerType LevelSetContainerType
typename Superclass::HeavisideConstPointer HeavisideConstPointer
Const version of NeighborhoodIterator, defining iteration of a local N-dimensional neighborhood of pi...
typename Superclass::LevelSetInputIndexType LevelSetInputIndexType
typename Superclass::LevelSetIdentifierType LevelSetIdentifierType
Abstract class to represents a term in the level-set evolution PDE.
Derived class to represents a propagation term in the level-set evolution PDE.
A templated class holding a n-Dimensional vector.
Definition: itkVector.h:62
typename Superclass::LevelSetGradientType LevelSetGradientType
typename Superclass::LevelSetPointer LevelSetPointer
typename Superclass::LevelSetOutputPixelType LevelSetOutputPixelType
typename Superclass::LevelSetHessianType LevelSetHessianType
typename Superclass::InputPixelRealType InputPixelRealType
typename Superclass::InputImageType InputImageType
typename ConstNeighborhoodIterator< InputImageType >::RadiusType RadiusType
typename Superclass::RadiusType RadiusType
typename Superclass::InputImagePointer InputImagePointer
typename Superclass::HeavisideType HeavisideType
typename Superclass::LevelSetDataType LevelSetDataType