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

imagecontainer.hxx
1/************************************************************************/
2/* */
3/* Copyright 1998-2002 by Ullrich Koethe */
4/* */
5/* This file is part of the VIGRA computer vision library. */
6/* The VIGRA Website is */
7/* http://hci.iwr.uni-heidelberg.de/vigra/ */
8/* Please direct questions, bug reports, and contributions to */
9/* ullrich.koethe@iwr.uni-heidelberg.de or */
10/* vigra@informatik.uni-hamburg.de */
11/* */
12/* Permission is hereby granted, free of charge, to any person */
13/* obtaining a copy of this software and associated documentation */
14/* files (the "Software"), to deal in the Software without */
15/* restriction, including without limitation the rights to use, */
16/* copy, modify, merge, publish, distribute, sublicense, and/or */
17/* sell copies of the Software, and to permit persons to whom the */
18/* Software is furnished to do so, subject to the following */
19/* conditions: */
20/* */
21/* The above copyright notice and this permission notice shall be */
22/* included in all copies or substantial portions of the */
23/* Software. */
24/* */
25/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND */
26/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES */
27/* OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND */
28/* NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT */
29/* HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, */
30/* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING */
31/* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR */
32/* OTHER DEALINGS IN THE SOFTWARE. */
33/* */
34/************************************************************************/
35
36#ifndef VIGRA_IMAGECONTAINER_HXX
37#define VIGRA_IMAGECONTAINER_HXX
38
39#include "utilities.hxx"
40#include "array_vector.hxx"
41#include "copyimage.hxx"
42#include <memory>
43
44 namespace vigra {
45
46/** \addtogroup ImageContainers Image Containers
47 Classes to manage multiple images (ImageArray..)
48*/
49//@{
50
51/********************************************************/
52/* */
53/* ImageArray */
54/* */
55/********************************************************/
56
57/** \brief Fundamental class template for arrays of equal-sized images.
58
59 An ImageArray manages an array of images of the type given as
60 template parameter. Use it like a ArrayVector<ImageType>, it has
61 the same interface, only operator< is missing from ImageArray. It
62 offers additional functions for resizing the images and querying
63 their common size. See \ref imageSize() for additional notes.
64
65 A customized allocator can be passed as a template argument and via the constructor.
66 By default, the allocator of the <tt>ImageType</tt> is reused.
67
68 <b>\#include</b> <vigra/imagecontainer.hxx> <br/>
69 Namespace: vigra
70*/
71 template <class ImageType,
72 class Alloc = typename std::allocator_traits<typename ImageType::allocator_type>::template rebind_alloc<ImageType> >
73 class ImageArray
74{
75 Size2D imageSize_;
76
77 protected:
78 typedef ArrayVector<ImageType, Alloc> ImageVector;
79 ImageVector images_;
80
81 public:
82 /** the type of the contained values/images
83 */
84 typedef ImageType value_type;
85
86 typedef typename ImageVector::iterator iterator;
87 typedef typename ImageVector::const_iterator const_iterator;
88 typedef typename ImageVector::reverse_iterator reverse_iterator;
89 typedef typename ImageVector::const_reverse_iterator const_reverse_iterator;
90 typedef typename ImageVector::reference reference;
91 typedef typename ImageVector::const_reference const_reference;
92#if !defined(_MSC_VER) || _MSC_VER >= 1300
93 typedef typename ImageVector::pointer pointer;
94#endif
95 typedef typename ImageVector::difference_type difference_type;
96 typedef typename ImageVector::size_type size_type;
97
98 /** init an array of numImages equal-sized images; use the specified allocator.
99 */
100 ImageArray(unsigned int numImages, const Diff2D &imageSize,
101 Alloc const & alloc = Alloc())
102 : imageSize_(imageSize),
103 images_(numImages, ImageType(), alloc)
104 {
105 for(unsigned int i=0; i<numImages; i++)
106 images_[i].resize(Size2D(imageSize));
107 }
108
109 /** Init an array of numImages equal-sized images. The size
110 depends on ImageType's default constructor (so it will
111 usually be 0x0); use the specified allocator.
112 */
113 ImageArray(unsigned int numImages= 0, Alloc const & alloc = Alloc())
114 : images_(numImages, alloc)
115 {
116 imageSize_= empty()? Size2D(0, 0) : front().size();
117 }
118
119 /** fill constructor: Init an array with numImages copies of
120 the given image. (STL-Sequence interface); use the specified allocator.
121 */
122 ImageArray(unsigned int numImages, const ImageType &image, Alloc const & alloc = Alloc())
123 : imageSize_(image.size()),
124 images_(numImages, image, alloc)
125 {
126 }
127
128 /** range constructor: Construct an array containing copies of
129 the images in [begin, end). Those images must all have the
130 same size, see \ref imageSize(). (STL-Sequence interface);
131 use the specified allocator.
132 */
133 template<class InputIterator>
134 ImageArray(InputIterator begin, InputIterator end, Alloc const & alloc = Alloc())
135 : imageSize_(begin!=end? (*begin).size() : Size2D(0,0)),
136 images_(begin, end, alloc)
137 {
138 }
139
140 virtual ~ImageArray() {}
141
142 /** Operator for a vector-like access to the contained images
143 (STL-Vector interface)
144 */
145 reference operator [](size_type index)
146 {
147 return images_[index];
148 }
149
150 /** Operator for a vector-like access to the contained images
151 (STL-Vector interface)
152 */
153 const_reference operator [](size_type index) const
154 {
155 return images_[index];
156 }
157
158 /** Returns an iterator pointing to the first image
159 (STL-Container interface)
160 */
161 iterator begin()
162 {
163 return images_.begin();
164 }
165
166 /** Returns an iterator pointing to the first image
167 (STL-Container interface)
168 */
169 const_iterator begin() const
170 {
171 return images_.begin();
172 }
173
174 /** Returns an iterator pointing behind the last image
175 (STL-Container interface)
176 */
177 iterator end()
178 {
179 return images_.end();
180 }
181
182 /** Returns an iterator pointing behind the last image
183 (STL-Container interface)
184 */
185 const_iterator end() const
186 {
187 return images_.end();
188 }
189
190 /** Returns a reverse_iterator pointing to the first image of
191 the reversed view of this array (STL-Reversable Container
192 interface)
193 */
194 reverse_iterator rbegin()
195 {
196 return images_.rbegin();
197 }
198
199 /** Returns a reverse_iterator pointing to the first image of
200 the reversed view of this array (STL-Reversable Container
201 interface)
202 */
203 const_reverse_iterator rbegin() const
204 {
205 return images_.rbegin();
206 }
207
208 /** Returns a reverse_iterator pointing behind the last image
209 of the reversed view of this array (STL-Reversable
210 Container interface)
211 */
212 reverse_iterator rend()
213 {
214 return images_.rend();
215 }
216
217 /** Returns a reverse_iterator pointing behind the last image
218 of the reversed view of this array (STL-Reversable
219 Container interface)
220 */
221 const_reverse_iterator rend() const
222 {
223 return images_.rend();
224 }
225
226 /** Query size of this ImageArray, that is: the number of
227 images. (STL-Container interface)
228 */
229 size_type size() const
230 {
231 return images_.size();
232 }
233
234 /** Query maximum size of this ImageArray, that is: the
235 max. parameter you may pass to resize(). (STL-Container
236 interface)
237 */
238 size_type max_size() const
239 {
240 return images_.max_size();
241 }
242
243 /** Returns true if and only if there are no contained
244 images. (STL-Container interface)
245 */
246 bool empty()
247 {
248 return images_.empty();
249 }
250
251 /** Returns true if and only if both ImageArrays have exactly
252 the same contents and all images did compare equal with the
253 corresponding image in the other ImageArray. (STL-Forward
254 Container interface)
255 */
256 bool operator ==(const ImageArray<ImageType, Alloc> &other)
257 {
258 return (imageSize() == other.imageSize())
259 && (images_ == other.images_);
260 }
261
262 /** Insert image at/before pos. (STL-Sequence interface)
263 */
264 iterator insert(iterator pos, const_reference image)
265 {
266 return images_.insert(pos, image);
267 }
268
269 /** Insert count copies of image at/before pos. (STL-Sequence
270 interface)
271 */
272 void insert (iterator pos, size_type count, const_reference image);
273
274 /** Insert copies of images from [begin, end) at/before
275 pos. (STL-Sequence interface)
276 */
277 template<class InputIterator>
278 void insert(iterator pos, InputIterator begin, InputIterator end)
279 {
280 images_.insert(pos, begin, end);
281 }
282
283 /** Removes the image at pos from this array. (STL-Sequence
284 interface)
285 */
286 iterator erase(iterator pos)
287 {
288 return images_.erase(pos);
289 }
290
291 /** Removes the images from [begin, end) from this
292 array. (STL-Sequence interface)
293 */
294 iterator erase(iterator begin, iterator end)
295 {
296 return images_.erase(begin, end);
297 }
298
299 /** Empty this array. (STL-Sequence interface)
300 */
301 void clear()
302 {
303 images_.clear();
304 }
305
306 /** Resize this ImageArray, throwing the last images away if
307 you make the array smaller or appending new images of the
308 right size at the end of the array if you make it
309 larger. (STL-Sequence interface)
310 */
311 void resize(size_type newSize)
312 {
313 if (newSize != size())
314 {
315 size_type oldSize= size();
316 images_.resize(newSize);
317 for (size_type i= oldSize; i<newSize; i++)
318 images_[i].resize(imageSize());
319 }
320 }
321
322 /** Resize this ImageArray, throwing the last images away if
323 you make the array smaller or appending new copies of image
324 at the end of the array if you make it larger.
325 precondition: <tt>image.size() == imageSize()</tt>
326 (STL-Sequence interface)
327 */
328 void resize(size_type newSize, ImageType &image)
329 {
330 if (newSize != size())
331 {
332 vigra_precondition(image.size() == imageSize(),
333 "trying to append images of wrong size to ImageArray with resize()");
334 images_.resize(newSize, image);
335 }
336 }
337
338 /** return the first image. (STL-Sequence interface)
339 */
340 reference front()
341 {
342 return images_.front();
343 }
344
345 /** return the first image. (STL-Sequence interface)
346 */
347 const_reference front() const
348 {
349 return images_.front();
350 }
351
352 /** return the last image. (STL-Vector interface)
353 */
354 reference back()
355 {
356 return images_.back();
357 }
358
359 /** return the last image. (STL-Vector interface)
360 */
361 const_reference back() const
362 {
363 return images_.back();
364 }
365
366 /** append image to array (STL-Back Insertion Sequence interface)
367 */
368 void push_back(const_reference image)
369 {
370 images_.push_back(image);
371 }
372
373 /** remove last image from array (STL-Back Insertion Sequence interface)
374 */
375 void pop_back()
376 {
377 images_.pop_back();
378 }
379
380 /** swap contents of this array with the contents of other
381 (STL-Container interface)
382 */
383 void swap(const_reference other)
384 {
385 Size2D oldImageSize = imageSize_;
386 images_.swap(other.images_);
387 imageSize_ = other.imageSize_;
388 other.imageSize_ = oldImageSize;
389 }
390
391 /** number of image objects for which memory has been allocated
392 (STL-Vector interface)
393 */
394 size_type capacity() const
395 {
396 return images_.capacity();
397 }
398
399 /** increase capacity(). (STL-Vector interface)
400 */
401 void reserve(size_type n)
402 {
403 images_.reserve(n);
404 }
405
406 /** Query the size of the contained images. ImageArray will
407 maintain an array of equal-sized images of this
408 size. However, <em>do not resize the contained images
409 manually</em>. ImageArray currently has no way to detect or
410 prevent this.
411 */
412 Size2D imageSize() const
413 { return imageSize_; }
414
415 /** Resize all images to a common new size (No-op if
416 <tt>newSize == imageSize()</tt>). See \ref imageSize() for
417 an important note about resizing the images.
418 */
419 virtual void resizeImages(const Diff2D &newSize)
420 {
421 if (newSize!=imageSize())
422 {
423 for(unsigned int i=0; i<size(); i++)
424 images_[i].resize(Size2D(newSize));
425 imageSize_= newSize;
426 }
427 }
428
429 /** Resize all images to a common new size (No-op if
430 <tt>newSize == imageSize()</tt>). See \ref imageSize() for
431 an important note about resizing the images.
432
433 (Convenience function, same as calling
434 <tt>resizeImages(Diff2D(width, height));</tt>.)
435 */
436 void resizeImages(int width, int height)
437 {
438 resizeImages(Size2D(width, height));
439 }
440};
441
442/********************************************************/
443/* */
444/* ImagePyramid */
445/* */
446/********************************************************/
447
448/** \brief Class template for logarithmically tapering image pyramids.
449
450 An ImagePyramid manages an array of images of the type given as
451 template parameter, where each level has half the width and height
452 of its predecessor. It actually represents a sequence of pyramid
453 levels whose start and end index are configurable.
454
455 To initialize all pyramid levels in the sense of a Gaussian pyramid,
456 use \ref pyramidReduceBurtFilter() and \ref pyramidExpandBurtFilter().
457 To create and reconstruct a Laplcaian pyramid, use
458 \ref pyramidReduceBurtLaplacian() and \ref pyramidExpandBurtLaplacian().
459
460 A customized allocator can be passed as a template argument and
461 via the constructor. By default, the allocator of the
462 <tt>ImageType</tt> is reused.
463
464 <b>\#include</b> <vigra/imagecontainer.hxx> <br/>
465 Namespace: vigra
466*/
467 template <class ImageType,
468 class Alloc = typename std::allocator_traits<typename ImageType::allocator_type>::template rebind_alloc<ImageType> >
469 class ImagePyramid
470{
471 int lowestLevel_, highestLevel_;
472
473 protected:
474 typedef ArrayVector<ImageType, Alloc> ImageVector;
475 ImageVector images_;
476
477 public:
478 /** the type of the contained values/images
479 */
480 typedef ImageType value_type;
481
482 typedef typename ImageVector::iterator iterator;
483 typedef typename ImageVector::const_iterator const_iterator;
484 typedef typename ImageVector::reverse_iterator reverse_iterator;
485 typedef typename ImageVector::const_reverse_iterator const_reverse_iterator;
486 typedef typename ImageVector::reference reference;
487 typedef typename ImageVector::const_reference const_reference;
488#if !defined(_MSC_VER) || _MSC_VER >= 1300
489 typedef typename ImageVector::pointer pointer;
490#endif
491 typedef typename ImageVector::difference_type difference_type;
492 typedef int size_type;
493
494 /** Init a pyramid between the given levels (inclusive).
495 *
496 * Allocate the given \a imageSize at the pyramid level given
497 * in \a sizeAppliesToLevel (default: level 0 / bottom) and
498 * size the other levels using recursive reduction/expansion
499 * by factors of 2. Use the specified allocator for image
500 * creation. The image type must be default constructible and
501 * resizable. sizeAppliesToLevel must be the in range
502 * lowestLevel..highestLevel (inclusive).
503 */
504 ImagePyramid(int lowestLevel, int highestLevel,
505 const Diff2D &imageSize, int sizeAppliesToLevel = 0,
506 Alloc const & alloc = Alloc())
507 : lowestLevel_(0), highestLevel_(-1),
508 images_(alloc)
509 {
510 resize(lowestLevel, highestLevel, imageSize, sizeAppliesToLevel);
511 }
512
513 /**
514 * Init a pyramid between the given levels (inclusive).
515 *
516 * Copy the given \a image into the pyramid level given in \a
517 * copyImageToLevel (default: level 0 / bottom) and size the
518 * other levels using recursive reduction/expansion by factors
519 * of 2 (their image data is not initialized). Use the
520 * specified allocator for image creation. The image type
521 * must be default constructible and resizable.
522 * sizeAppliesToLevel must be the in range
523 * lowestLevel..highestLevel (inclusive).
524 */
525 ImagePyramid(int lowestLevel, int highestLevel,
526 const ImageType &image, int copyImageToLevel = 0,
527 Alloc const & alloc = Alloc())
528 : lowestLevel_(0), highestLevel_(-1),
529 images_(alloc)
530 {
531 resize(lowestLevel, highestLevel, image.size(), copyImageToLevel);
532 copyImage(srcImageRange(image), destImage((*this)[copyImageToLevel]));
533 }
534
535 /**
536 * Init a pyramid between the given levels (inclusive).
537 *
538 * Copy the image given by the range \a ul to \a lr into the
539 * pyramid level given in \a copyImageToLevel (default: level
540 * 0 / bottom) and size the other levels using recursive
541 * reduction/expansion by factors of 2 (their image data is
542 * not initialized). Use the specified allocator for image
543 * creation. The image type must be default constructible and
544 * resizable. sizeAppliesToLevel must be the in range
545 * lowestLevel..highestLevel (inclusive).
546 */
547 template <class SrcIterator, class SrcAccessor>
548 ImagePyramid(int lowestLevel, int highestLevel,
549 SrcIterator ul, SrcIterator lr, SrcAccessor src,
550 int copyImageToLevel = 0,
551 Alloc const & alloc = Alloc())
552 : lowestLevel_(0), highestLevel_(-1),
553 images_(alloc)
554 {
555 resize(lowestLevel, highestLevel, lr - ul, copyImageToLevel);
556 copyImage(srcIterRange(ul, lr, src), destImage((*this)[copyImageToLevel]));
557 }
558
559 /** Init an empty pyramid. Use the specified allocator.
560 */
561 ImagePyramid(Alloc const & alloc = Alloc())
562 : lowestLevel_(0), highestLevel_(-1),
563 images_(alloc)
564 {}
565
566 virtual ~ImagePyramid() {}
567
568 /** Get the index of the lowest allocated level of the pyramid.
569 */
570 int lowestLevel() const
571 {
572 return lowestLevel_;
573 }
574
575 /** Get the index of the highest allocated level of the pyramid.
576 */
577 int highestLevel() const
578 {
579 return highestLevel_;
580 }
581
582 /** Operator for a vector-like access to the contained images
583 (STL-Vector interface)
584 */
585 reference operator [](size_type index)
586 {
587 return images_[index - lowestLevel_];
588 }
589
590 /** Operator for a vector-like access to the contained images
591 (STL-Vector interface)
592 */
593 const_reference operator [](size_type index) const
594 {
595 return images_[index - lowestLevel_];
596 }
597
598 /** Returns an iterator pointing to the first image
599 (STL-Container interface)
600 */
601 iterator begin()
602 {
603 return images_.begin();
604 }
605
606 /** Returns an iterator pointing to the first image
607 (STL-Container interface)
608 */
609 const_iterator begin() const
610 {
611 return images_.begin();
612 }
613
614 /** Returns an iterator pointing behind the last image
615 (STL-Container interface)
616 */
617 iterator end()
618 {
619 return images_.end();
620 }
621
622 /** Returns an iterator pointing behind the last image
623 (STL-Container interface)
624 */
625 const_iterator end() const
626 {
627 return images_.end();
628 }
629
630 /** Returns a reverse_iterator pointing to the first image of
631 the reversed view of this array (STL-Reversable Container
632 interface)
633 */
634 reverse_iterator rbegin()
635 {
636 return images_.rbegin();
637 }
638
639 /** Returns a reverse_iterator pointing to the first image of
640 the reversed view of this array (STL-Reversable Container
641 interface)
642 */
643 const_reverse_iterator rbegin() const
644 {
645 return images_.rbegin();
646 }
647
648 /** Returns a reverse_iterator pointing behind the last image
649 of the reversed view of this array (STL-Reversable
650 Container interface)
651 */
652 reverse_iterator rend()
653 {
654 return images_.rend();
655 }
656
657 /** Returns a reverse_iterator pointing behind the last image
658 of the reversed view of this array (STL-Reversable
659 Container interface)
660 */
661 const_reverse_iterator rend() const
662 {
663 return images_.rend();
664 }
665
666 /** Query size of this ImageArray, that is: the number of
667 images. (STL-Container interface)
668 */
669 size_type size() const
670 {
671 return images_.size();
672 }
673
674 /** Returns true if and only if there are no contained
675 images. (STL-Container interface)
676 */
677 bool empty()
678 {
679 return images_.empty();
680 }
681
682 /** Returns true if and only if both ImageArrays have exactly
683 the same contents and all images did compare equal with the
684 corresponding image in the other ImageArray. (STL-Forward
685 Container interface)
686 */
687 bool operator ==(const ImagePyramid<ImageType, Alloc> &other) const
688 {
689 return (lowestLevel_ == other.lowestLevel_) && (highestLevel_ == other.highestLevel_) &&
690 (images_ == other.images_);
691 }
692
693 /** Empty this array. (STL-Sequence interface)
694 */
695 void clear()
696 {
697 images_.clear();
698 lowestLevel_ = 0;
699 highestLevel_ = -1;
700 }
701
702 /** Resize this ImageArray, throwing the last images away if
703 you make the array smaller or appending new images of the
704 right size at the end of the array if you make it
705 larger. (STL-Sequence interface)
706 */
707 void resize(int lowestLevel, int highestLevel,
708 const Diff2D &imageSize, int sizeAppliesToLevel = 0)
709 {
710 vigra_precondition(lowestLevel <= highestLevel,
711 "ImagePyramid::resize(): lowestLevel <= highestLevel required.");
712 vigra_precondition(lowestLevel <= sizeAppliesToLevel && sizeAppliesToLevel <= highestLevel,
713 "ImagePyramid::resize(): sizeAppliesToLevel must be between lowest and highest level (inclusive).");
714
715 ImageVector images(highestLevel - lowestLevel + 1, ImageType());
716
717 images[sizeAppliesToLevel - lowestLevel].resize(imageSize);
718 for(int i=sizeAppliesToLevel + 1; i<=highestLevel; ++i)
719 {
720 unsigned int w = (images[i - 1 - lowestLevel].width() + 1) / 2;
721 unsigned int h = (images[i - 1 - lowestLevel].height() + 1) / 2;
722 images[i - lowestLevel].resize(w, h);
723 }
724 for(int i=sizeAppliesToLevel - 1; i>=lowestLevel; --i)
725 {
726 unsigned int w = 2*images[i + 1 - lowestLevel].width() - 1;
727 unsigned int h = 2*images[i + 1 - lowestLevel].height() - 1;
728 images[i - lowestLevel].resize(w, h);
729 }
730
731 images_.swap(images);
732 lowestLevel_ = lowestLevel;
733 highestLevel_ = highestLevel;
734 }
735
736 /** return the first image (lowestLevel()). (STL-Sequence interface)
737 */
738 reference front()
739 {
740 return images_.front();
741 }
742
743 /** return the first image (lowestLevel()). (STL-Sequence interface)
744 */
745 const_reference front() const
746 {
747 return images_.front();
748 }
749
750 /** return the last image (highestLevel()). (STL-Vector interface)
751 */
752 reference back()
753 {
754 return images_.back();
755 }
756
757 /** return the last image (highestLevel()). (STL-Vector interface)
758 */
759 const_reference back() const
760 {
761 return images_.back();
762 }
763
764 /** swap contents of this array with the contents of other
765 (STL-Container interface)
766 */
767 void swap(ImagePyramid<ImageType, Alloc> &other)
768 {
769 images_.swap(other.images_);
770 std::swap(lowestLevel_, other.lowestLevel_);
771 std::swap(highestLevel_, other.highestLevel_);
772 }
773};
774
775//@}
776
777} // namespace vigra
778
779#endif // VIGRA_IMAGECONTAINER_HXX
vigra::ArrayVector
Definition array_vector.hxx:514
vigra::Diff2D
Two dimensional difference vector.
Definition diff2d.hxx:186
vigra::ImageArray
Fundamental class template for arrays of equal-sized images.
Definition imagecontainer.hxx:74
vigra::ImageArray::pop_back
void pop_back()
Definition imagecontainer.hxx:375
vigra::ImageArray::rend
const_reverse_iterator rend() const
Definition imagecontainer.hxx:221
vigra::ImageArray::front
const_reference front() const
Definition imagecontainer.hxx:347
vigra::ImageArray::insert
void insert(iterator pos, size_type count, const_reference image)
vigra::ImageArray::resize
void resize(size_type newSize, ImageType &image)
Definition imagecontainer.hxx:328
vigra::ImageArray::begin
const_iterator begin() const
Definition imagecontainer.hxx:169
vigra::ImageArray::push_back
void push_back(const_reference image)
Definition imagecontainer.hxx:368
vigra::ImageArray::empty
bool empty()
Definition imagecontainer.hxx:246
vigra::ImageArray::ImageArray
ImageArray(unsigned int numImages, const ImageType &image, Alloc const &alloc=Alloc())
Definition imagecontainer.hxx:122
vigra::ImageArray::reserve
void reserve(size_type n)
Definition imagecontainer.hxx:401
vigra::ImageArray::insert
iterator insert(iterator pos, const_reference image)
Definition imagecontainer.hxx:264
vigra::ImageArray::resizeImages
virtual void resizeImages(const Diff2D &newSize)
Definition imagecontainer.hxx:419
vigra::ImageArray< ImageType, Alloc >::size
size_type size() const
Definition imagecontainer.hxx:229
vigra::ImageArray::back
const_reference back() const
Definition imagecontainer.hxx:361
vigra::ImageArray::rend
reverse_iterator rend()
Definition imagecontainer.hxx:212
vigra::ImageArray::front
reference front()
Definition imagecontainer.hxx:340
vigra::ImageArray::swap
void swap(const_reference other)
Definition imagecontainer.hxx:383
vigra::ImageArray::resize
void resize(size_type newSize)
Definition imagecontainer.hxx:311
vigra::ImageArray::resizeImages
void resizeImages(int width, int height)
Definition imagecontainer.hxx:436
vigra::ImageArray::insert
void insert(iterator pos, InputIterator begin, InputIterator end)
Definition imagecontainer.hxx:278
vigra::ImageArray::max_size
size_type max_size() const
Definition imagecontainer.hxx:238
vigra::ImageArray::operator[]
reference operator[](size_type index)
Definition imagecontainer.hxx:145
vigra::ImageArray< ImageType, Alloc >::value_type
ImageType value_type
Definition imagecontainer.hxx:84
vigra::ImageArray< ImageType, Alloc >::imageSize
Size2D imageSize() const
Definition imagecontainer.hxx:412
vigra::ImageArray::ImageArray
ImageArray(InputIterator begin, InputIterator end, Alloc const &alloc=Alloc())
Definition imagecontainer.hxx:134
vigra::ImageArray::clear
void clear()
Definition imagecontainer.hxx:301
vigra::ImageArray::ImageArray
ImageArray(unsigned int numImages, const Diff2D &imageSize, Alloc const &alloc=Alloc())
Definition imagecontainer.hxx:100
vigra::ImageArray< ImageType, Alloc >::end
iterator end()
Definition imagecontainer.hxx:177
vigra::ImageArray::ImageArray
ImageArray(unsigned int numImages=0, Alloc const &alloc=Alloc())
Definition imagecontainer.hxx:113
vigra::ImageArray::end
const_iterator end() const
Definition imagecontainer.hxx:185
vigra::ImageArray::rbegin
reverse_iterator rbegin()
Definition imagecontainer.hxx:194
vigra::ImageArray::capacity
size_type capacity() const
Definition imagecontainer.hxx:394
vigra::ImageArray::erase
iterator erase(iterator begin, iterator end)
Definition imagecontainer.hxx:294
vigra::ImageArray< ImageType, Alloc >::begin
iterator begin()
Definition imagecontainer.hxx:161
vigra::ImageArray::operator==
bool operator==(const ImageArray< ImageType, Alloc > &other)
Definition imagecontainer.hxx:256
vigra::ImageArray::rbegin
const_reverse_iterator rbegin() const
Definition imagecontainer.hxx:203
vigra::ImageArray::back
reference back()
Definition imagecontainer.hxx:354
vigra::ImageArray::erase
iterator erase(iterator pos)
Definition imagecontainer.hxx:286
vigra::ImagePyramid
Class template for logarithmically tapering image pyramids.
Definition imagecontainer.hxx:470
vigra::ImagePyramid::rend
const_reverse_iterator rend() const
Definition imagecontainer.hxx:661
vigra::ImagePyramid::front
const_reference front() const
Definition imagecontainer.hxx:745
vigra::ImagePyramid::begin
const_iterator begin() const
Definition imagecontainer.hxx:609
vigra::ImagePyramid::resize
void resize(int lowestLevel, int highestLevel, const Diff2D &imageSize, int sizeAppliesToLevel=0)
Definition imagecontainer.hxx:707
vigra::ImagePyramid::empty
bool empty()
Definition imagecontainer.hxx:677
vigra::ImagePyramid::ImagePyramid
ImagePyramid(int lowestLevel, int highestLevel, SrcIterator ul, SrcIterator lr, SrcAccessor src, int copyImageToLevel=0, Alloc const &alloc=Alloc())
Definition imagecontainer.hxx:548
vigra::ImagePyramid::ImagePyramid
ImagePyramid(Alloc const &alloc=Alloc())
Definition imagecontainer.hxx:561
vigra::ImagePyramid::highestLevel
int highestLevel() const
Definition imagecontainer.hxx:577
vigra::ImagePyramid::size
size_type size() const
Definition imagecontainer.hxx:669
vigra::ImagePyramid::back
const_reference back() const
Definition imagecontainer.hxx:759
vigra::ImagePyramid::rend
reverse_iterator rend()
Definition imagecontainer.hxx:652
vigra::ImagePyramid::front
reference front()
Definition imagecontainer.hxx:738
vigra::ImagePyramid::swap
void swap(ImagePyramid< ImageType, Alloc > &other)
Definition imagecontainer.hxx:767
vigra::ImagePyramid::operator[]
reference operator[](size_type index)
Definition imagecontainer.hxx:585
vigra::ImagePyramid::ImagePyramid
ImagePyramid(int lowestLevel, int highestLevel, const Diff2D &imageSize, int sizeAppliesToLevel=0, Alloc const &alloc=Alloc())
Definition imagecontainer.hxx:504
vigra::ImagePyramid::value_type
ImageType value_type
Definition imagecontainer.hxx:480
vigra::ImagePyramid::clear
void clear()
Definition imagecontainer.hxx:695
vigra::ImagePyramid::operator==
bool operator==(const ImagePyramid< ImageType, Alloc > &other) const
Definition imagecontainer.hxx:687
vigra::ImagePyramid::ImagePyramid
ImagePyramid(int lowestLevel, int highestLevel, const ImageType &image, int copyImageToLevel=0, Alloc const &alloc=Alloc())
Definition imagecontainer.hxx:525
vigra::ImagePyramid::end
iterator end()
Definition imagecontainer.hxx:617
vigra::ImagePyramid::end
const_iterator end() const
Definition imagecontainer.hxx:625
vigra::ImagePyramid::rbegin
reverse_iterator rbegin()
Definition imagecontainer.hxx:634
vigra::ImagePyramid::begin
iterator begin()
Definition imagecontainer.hxx:601
vigra::ImagePyramid::lowestLevel
int lowestLevel() const
Definition imagecontainer.hxx:570
vigra::ImagePyramid::rbegin
const_reverse_iterator rbegin() const
Definition imagecontainer.hxx:643
vigra::ImagePyramid::back
reference back()
Definition imagecontainer.hxx:752
vigra::Size2D
Two dimensional size object.
Definition diff2d.hxx:483
vigra
vigra::copyImage
void copyImage(...)
Copy source image into destination image.
utilities.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.12.4