ITK  4.8.0
Insight Segmentation and Registration Toolkit
itkLevelSetFunctionWithRefitTerm.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 #ifndef itkLevelSetFunctionWithRefitTerm_h
19 #define itkLevelSetFunctionWithRefitTerm_h
20 
21 #include "itkLevelSetFunction.h"
22 #include "itkSparseImage.h"
23 #include "itkNumericTraits.h"
24 
25 namespace itk
26 {
51 template< typename TImageType, typename TSparseImageType >
53  public LevelSetFunction< TImageType >
54 {
55 public:
56 
62 
65 
67  itkNewMacro (Self);
68 
70  typedef typename Superclass::ImageType ImageType;
73  typedef typename Superclass::GlobalDataStruct GlobalDataStruct;
77 
79 
81  typedef typename ImageType::IndexType IndexType;
82 
84  typedef TSparseImageType SparseImageType;
85 
87  typedef typename SparseImageType::NodeType NodeType;
88 
90  typedef typename NodeType::NodeDataType NormalVectorType;
91 
94  {
95  m_RefitWeight = w;
96  }
97 
101  {
103  }
104 
108  { m_SparseTargetImage = im; }
109 
112  { return m_SparseTargetImage; }
113 
118  virtual TimeStepType ComputeGlobalTimeStep(void *GlobalData) const ITK_OVERRIDE;
119 
120 protected:
123 
127 
129  void PrintSelf(std::ostream & os, Indent indent) const ITK_OVERRIDE;
130 
134 
139  const FloatOffsetType &,
140  GlobalDataStruct * = 0) const ITK_OVERRIDE;
141 
146  const FloatOffsetType &,
147  GlobalDataStruct * = 0) const
148  {
150  }
151 
152 private:
153  LevelSetFunctionWithRefitTerm(const Self &); //purposely not implemented
154  void operator=(const Self &); //purposely not implemented
155 
157  typename SparseImageType::Pointer m_SparseTargetImage;
158 
161 
165 };
166 } // end namespace itk
167 
168 #ifndef ITK_MANUAL_INSTANTIATION
169 #include "itkLevelSetFunctionWithRefitTerm.hxx"
170 #endif
171 
172 #endif
void PrintSelf(std::ostream &os, Indent indent) const override
ScalarValueType ComputeCurvature(const NeighborhoodType &) const
Light weight base class for most itk classes.
The LevelSetFunction class is a generic function object which can be used to create a level set metho...
Superclass::NeighborhoodType NeighborhoodType
static const NeighborhoodSizeValueType m_NumVertex
Superclass::FloatOffsetType FloatOffsetType
Superclass::ImageType ImageType
Const version of NeighborhoodIterator, defining iteration of a local N-dimensional neighborhood of pi...
unsigned long SizeValueType
Definition: itkIntTypes.h:143
virtual TimeStepType ComputeGlobalTimeStep(void *GlobalData) const override
Superclass::NeighborhoodScalesType NeighborhoodScalesType
Superclass::NeighborhoodScalesType NeighborhoodScalesType
void SetOtherPropagationWeight(const ScalarValueType w)
virtual ScalarValueType PropagationSpeed(const NeighborhoodType &, const FloatOffsetType &, GlobalDataStruct *=0) const override
A templated class holding a n-Dimensional vector.
Definition: itkVector.h:62
NeighborhoodType::SizeValueType NeighborhoodSizeValueType
This class extends the LevelSetFunction class by adding a grow term based on a target curvature store...
Control indentation during Print() invocation.
Definition: itkIndent.h:49
virtual ScalarValueType OtherPropagationSpeed(const NeighborhoodType &, const FloatOffsetType &, GlobalDataStruct *=0) const