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

| ImagePyramid [Image Containers] |

Class template for logarithmically tapering image pyramids. More...

`#include <vigra/imagecontainer.hxx>`

List of all members.

## Public Types

typedef ImageType | value_type

## Public Member Functions

const_reference | back () const
reference | back ()
const_iterator | begin () const
iterator | begin ()
void | clear ()
bool | empty ()
const_iterator | end () const
iterator | end ()
const_reference | front () const
reference | front ()
int | highestLevel () const
| ImagePyramid (Alloc const &alloc=Alloc())
template<class SrcIterator, class SrcAccessor>
| ImagePyramid (int lowestLevel, int highestLevel, SrcIterator ul, SrcIterator lr, SrcAccessor src, int copyImageToLevel=0, Alloc const &alloc=Alloc())
| ImagePyramid (int lowestLevel, int highestLevel, const ImageType &image, int copyImageToLevel=0, Alloc const &alloc=Alloc())
| ImagePyramid (int lowestLevel, int highestLevel, const Diff2D &imageSize, int sizeAppliesToLevel=0, Alloc const &alloc=Alloc())
int | lowestLevel () const
bool | operator== (const ImagePyramid< ImageType, Alloc > &other) const
const_reference | operator[] (size_type index) const
reference | operator[] (size_type index)
const_reverse_iterator | rbegin () const
reverse_iterator | rbegin ()
const_reverse_iterator | rend () const
reverse_iterator | rend ()
void | resize (int lowestLevel, int highestLevel, const Diff2D &imageSize, int sizeAppliesToLevel=0)
size_type | size () const
void | swap (const ImagePyramid< ImageType, Alloc > &other)

## Detailed Description

### template<class ImageType, class Alloc = typename ImageType::allocator_type::template rebind<ImageType>::other>
class vigra::ImagePyramid< ImageType, Alloc >

Class template for logarithmically tapering image pyramids.

An ImagePyramid manages an array of images of the type given as template parameter, where each level has half the width and height of its predecessor. It actually represents a sequence of pyramid levels whose start and end index are configurable. For Burt-style pyramids, see also pyramidReduceBurtFilter and pyramidExpandBurtFilter.

A custimized allocator can be passed as a template argument and via the constructor. By default, the allocator of the `ImageType` is reused.

#include <vigra/imagecontainer.hxx>

Namespace: vigra

## Member Typedef Documentation

typedef ImageType value_type

the type of the contained values/images

## Constructor & Destructor Documentation

ImagePyramid | ( | int | lowestLevel,
|  | int | highestLevel,
|  | const Diff2D & | imageSize,
|  | int | sizeAppliesToLevel = `0`,
|  | Alloc const & | alloc = `Alloc()` |
| ) |  |  |

Init a pyramid between the given levels (inclusive).

Allocate the given imageSize at the pyramid level given in sizeAppliesToLevel (default: level 0 / bottom) and size the other levels using recursive reduction/expansion by factors of 2. Use the specified allocator for image creation. The image type must be default constructible and resizable. sizeAppliesToLevel must be the in range lowestLevel..highestLevel (inclusive).

ImagePyramid | ( | int | lowestLevel,
|  | int | highestLevel,
|  | const ImageType & | image,
|  | int | copyImageToLevel = `0`,
|  | Alloc const & | alloc = `Alloc()` |
| ) |  |  |

Init a pyramid between the given levels (inclusive).

Copy the given image into the pyramid level given in copyImageToLevel (default: level 0 / bottom) and size the other levels using recursive reduction/expansion by factors of 2 (their image data is not initialized). Use the specified allocator for image creation. The image type must be default constructible and resizable. sizeAppliesToLevel must be the in range lowestLevel..highestLevel (inclusive).

template<class SrcIterator, class SrcAccessor>
ImagePyramid | ( | int | lowestLevel,
|  | int | highestLevel,
|  | SrcIterator | ul,
|  | SrcIterator | lr,
|  | SrcAccessor | src,
|  | int | copyImageToLevel = `0`,
|  | Alloc const & | alloc = `Alloc()` |
| ) |  |  |

Init a pyramid between the given levels (inclusive).

Copy the image given by the range ul to lr into the pyramid level given in copyImageToLevel (default: level 0 / bottom) and size the other levels using recursive reduction/expansion by factors of 2 (their image data is not initialized). Use the specified allocator for image creation. The image type must be default constructible and resizable. sizeAppliesToLevel must be the in range lowestLevel..highestLevel (inclusive).

ImagePyramid | ( | Alloc const & | alloc = `Alloc()` | ) |

Init an empty pyramid. Use the specified allocator.

## Member Function Documentation

const_reference back | ( |  | ) | const

return the last image (highestLevel()). (STL-Vector interface)

reference back | ( |  | ) |

return the last image (highestLevel()). (STL-Vector interface)

const_iterator begin | ( |  | ) | const

Returns an iterator pointing to the first image (STL-Container interface)

iterator begin | ( |  | ) |

Returns an iterator pointing to the first image (STL-Container interface)

void clear | ( |  | ) |

Empty this array. (STL-Sequence interface)

bool empty | ( |  | ) |

Returns true if and only if there are no contained images. (STL-Container interface)

const_iterator end | ( |  | ) | const

Returns an iterator pointing behind the last image (STL-Container interface)

iterator end | ( |  | ) |

Returns an iterator pointing behind the last image (STL-Container interface)

const_reference front | ( |  | ) | const

return the first image (lowestLevel()). (STL-Sequence interface)

reference front | ( |  | ) |

return the first image (lowestLevel()). (STL-Sequence interface)

int highestLevel | ( |  | ) | const

Get the index of the highest allocated level of the pyramid.

int lowestLevel | ( |  | ) | const

Get the index of the lowest allocated level of the pyramid.

bool operator== | ( | const ImagePyramid< ImageType, Alloc > & | other | ) | const

Returns true if and only if both ImageArrays have exactly the same contents and all images did compare equal with the corresponding image in the other ImageArray. (STL-Forward Container interface)

const_reference operator[] | ( | size_type | index | ) | const

Operator for a vector-like access to the contained images (STL-Vector interface)

reference operator[] | ( | size_type | index | ) |

Operator for a vector-like access to the contained images (STL-Vector interface)

const_reverse_iterator rbegin | ( |  | ) | const

Returns a reverse_iterator pointing to the first image of the reversed view of this array (STL-Reversable Container interface)

reverse_iterator rbegin | ( |  | ) |

Returns a reverse_iterator pointing to the first image of the reversed view of this array (STL-Reversable Container interface)

const_reverse_iterator rend | ( |  | ) | const

Returns a reverse_iterator pointing behind the last image of the reversed view of this array (STL-Reversable Container interface)

reverse_iterator rend | ( |  | ) |

Returns a reverse_iterator pointing behind the last image of the reversed view of this array (STL-Reversable Container interface)

void resize | ( | int | lowestLevel,
|  | int | highestLevel,
|  | const Diff2D & | imageSize,
|  | int | sizeAppliesToLevel = `0` |
| ) |  |  |

Resize this ImageArray, throwing the last images away if you make the array smaller or appending new images of the right size at the end of the array if you make it larger. (STL-Sequence interface)

size_type size | ( |  | ) | const

Query size of this ImageArray, that is: the number of images. (STL-Container interface)

void swap | ( | const ImagePyramid< ImageType, Alloc > & | other | ) |

swap contents of this array with the contents of other (STL-Container interface)

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

- vigra/imagecontainer.hxx

© 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.7.1 (3 Dec 2010)