Point Cloud Library (PCL)
1.11.1-dev
|
38 #include "organized_index_iterator.h"
71 void reset ()
override;
161 int x_dir = ( (delta_x > 0) ? 1 : -1 ) ;
162 int y_dir = ( (delta_y > 0) ? 1 : -1 ) ;
167 if(delta_x >= delta_y)
base class for iterators on 2-dimensional maps like images/organized clouds etc.
int index_plus_
increment pixel/point index in case of just an x-step (if dx > dy)
unsigned x_
current column index
int error_
current distance to the line
int x_plus_
increment of column index in case of just an x-step (if dx > dy)
Neighborhood
Neighborhood connectivity
unsigned index_
the index of the current pixel/point
int y_plus_
increment of row index in case of just an x-step (if dx > dy)
int error_max_
error threshold
LineIterator(unsigned x_start, unsigned y_start, unsigned x_end, unsigned y_end, unsigned width, const Neighborhood &neighborhood=Neighbor8)
Constructor.
unsigned x_end_
column index of end pixel/point
int y_minus_
increment of row index in case of just an y-step (if dx > dy)
unsigned width_
the width of the image/cloud
unsigned x_start_
column index of first pixel/point
~LineIterator()
Destructor.
void reset() override
resets the iterator to the beginning of the line
int index_minus_
increment pixel/point index in case of just an y-step (if dx > dy)
unsigned y_end_
row index of end pixel/point
bool isValid() const override
return whether the current visited pixel/point is valid or not.
int error_plus_
increment of error (distance) value in case of just an x-step (if dx > dy)
Organized Index Iterator for iterating over the "pixels" for a given line using the Bresenham algorit...
void init(const Neighborhood &neighborhood)
initializes the variables for the Bresenham algorithm
unsigned getColumnIndex() const override
returns the col index (x-coordinate) of the current pixel/point
unsigned getRowIndex() const override
returns the row index (y-coordinate) of the current pixel/point
unsigned y_start_
row index of first pixel/point
int x_minus_
increment of column index in case of just an y-step (if dx > dy)
int error_minus_
increment of error (distance) value in case of an y-step (if dx > dy)
void operator++() override
go to next pixel/point in image/cloud
unsigned y_
current row index