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

details Wrap aref vigra::MultiArrayView in VIGRA

Functions

template<class T >
BasicImageView< T > makeBasicImageView (MultiArray< 3, T > const &array)
template<class T >
BasicImageView< T > makeBasicImageView (MultiArrayView< 2, T, UnstridedArrayTag > const &array)
template<class T >
BasicImageView< RGBValue< T > > makeRGBImageView (MultiArray< 3, T > const &array)


Detailed Description

a vigra::BasicImageView


Function Documentation

BasicImageView<T> vigra::makeBasicImageView ( MultiArrayView< 2, T, UnstridedArrayTag > const &  array  ) 

Create a vigra::BasicImageView from an unstrided 2-dimensional vigra::MultiArrayView.

The vigra::BasicImageView will have the same value_type as the original vigra::MultiArrayView.

BasicImageView<T> vigra::makeBasicImageView ( MultiArray< 3, T > const &  array  ) 

Create a vigra::BasicImageView from a 3-dimensional vigra::MultiArray.

This wrapper flattens the two innermost dimensions of the array into single rows of the resulting image. The vigra::BasicImageView will have the same value_type as the original vigra::MultiArray.

BasicImageView<RGBValue<T> > vigra::makeRGBImageView ( MultiArray< 3, T > const &  array  ) 

Create a vigra::BasicImageView from a 3-dimensional vigra::MultiArray.

This wrapper only works if T is a scalar type and the array's innermost dimension has size 3. It then re-interprets the data array as a 2-dimensional array with value_type RGBValue<T>.

© 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.8.0 (20 Sep 2011)