CGAL 5.6 - Spatial Sorting
|
#include <CGAL/Hilbert_sort_2.h>
The function object Hilbert_sort_2
sorts iterator ranges of Traits::Point_2
along a Hilbert curve by recursively subdividing at the median or the middle, depending on the PolicyTag
(see Section Hilbert Sorting for more information on the policies).
Traits | must be a model of the concept SpatialSortingTraits_2 . |
PolicyTag | is used to specify the strategy policy. Possible values are Hilbert_sort_median_policy (the default policy) or Hilbert_sort_middle_policy . |
ConcurrencyTag | enables sequential versus parallel algorithm. Possible values are Sequential_tag , Parallel_tag , and Parallel_if_available_tag . With parallelism enabled, sorting will be performed using up to four threads. Parallel sorting is available only when the median strategy policy (the default policy) is used. |
Creation | |
Hilbert_sort_2 (const Traits &traits=Traits()) | |
constructs an instance with traits as traits class instance. | |
Operations | |
template<class InputPointIterator > | |
void | operator() (InputPointIterator begin, InputPointIterator end) const |
It sorts the range [begin, end) . | |
void CGAL::Hilbert_sort_2< Traits, PolicyTag, ConcurrencyTag >::operator() | ( | InputPointIterator | begin, |
InputPointIterator | end | ||
) | const |
It sorts the range [begin, end)
.
InputPointIterator | must be a model of RandomAccessIterator with value type Traits::Point_2 . |