Iterates through multidmensional arrays.
More...
#include <glv_model.h>
List of all members.
Public Member Functions |
| | Indexer (int size1=1, int size2=1, int size3=1) |
| | Indexer (const int *sizes) |
|
bool | operator() () const |
| | Perform one iteration returning whether more elements exist.
|
|
int | operator[] (int dim) const |
| | Get current index within a dimension.
|
|
int | indexFlat (int dim1, int dim2) const |
| | Get one-dimensional index into plane.
|
|
double | frac (int dim) const |
| | Get current fractional position within a dimension.
|
|
int | size (int dim) const |
| | Get size of a dimension.
|
|
int | size (int dim1, int dim2) const |
| | Get product of sizes of two dimensions.
|
|
int | size () const |
| | Get product of sizes of all dimensions.
|
|
Indexer & | reset () |
| | Reset position indices.
|
|
Indexer & | shape (const int *sizes, int n) |
| | Set dimensions.
|
|
Indexer & | shape (int size1, int size2=1, int size3=1) |
| | Set dimensions.
|
Detailed Description
Iterates through multidmensional arrays.
Constructor & Destructor Documentation
| glv::Indexer::Indexer |
( |
int |
size1 = 1, |
|
|
int |
size2 = 1, |
|
|
int |
size3 = 1 | |
|
) |
| | [inline] |
- Parameters:
-
| [in] | size1 | size of dimension 1 |
| [in] | size2 | size of dimension 2 |
| [in] | size3 | size of dimension 3 |
| glv::Indexer::Indexer |
( |
const int * |
sizes |
) |
[inline] |
- Parameters:
-
| [in] | sizes | array of dimension sizes |
The documentation for this class was generated from the following file:
- /Users/ljp/code/glv-svn/trunk/include/glv_model.h