18 #ifndef itkImageScanlineConstIterator_h
19 #define itkImageScanlineConstIterator_h
62 template<
typename TImage >
75 static constexpr
unsigned int ImageIteratorDimension = Superclass::ImageIteratorDimension;
101 m_SpanBeginOffset = 0;
111 m_SpanBeginOffset = this->m_BeginOffset;
112 m_SpanEndOffset = this->m_BeginOffset +
static_cast< OffsetValueType >( this->m_Region.GetSize()[0] );
127 m_SpanEndOffset = this->m_Offset +
static_cast< OffsetValueType >( this->m_Region.GetSize()[0] )
128 - ( ind[0] - this->m_Region.GetIndex()[0] );
129 m_SpanBeginOffset = m_SpanEndOffset
144 m_SpanEndOffset = this->m_Offset +
static_cast< OffsetValueType >( this->m_Region.GetSize()[0] )
145 - ( ind[0] - this->m_Region.GetIndex()[0] );
146 m_SpanBeginOffset = m_SpanEndOffset
154 Superclass::GoToBegin();
157 m_SpanBeginOffset = this->m_BeginOffset;
158 m_SpanEndOffset = this->m_BeginOffset +
static_cast< OffsetValueType >( this->m_Region.GetSize()[0] );
168 Superclass::GoToEnd();
171 m_SpanEndOffset = this->m_EndOffset;
172 m_SpanBeginOffset = m_SpanEndOffset -
static_cast< OffsetValueType >( this->m_Region.GetSize()[0] );
184 this->m_Offset = m_SpanBeginOffset;
197 this->m_Offset = m_SpanEndOffset;
204 return this->m_Offset >= m_SpanEndOffset;
215 Superclass::SetIndex(ind);
216 m_SpanEndOffset = this->m_Offset +
static_cast< OffsetValueType >( this->m_Region.GetSize()[0] )
217 - ( ind[0] - this->m_Region.GetIndex()[0] );
218 m_SpanBeginOffset = m_SpanEndOffset -
static_cast< OffsetValueType >( this->m_Region.GetSize()[0] );
245 itkAssertInDebugAndIgnoreInReleaseMacro( !this->IsAtEndOfLine() );
256 itkAssertInDebugAndIgnoreInReleaseMacro( !this->IsAtEndOfLine() );
276 #ifndef ITK_MANUAL_INSTANTIATION
277 #include "itkImageScanlineConstIterator.hxx"
typename TImage::OffsetType OffsetType
typename TImage::InternalPixelType InternalPixelType
A multi-dimensional iterator templated over image type.
typename PixelContainer::Pointer PixelContainerPointer
typename TImage::PixelType PixelType
typename TImage::PixelContainer PixelContainer
A multi-dimensional image iterator templated over image type.
Self & operator=(const Self &it)
bool IsAtEndOfLine() const
ImageBaseType::SizeType SizeType
ImageScanlineConstIterator(const ImageType *ptr, const RegionType ®ion)
ImageBaseType::IndexType IndexType
typename TImage::IndexType IndexType
OffsetValueType m_SpanBeginOffset
typename TImage::SizeType SizeType
ImageScanlineConstIterator()
ImageScanlineConstIterator(const ImageIterator< TImage > &it)
void SetIndex(const IndexType &ind) override
A multi-dimensional iterator templated over image type that walks a region of pixels, scanline by scanline or in the direction of the fastest axis.
typename TImage::AccessorType AccessorType
typename TImage::RegionType RegionType
ImageScanlineConstIterator(const ImageConstIterator< TImage > &it)
ImageBaseType::RegionType RegionType
signed long OffsetValueType
OffsetValueType m_SpanEndOffset