Iterator to scan rectangular windows. More...
#include <vgl_fwd.h>

Public Member Functions | |
| void | set_window_corners (T x1_, T y1_, T x2_, T y2_) |
| Define rectangular region to be [x1, x2] x [y1, y2]. More... | |
| void | set_window (T x, T y, T w, T h) |
| Define rectangular region to be [x-w, x+w] x [y-h, y+h]. More... | |
| void | set_window (T x, T y, T r) |
| Define rectangular region to be [x-r, x+r] x [y-r, y+r]. More... | |
| vgl_window_scan_iterator ()=default | |
| makes uninitialized iterator. More... | |
| vgl_window_scan_iterator (T x1_, T y1_, T x2_, T y2_) | |
| region is [x1, x2] x [y1, y2]. No assumption about x1<x2 or y1<y2. More... | |
| void | reset () override |
| Resets the scan iterator to before the first scan line. More... | |
| bool | next () override |
| Tries to move to the next scan line. More... | |
| int | scany () const override |
| y-coordinate of the current scan line. More... | |
| int | startx () const override |
| Returns starting x-value of the current scan line. More... | |
| int | endx () const override |
| Returns ending x-value of the current scan line. More... | |
| int | count () |
| Number of image points (= integer grid points) inside the region. More... | |
Public Attributes | |
| int | current_y |
Private Attributes | |
| int | x1 |
| int | y1 |
| int | x2 |
| int | y2 |
Iterator to scan rectangular windows.
This class is completely inlined.
|
inlinedefault |
makes uninitialized iterator.
|
inline |
region is [x1, x2] x [y1, y2]. No assumption about x1<x2 or y1<y2.
Definition at line 58 of file vgl_window_scan_iterator.h.
|
inlineinherited |
Number of image points (= integer grid points) inside the region.
Definition at line 48 of file vgl_region_scan_iterator.h.
|
inlineoverridevirtual |
Returns ending x-value of the current scan line.
endx() should be larger than startx(), unless the scan line is empty
Implements vgl_region_scan_iterator.
Definition at line 67 of file vgl_window_scan_iterator.h.
|
inlineoverridevirtual |
Tries to move to the next scan line.
Returns false if there are no more scan lines.
Implements vgl_region_scan_iterator.
Definition at line 64 of file vgl_window_scan_iterator.h.
|
inlineoverridevirtual |
Resets the scan iterator to before the first scan line.
After calling this function, next() needs to be called before startx() and endx() form a valid scan line.
Implements vgl_region_scan_iterator.
Definition at line 63 of file vgl_window_scan_iterator.h.
|
inlineoverridevirtual |
y-coordinate of the current scan line.
The next scan line is not guaranteed to have scany()+1; use next() instead.
Implements vgl_region_scan_iterator.
Definition at line 65 of file vgl_window_scan_iterator.h.
|
inline |
Define rectangular region to be [x-w, x+w] x [y-h, y+h].
Definition at line 47 of file vgl_window_scan_iterator.h.
|
inline |
Define rectangular region to be [x-r, x+r] x [y-r, y+r].
Definition at line 51 of file vgl_window_scan_iterator.h.
|
inline |
Define rectangular region to be [x1, x2] x [y1, y2].
Definition at line 29 of file vgl_window_scan_iterator.h.
|
inlineoverridevirtual |
Returns starting x-value of the current scan line.
startx() should be smaller than endx(), unless the scan line is empty
Implements vgl_region_scan_iterator.
Definition at line 66 of file vgl_window_scan_iterator.h.
| int vgl_window_scan_iterator< T >::current_y |
Definition at line 61 of file vgl_window_scan_iterator.h.
|
private |
Definition at line 25 of file vgl_window_scan_iterator.h.
|
private |
Definition at line 25 of file vgl_window_scan_iterator.h.
|
private |
Definition at line 25 of file vgl_window_scan_iterator.h.
|
private |
Definition at line 25 of file vgl_window_scan_iterator.h.
1.8.15