Class ThreadSafeIndex

Class Documentation

class ThreadSafeIndex

Small class that can be used by multiple threads that need mutually exclusive indexes to the same array, while still covering all elements.

The class attempts to ensure that the points are read in an order that gives good coverage over the pointcloud very quickly. This is so that the integrator can be terminated before all points have been read (due to time constraints) and still capture most of the geometry.

Public Functions

ThreadSafeIndex(size_t number_of_points)
bool getNextIndex(size_t *idx)

returns true if index is valid, false otherwise

void reset()