ITK
4.1.0
Insight Segmentation and Registration Toolkit
|
00001 /*========================================================================= 00002 * 00003 * Copyright Insight Software Consortium 00004 * 00005 * Licensed under the Apache License, Version 2.0 (the "License"); 00006 * you may not use this file except in compliance with the License. 00007 * You may obtain a copy of the License at 00008 * 00009 * http://www.apache.org/licenses/LICENSE-2.0.txt 00010 * 00011 * Unless required by applicable law or agreed to in writing, software 00012 * distributed under the License is distributed on an "AS IS" BASIS, 00013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00014 * See the License for the specific language governing permissions and 00015 * limitations under the License. 00016 * 00017 *=========================================================================*/ 00018 #ifndef __itkHMinimaImageFilter_h 00019 #define __itkHMinimaImageFilter_h 00020 00021 #include "itkImageToImageFilter.h" 00022 00023 namespace itk 00024 { 00054 template< class TInputImage, class TOutputImage > 00055 class ITK_EXPORT HMinimaImageFilter: 00056 public ImageToImageFilter< TInputImage, TOutputImage > 00057 { 00058 public: 00060 typedef HMinimaImageFilter Self; 00061 typedef ImageToImageFilter< TInputImage, TOutputImage > Superclass; 00062 typedef SmartPointer< Self > Pointer; 00063 typedef SmartPointer< const Self > ConstPointer; 00064 00066 typedef TInputImage InputImageType; 00067 typedef typename InputImageType::Pointer InputImagePointer; 00068 typedef typename InputImageType::ConstPointer InputImageConstPointer; 00069 typedef typename InputImageType::RegionType InputImageRegionType; 00070 typedef typename InputImageType::PixelType InputImagePixelType; 00071 typedef TOutputImage OutputImageType; 00072 typedef typename OutputImageType::Pointer OutputImagePointer; 00073 typedef typename OutputImageType::ConstPointer OutputImageConstPointer; 00074 typedef typename OutputImageType::RegionType OutputImageRegionType; 00075 typedef typename OutputImageType::PixelType OutputImagePixelType; 00076 00078 itkStaticConstMacro(InputImageDimension, unsigned int, 00079 TInputImage::ImageDimension); 00080 itkStaticConstMacro(OutputImageDimension, unsigned int, 00081 TOutputImage::ImageDimension); 00083 00085 itkNewMacro(Self); 00086 00088 itkTypeMacro(HMinimaImageFilter, 00089 ImageToImageFilter); 00090 00095 itkSetMacro(Height, InputImagePixelType); 00096 itkGetConstMacro(Height, InputImagePixelType); 00098 00105 itkSetMacro(FullyConnected, bool); 00106 itkGetConstReferenceMacro(FullyConnected, bool); 00107 itkBooleanMacro(FullyConnected); 00109 00110 #ifdef ITK_USE_CONCEPT_CHECKING 00111 00112 itkConceptMacro( InputEqualityComparableCheck, 00113 ( Concept::EqualityComparable< InputImagePixelType > ) ); 00114 itkConceptMacro( IntConvertibleToInputCheck, 00115 ( Concept::Convertible< int, InputImagePixelType > ) ); 00116 itkConceptMacro( InputOStreamWritableCheck, 00117 ( Concept::OStreamWritable< InputImagePixelType > ) ); 00118 00120 #endif 00121 protected: 00122 HMinimaImageFilter(); 00123 ~HMinimaImageFilter() {} 00124 void PrintSelf(std::ostream & os, Indent indent) const; 00126 00130 void GenerateInputRequestedRegion(); 00131 00133 void EnlargeOutputRequestedRegion( DataObject *itkNotUsed(output) ); 00134 00137 void GenerateData(); 00138 00139 private: 00140 HMinimaImageFilter(const Self &); //purposely not implemented 00141 void operator=(const Self &); //purposely not implemented 00142 00143 InputImagePixelType m_Height; 00144 unsigned long m_NumberOfIterationsUsed; 00145 bool m_FullyConnected; 00146 }; // end of class 00147 } // end namespace itk 00148 00149 #ifndef ITK_MANUAL_INSTANTIATION 00150 #include "itkHMinimaImageFilter.hxx" 00151 #endif 00152 00153 #endif 00154