![]() |
TerraLib 4.1
|
A raster iterator. More...
#include <TeRaster.h>
Public Member Functions | |
| iterator (int c0=0, int l0=0, int nc=0, int nl=0, int nb=0, TeRaster *pt=0) | |
| Constructor. | |
| virtual | ~iterator () |
| Destructor. | |
| virtual void | moveForward () |
| Move iterator forward. | |
| iterator & | operator++ () |
| Prefix move forward operator. | |
| iterator | operator++ (int) |
| Posfix move forward operator. | |
| int | currentLine () |
| Returns iterator current line. | |
| int | currentColumn () |
| Returns iterator current column. | |
| int | nBands (void) |
| Returns the number of bands. | |
| vector< double > | operator* () |
| Iterator de-referencing operator. | |
| double | operator* (int band) |
| Returns the value in a given band of a element pointed by the iterator. | |
| bool | operator== (const iterator &rhs) const |
| Returns whether two iterators point to the same element. | |
| bool | operator!= (const iterator &rhs) const |
| Returns whether two iterators point to the different elements. | |
Protected Attributes | |
| int | linCurrent_ |
| int | colCurrent_ |
| int | nLines_ |
| int | nCols_ |
| int | nBands_ |
| TeRaster * | raster_ |
A raster iterator.
An strucuture that allows the traversal over the raster elements (pixels) in a similar way as the STL iterators.
| TeRaster::iterator::iterator | ( | int | c0 = 0, |
| int | l0 = 0, |
||
| int | nc = 0, |
||
| int | nl = 0, |
||
| int | nb = 0, |
||
| TeRaster * | pt = 0 |
||
| ) | [inline] |
Constructor.
| c0 | initial column |
| l0 | initial line |
| nc | number of columns |
| nl | number of lines |
| nb | number of bands |
| pt | pointer to the raster to iterate |
| virtual TeRaster::iterator::~iterator | ( | ) | [inline, virtual] |
Destructor.
| int TeRaster::iterator::currentColumn | ( | ) | [inline] |
Returns iterator current column.
| int TeRaster::iterator::currentLine | ( | ) | [inline] |
Returns iterator current line.
| void TeRaster::iterator::moveForward | ( | ) | [virtual] |
Move iterator forward.
Reimplemented in TeRaster::iteratorPoly.
| int TeRaster::iterator::nBands | ( | void | ) | [inline] |
Returns the number of bands.
| bool TeRaster::iterator::operator!= | ( | const iterator & | rhs | ) | const |
Returns whether two iterators point to the different elements.
| double TeRaster::iterator::operator* | ( | int | band | ) |
Returns the value in a given band of a element pointed by the iterator.
Reimplemented in TeRaster::iteratorPoly.
| vector< double > TeRaster::iterator::operator* | ( | ) |
Iterator de-referencing operator.
Reimplemented in TeRaster::iteratorPoly.
| TeRaster::iterator & TeRaster::iterator::operator++ | ( | ) |
Prefix move forward operator.
Reimplemented in TeRaster::iteratorPoly.
| TeRaster::iterator TeRaster::iterator::operator++ | ( | int | ) |
Posfix move forward operator.
Reimplemented in TeRaster::iteratorPoly.
| bool TeRaster::iterator::operator== | ( | const iterator & | rhs | ) | const |
Returns whether two iterators point to the same element.
int TeRaster::iterator::colCurrent_ [protected] |
int TeRaster::iterator::linCurrent_ [protected] |
int TeRaster::iterator::nBands_ [protected] |
int TeRaster::iterator::nCols_ [protected] |
int TeRaster::iterator::nLines_ [protected] |
TeRaster* TeRaster::iterator::raster_ [protected] |