ITK  4.6.0
Insight Segmentation and Registration Toolkit
itkReinitializeLevelSetImageFilter.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 __itkReinitializeLevelSetImageFilter_h
19 #define __itkReinitializeLevelSetImageFilter_h
20 
23 
24 namespace itk
25 {
54 template< typename TLevelSet >
56  public ImageToImageFilter< TLevelSet, TLevelSet >
57 {
58 public:
64 
66  itkNewMacro(Self);
67 
70 
77  typedef typename LevelSetType::NodeType NodeType;
80 
82  itkStaticConstMacro(SetDimension, unsigned int,
84 
87  itkSetMacro(LevelSetValue, double);
88  itkGetConstMacro(LevelSetValue, double);
90 
93  itkSetMacro(NarrowBanding, bool);
94  itkGetConstMacro(NarrowBanding, bool);
95  itkBooleanMacro(NarrowBanding);
97 
99  itkSetClampMacro( InputNarrowBandwidth, double, 0.0,
101  itkGetConstMacro(InputNarrowBandwidth, double);
103 
105  itkSetClampMacro( OutputNarrowBandwidth, double, 0.0,
107  itkGetConstMacro(OutputNarrowBandwidth, double);
109 
112  void SetNarrowBandwidth(double value)
113  {
114  this->SetInputNarrowBandwidth(value);
115  this->SetOutputNarrowBandwidth(value);
116  }
118 
121 
123  { return m_InputNarrowBand; }
124 
127  { return m_OutputNarrowBand; }
128 
129 #ifdef ITK_USE_CONCEPT_CHECKING
130  // Begin concept checking
131  itkConceptMacro( LevelSetDoubleAdditiveOperatorsCheck,
133  itkConceptMacro( LevelSetOStreamWritableCheck,
135  // End concept checking
136 #endif
137 
138 protected:
141  void PrintSelf(std::ostream & os, Indent indent) const;
142 
147 
148  void GenerateData();
149 
150  virtual void GenerateDataFull();
151 
152  virtual void GenerateDataNarrowBand();
153 
154  virtual void AllocateOutput();
155 
156  virtual void GenerateInputRequestedRegion();
157 
159 
161  { m_OutputNarrowBand = ptr; }
162 
163 private:
164  ReinitializeLevelSetImageFilter(const Self &); //purposely not implemented
165  void operator=(const Self &); //purposely not implemented
166 
168 
170 
172 
178 };
179 } // namespace itk
180 
181 #ifndef ITK_MANUAL_INSTANTIATION
182 #include "itkReinitializeLevelSetImageFilter.hxx"
183 #endif
184 
185 #endif
LevelSetType::LevelSetConstPointer LevelSetConstPointer
Locate pixels of a particular level set.
Light weight base class for most itk classes.
TLevelSet::PixelType PixelType
Definition: itkLevelSet.h:55
FastMarchingImageFilter< TLevelSet, SpeedImageType > FastMarchingImageFilterType
void SetInputNarrowBand(NodeContainer *ptr)
virtual void SetInputNarrowBandwidth(double _arg)
Image< float, itkGetStaticConstMacro(SetDimension) > SpeedImageType
Represent a node in a level set.
TLevelSet::ConstPointer LevelSetConstPointer
Definition: itkLevelSet.h:52
LevelSetNeighborhoodExtractor< TLevelSet > LocatorType
LevelSetType::NodeContainerPointer NodeContainerPointer
virtual void EnlargeOutputRequestedRegion(DataObject *)
Reinitialize the level set to the signed distance function.
Base class for filters that take an image as input and produce an image as output.
Define a front-end to the STL &quot;vector&quot; container that conforms to the IndexedContainerInterface.
FastMarchingImageFilterType::Pointer m_Marcher
Control indentation during Print() invocation.
Definition: itkIndent.h:49
void PrintSelf(std::ostream &os, Indent indent) const
Define additional traits for native types such as int or float.
Solve an Eikonal equation using Fast Marching.
virtual void SetOutputNarrowBandwidth(double _arg)
#define itkConceptMacro(name, concept)
Level set type information.
Definition: itkLevelSet.h:40
ImageToImageFilter< TLevelSet, TLevelSet > Superclass
static const unsigned int SetDimension
Definition: itkLevelSet.h:48
Base class for all data objects in ITK.
Templated n-dimensional image class.
Definition: itkImage.h:75
TLevelSet::Pointer LevelSetPointer
Definition: itkLevelSet.h:51