00001 /*========================================================================= 00002 00003 Program: Insight Segmentation & Registration Toolkit 00004 Module: $RCSfile: itkImageRegionExclusionConstIteratorWithIndex.h,v $ 00005 Language: C++ 00006 Date: $Date: 2005/02/18 13:24:53 $ 00007 Version: $Revision: 1.7 $ 00008 00009 Copyright (c) Insight Software Consortium. All rights reserved. 00010 See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details. 00011 00012 This software is distributed WITHOUT ANY WARRANTY; without even 00013 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00014 PURPOSE. See the above copyright notices for more information. 00015 00016 =========================================================================*/ 00017 #ifndef __itkImageRegionExclusionConstIteratorWithIndex_h 00018 #define __itkImageRegionExclusionConstIteratorWithIndex_h 00019 00020 #include "itkImageConstIteratorWithIndex.h" 00021 00022 namespace itk 00023 { 00024 00124 template<typename TImage> 00125 class ITK_EXPORT ImageRegionExclusionConstIteratorWithIndex : public ImageConstIteratorWithIndex<TImage> 00126 { 00127 public: 00129 typedef ImageRegionExclusionConstIteratorWithIndex Self; 00130 typedef ImageConstIteratorWithIndex<TImage> Superclass; 00131 00136 typedef typename TImage::IndexType IndexType; 00137 typedef typename TImage::SizeType SizeType; 00138 00143 typedef TImage ImageType; 00144 00148 typedef typename TImage::PixelContainer PixelContainer; 00149 typedef typename PixelContainer::Pointer PixelContainerPointer; 00150 00155 typedef typename TImage::RegionType RegionType; 00156 00158 ImageRegionExclusionConstIteratorWithIndex() : ImageConstIteratorWithIndex<TImage>() {} 00159 00162 ImageRegionExclusionConstIteratorWithIndex(const TImage *ptr, 00163 const RegionType& region) 00164 : ImageConstIteratorWithIndex<TImage>(ptr, region) {} 00165 00172 ImageRegionExclusionConstIteratorWithIndex( const ImageConstIteratorWithIndex<TImage> &it) 00173 { this->ImageConstIteratorWithIndex<TImage>::operator=(it); } 00174 00182 Self & operator++(); 00183 00191 Self & operator--(); 00192 00193 00200 void SetExclusionRegion( const RegionType & region ); 00201 00206 void SetExclusionRegionToInsetRegion(); 00207 00208 private: 00209 00210 RegionType m_ExclusionRegion; 00211 00212 IndexType m_ExclusionBegin; 00213 IndexType m_ExclusionEnd; 00214 00215 }; 00216 00217 } // end namespace itk 00218 00219 #ifndef ITK_MANUAL_INSTANTIATION 00220 #include "itkImageRegionExclusionConstIteratorWithIndex.txx" 00221 #endif 00222 00223 #endif 00224