position_iterator Struct Template Reference

#include <position_iterator.hpp>

List of all members.

Detailed Description

template<typename Deref, int Dim>
struct boost::gil::position_iterator< Deref, Dim >

An iterator that remembers its current X,Y position and invokes a function object with it upon dereferencing. Models PixelIteratorConcept. Used to create virtual image views. Models: StepIteratorConcept, PixelIteratorConcept, PixelBasedConcept, HasDynamicXStepTypeConcept.

Public Types

typedef iterator_facade
< position_iterator< Deref,
Dim >, typename
typename Deref::reference,
axis< Dim >::coord_t > 
typedef parent_t::difference_type difference_type
typedef parent_t::reference reference
typedef Deref::argument_type point_t

Public Member Functions

 position_iterator (const point_t &p, const point_t &step, const Deref &d)
 position_iterator (const position_iterator &p)
template<typename D>
 position_iterator (const position_iterator< D, Dim > &p)
position_iteratoroperator= (const position_iterator &p)
const point_t & pos () const
const point_t & step () const
const Deref & deref_fn () const
void set_step (difference_type s)
reference operator[] (difference_type d) const


struct position_iterator
class boost::iterator_core_access

Member Function Documentation

reference operator[] ( difference_type  d  )  const [inline]

For some reason operator[] provided by iterator_adaptor returns a custom class that is convertible to reference We require our own reference because it is registered in iterator_traits

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

Generated on Sat May 2 13:50:18 2009 for Generic Image Library by  doxygen 1.5.6