18 #ifndef itkRLEImageRegionConstIterator_h
19 #define itkRLEImageRegionConstIterator_h
26 class MultiLabelMeshPipeline;
41 template<
typename TPixel,
unsigned int VImageDimension,
typename CounterType >
45 friend class ::MultiLabelMeshPipeline;
120 if ( this->m_Index0 >= this->m_EndIndex0 )
123 if ( !this->m_BI.IsAtEnd() )
125 this->SetIndexInternal( this->m_BeginIndex0 );
129 this->m_Index0 = this->m_BeginIndex0;
134 this->m_SegmentRemainder--;
135 if ( this->m_SegmentRemainder > 0 )
141 this->m_SegmentRemainder = ( *this->m_RunLengthLine )[this->m_RealIndex].first;
157 if ( this->m_Index0 < this->m_BeginIndex0 )
160 this->SetIndexInternal( this->m_EndIndex0 - 1 );
164 this->m_SegmentRemainder++;
165 if ( this->m_SegmentRemainder <= ( *this->m_RunLengthLine )[this->m_RealIndex].first )
171 this->m_SegmentRemainder = 1;
176 template<
typename TPixel,
unsigned int VImageDimension,
typename CounterType >
199 this->m_BI.GoToEnd();
201 this->m_Index0 = this->m_EndIndex0 - 1;
202 this->SetIndexInternal( this->m_Index0 );
208 return ( this->m_Index0 == this->m_BeginIndex0 ) && this->m_BI.IsAtBegin();
224 template<
typename TPixel,
unsigned int VImageDimension,
typename CounterType >
260 #endif // itkRLEImageRegionConstIterator_h
typename TImage::OffsetType OffsetType
ImageRegionConstIteratorWithOnlyIndex(const ImageIterator< ImageType > &it)
static constexpr unsigned int ImageIteratorDimension
ImageRegionConstIteratorWithIndex(const ImageType *ptr, const RegionType ®ion)
typename TImage::InternalPixelType InternalPixelType
A multi-dimensional iterator templated over image type that walks an image region and is specialized ...
typename ImageType::SizeType SizeType
ImageRegionConstIteratorWithIndex()
A multi-dimensional iterator templated over image type.
typename TImage::PixelType PixelType
typename ImageType::RegionType RegionType
typename Superclass::RegionType RegionType
A multi-dimensional iterator templated over image type that walks an image region and is specialized ...
A multi-dimensional image iterator templated over image type.
ImageRegionConstIterator(const ImageType *ptr, const RegionType ®ion)
Self & operator=(const Self &it)
typename ImageType::PixelType PixelType
ImageRegionConstIterator Self
A multi-dimensional iterator templated over image type that walks a region of pixels.
typename TImage::IndexType IndexType
ImageRegionConstIterator(const ImageIterator< ImageType > &it)
typename Superclass::RegionType RegionType
typename ImageType::OffsetType OffsetType
ImageRegionConstIteratorWithOnlyIndex(const ImageType *ptr, const RegionType ®ion)
ImageRegionConstIterator(const ImageConstIterator< ImageType > &it)
ImageRegionConstIteratorWithOnlyIndex()
typename TImage::SizeType SizeType
typename ImageType::IndexType IndexType
Run-Length Encoded image. It saves memory for label images at the expense of processing times...
typename TImage::RegionType RegionType
typename ImageType::InternalPixelType InternalPixelType
ImageRegionConstIteratorWithIndex(const ImageIterator< ImageType > &it)
ImageRegionConstIterator()