[ VIGRA Homepage | Class Index | Function Index | File Index | Main Page ]
![]() |
MultiArrayView Class Template Reference | ![]() |
---|
Base class for, and view to, vigra::MultiArray. More...
#include "vigra/multi_array.hxx"
Public Types | |
typedef T | value_type |
typedef value_type & | reference |
typedef const value_type & | const_reference |
typedef value_type * | pointer |
typedef const value_type * | const_pointer |
typedef TinyVector< int, actual_dimension > | size_type |
typedef TinyVector< int, actual_dimension > | difference_type |
typedef detail::MultiIteratorChooser< C >::template Traverser< actual_dimension, T, T &, T * >::type | traverser |
typedef detail::MultiIteratorChooser< C >::template Traverser< actual_dimension, T, T const &, T const * >::type | const_traverser |
typedef MultiArrayView< N, T, C > | view_type |
typedef MultiArray< N, T > | matrix_type |
enum | ActualDimension |
Public Methods | |
MultiArrayView () | |
MultiArrayView (const difference_type &shape, pointer ptr) | |
MultiArrayView (const difference_type &shape, const difference_type &stride, pointer ptr) | |
reference | operator[] (const difference_type &d) |
const_reference | operator[] (const difference_type &d) const |
reference | operator() (int x) |
reference | operator() (int x, int y) |
reference | operator() (int x, int y, int z) |
reference | operator() (int x, int y, int z, int u) |
reference | operator() (int x, int y, int z, int u, int v) |
const_reference | operator() (int x) const |
const_reference | operator() (int x, int y) const |
const_reference | operator() (int x, int y, int z) const |
const_reference | operator() (int x, int y, int z, int u) const |
const_reference | operator() (int x, int y, int z, int u, int v) const |
template<unsigned int M> MultiArrayView< N-M, T, C > | bindOuter (const TinyVector< int, M > &d) const |
template<unsigned int M> MultiArrayView< N-M, T, StridedArrayTag > | bindInner (const TinyVector< int, M > &d) const |
template<unsigned int M> MultiArrayView< N-1, T, typename detail::MaybeStrided< M >::type > | bind (int d) const |
MultiArrayView< N-1, T, C > | bindOuter (int d) const |
MultiArrayView< N-1, T, StridedArrayTag > | bindInner (int d) const |
MultiArrayView< N-1, T, StridedArrayTag > | bindAt (int m, int d) const |
MultiArrayView< N-1, T, StridedArrayTag > | bindRow (int d) const |
MultiArrayView< N-1, T, C > | bindColumn (int d) const |
MultiArrayView | subarray (const difference_type &p, const difference_type &q) const |
MultiArrayView< N, T, StridedArrayTag > | stridearray (const difference_type &s) const |
std::size_t | elementCount () const |
const size_type & | size () const |
const difference_type & | shape () const |
int | shape (int n) const |
const difference_type & | stride () const |
int | stride (int n) const |
pointer | data () const |
traverser | traverser_begin () |
const_traverser | traverser_begin () const |
traverser | traverser_end () |
const_traverser | traverser_end () const |
Protected Attributes | |
difference_type | m_stride |
difference_type | m_shape |
pointer | m_ptr |
Detailed Description |
This class implements the interface of both MultiArray and MultiArrayView. By default, MultiArrayViews are tagged as unstrided. I necessary, strided arrays are constructed automatically by calls to a variant of the bind...() function.
#include "vigra/multi_array.hxx"
Namespace: vigra
|
const pointer type Reimplemented in MultiArray. |
|
const reference type (result of operator[] const) Reimplemented in MultiArray. |
|
const traverser (MultiIterator) type Reimplemented in MultiArray. |
|
difference type (used for offsetting) Reimplemented in MultiArray. |
|
the matrix type associated with this array. Reimplemented in MultiArray. |
|
pointer type Reimplemented in MultiArray. |
|
reference type (result of operator[]) Reimplemented in MultiArray. |
|
size type Reimplemented in MultiArray. |
|
traverser (MultiIterator) type Reimplemented in MultiArray. |
|
the array's value type Reimplemented in MultiArray. |
|
the view type associated with this array. Reimplemented in MultiArray. |
|
the array's actual dimensionality. This ensures that MultiArrayView can also be used for scalars (that is, when actual_dimension = (N==0) ? 1 : N |
|
default constructor: create an empty image of size 0. |
|
construct from shape and pointer |
|
construct from shape, strides (offset of a sample to the next) for every dimension) and pointer |
|
bind dimension M to index d. this reduces the dimensionality of the image to min { 1, N-1 } |
|
bind dimension m to index d. this reduces the dimensionality of the image to min { 1, N-1 } |
|
bind dimension m to index d. this reduces the dimensionality of the image to min { 1, N-1 } |
|
bind the innermost dimension to a certain index. this reduces the dimensionality of the image to min { 1, N-1 } |
|
bind the M innermost dimensions to certain indices. this reduces the dimensionality of the image to min { 1, N-M } |
|
bind the outmost dimension to a certain index. this reduces the dimensionality of the image to min { 1, N-1 } |
|
bind the M outmost dimensions to certain indices. this reduces the dimensionality of the image to min { 1, N-M } |
|
bind dimension m to index d. this reduces the dimensionality of the image to min { 1, N-1 } |
|
return the pointer to the image data |
|
number of the elements in the array. |
|
5D const array access. Use only if N == 5. |
|
4D const array access. Use only if N == 4. |
|
3D const array access. Use only if N == 3. |
|
2D const array access. Use only if N == 2. |
|
1D const array access. Use only if N == 1. |
|
5D array access. Use only if N == 5. |
|
4D array access. Use only if N == 4. |
|
3D array access. Use only if N == 3. |
|
2D array access. Use only if N == 2. |
|
1D array access. Use only if N == 1. |
|
array access. |
|
array access. |
|
return the array's shape at a certain dimension. |
|
return the array's shape. |
|
return the array's size (same as the shape). |
|
return the array's stride at a certain dimension. |
|
return the array's stride for every dimension. |
|
apply an additional striding to the image, thereby reducing the shape of the array. for example, multiplying the stride of dimension one by three turns an appropriately layed out (interleaved) rgb image into a single band image. |
|
create a rectangular subarray that spans between the points p and q, where p is in the subarray, q not. |
|
returns the N-dimensional MultiIterator pointing to the const first element in every dimension. |
|
returns the N-dimensional MultiIterator pointing to the first element in every dimension. |
|
returns the N-dimensional const MultiIterator pointing beyond the last element in dimension N, and to the first element in every other dimension. |
|
returns the N-dimensional MultiIterator pointing beyond the last element in dimension N, and to the first element in every other dimension. |
|
pointer to the image. |
|
the shape of the image pointed to is stored here. |
|
the strides (offset of a sample to the next) for every dimension are stored here. |
© Ullrich Köthe (koethe@informatik.uni-hamburg.de) |
html generated using doxygen and Python
|