[ VIGRA Homepage | Function Index | Class Index | Namespaces | File List | Main Page ]

ConstValueIterator< PIXELTYPE > Class Template Reference

Iterator that always returns the constant specified in the constructor. More...

#include <vigra/imageiterator.hxx>

Public Types

typedef IteratorAdaptor< ConstValueIteratorPolicy< PIXELTYPE > > column_iterator
 
typedef Diff2D difference_type
 
typedef PIXELTYPE constindex_reference
 
typedef image_traverser_tag iterator_category
 
typedef std::ptrdiff_t MoveX
 
typedef std::ptrdiff_t MoveY
 
typedef PIXELTYPE PixelType
 
typedef PIXELTYPE constpointer
 
typedef PIXELTYPE constreference
 
typedef IteratorAdaptor< ConstValueIteratorPolicy< PIXELTYPE > > row_iterator
 
typedef PIXELTYPE value_type
 

Public Member Functions

column_iterator columnIterator () const
 
 ConstValueIterator ()
 
 ConstValueIterator (ConstValueIterator const &v)
 
 ConstValueIterator (PixelType const &v)
 
bool operator!= (ConstValueIterator const &r) const
 
index_reference operator() (std::ptrdiff_t const &, std::ptrdiff_t const &) const
 
reference operator* () const
 
ConstValueIterator operator+ (Diff2D const &d) const
 
ConstValueIteratoroperator+= (Diff2D const &d)
 
Diff2D operator- (ConstValueIterator const &r) const
 
ConstValueIterator operator- (Diff2D const &d) const
 
ConstValueIteratoroperator-= (Diff2D const &d)
 
pointer operator-> () const
 
ConstValueIteratoroperator= (ConstValueIterator const &v)
 
bool operator== (ConstValueIterator const &r) const
 
index_reference operator[] (Diff2D const &) const
 
row_iterator rowIterator () const
 

Specify coordinate direction for navigation commands

std::ptrdiff_t x
 refer to x coordinate
 
std::ptrdiff_t y
 refer to y coordinate
 

Detailed Description

template<class PIXELTYPE>
class vigra::ConstValueIterator< PIXELTYPE >

Iterator that always returns the constant specified in the constructor.

This iterator can be used to simulate an image that does not actually exist.

#include <vigra/imageiterator.hxx>
Namespace: vigra

Member Typedef Documentation

◆ value_type

The type of the constant the iterator holds.

◆ PixelType

The type of the constant the iterator holds.

◆ reference

the iterator's reference type (return type of *iter)

◆ index_reference

the iterator's index reference type (return type of iter[diff])

◆ pointer

the iterator's pointer type (return type of iter.operator->())

◆ difference_type

the iterator's difference type (argument type of iter[diff])

◆ iterator_category

template<class PIXELTYPE >
typedef image_traverser_tag iterator_category

the iterator tag (image traverser)

◆ row_iterator

template<class PIXELTYPE >
typedef IteratorAdaptor<ConstValueIteratorPolicy<PIXELTYPE> > row_iterator

The associated row iterator.

◆ column_iterator

template<class PIXELTYPE >
typedef IteratorAdaptor<ConstValueIteratorPolicy<PIXELTYPE> > column_iterator

The associated column iterator.

◆ MoveX

template<class PIXELTYPE >
typedef std::ptrdiff_t MoveX

Let operations act in X direction

◆ MoveY

template<class PIXELTYPE >
typedef std::ptrdiff_t MoveY

Let operations act in Y direction

Constructor & Destructor Documentation

◆ ConstValueIterator() [1/3]

Default Constructor. (the constant is set to NumericTraits<PIXELTYPE>::zero() )

◆ ConstValueIterator() [2/3]

Construct with given constant.

◆ ConstValueIterator() [3/3]

Copy Constructor.

Member Function Documentation

◆ operator=()

Copy Assigment.

◆ operator+=()

Move iterator by specified distance.

◆ operator-=()

Move iterator by specified distance.

◆ operator+()

template<class PIXELTYPE >
ConstValueIterator operator+ ( Diff2D const d) const

Create iterator at specified distance.

◆ operator-() [1/2]

template<class PIXELTYPE >
ConstValueIterator operator- ( Diff2D const d) const

Create iterator at specified distance.

◆ operator-() [2/2]

Compute distance between two iterators

◆ operator==()

template<class PIXELTYPE >
bool operator== ( ConstValueIterator< PIXELTYPE > const r) const

Equality.

◆ operator!=()

template<class PIXELTYPE >
bool operator!= ( ConstValueIterator< PIXELTYPE > const r) const

Inequality.

◆ operator*()

template<class PIXELTYPE >
reference operator* ( ) const

Read current pixel (return specified constant).

◆ operator->()

template<class PIXELTYPE >
pointer operator-> ( ) const

Call member function for stored constant.

◆ operator()()

template<class PIXELTYPE >
index_reference operator() ( std::ptrdiff_t const ,
std::ptrdiff_t const  
) const

Read pixel at a distance (return specified constant).

◆ operator[]()

template<class PIXELTYPE >
index_reference operator[] ( Diff2D const ) const

Read pixel at a distance (return specified constant).

◆ rowIterator()

template<class PIXELTYPE >
row_iterator rowIterator ( ) const

Get row iterator at current position (which will also hold the constant).

◆ columnIterator()

template<class PIXELTYPE >
column_iterator columnIterator ( ) const

Get column iterator at current position (which will also hold the constant).


The documentation for this class was generated from the following file:

© Ullrich Köthe (ullrich.koethe@iwr.uni-heidelberg.de)
Heidelberg Collaboratory for Image Processing, University of Heidelberg, Germany

html generated using doxygen and Python
vigra 1.12.1