Go to the documentation of this file.
35 #ifndef NAV_GRID_ITERATORS_SPIRAL_H
36 #define NAV_GRID_ITERATORS_SPIRAL_H
93 double radius_sq,
unsigned int distance,
unsigned int max_distance,
106 bool isInside(
unsigned int x,
unsigned int y)
const;
116 #endif // NAV_GRID_ITERATORS_SPIRAL_H
Iterates over all of the valid indexes that lie within a circle from the center out.
Spiral(const nav_grid::NavGridInfo *info, double center_x, double center_y, double radius)
Public Constructor.
void increment() override
Increase the iterator to the next element.
std::unique_ptr< CircleOutline > internal_iterator_
Spiral & operator=(const Spiral &other)
Assignment Operator Required to ensure unique_ptr is set properly.
nav_grid::Index start_index_
bool isInside(unsigned int x, unsigned int y) const
Check if the center of the given index is within the circle.
Spiral begin() const override
Spiral end() const override
bool fieldsEqual(const Spiral &other) override
Additional check for whether fields of derived iterators are equal.
unsigned int max_distance_
void loadRing()
Given a new distance value, loads the internal iterator. If there are no valid values in the internal...