![]() |
All higher dimensional spatial sorting algorithms provided in Cgal are parameterized by a traits class Traits, which defines the primitives (objects and predicates) that the sorting algorithms use. SpatialSortingTraits_d defines the complete set of primitives required in these functions and functors.
SpatialSortingTraits_d::Point_d | |
The point type on which the sorting algorithms operate.
| |
SpatialSortingTraits_d::Point_dimension_d | |
Functor object type returning the dimension of a Point_d.
Must provide
int operator()(Point_d p) returning the dimension of p.
| |
SpatialSortingTraits_d::Compute_coordinate_d | |
Functor object type returning the coordinates of a Point_d.
Must provide
FT operator()(Point_d p, int i) returning the ith
coordinate of p. FT is a type that can be used as
argument of CGAL::to_double.
| |
SpatialSortingTraits_d::Less_coordinate_d | |
Binary predicate object type comparing Point_ds
along some coordinate.
Must provide
bool operator()(Point_d p, Point_d q, int i) where true
is returned iff pi < qi,
where pi and qi denote ith coordinate of point p and q,
respectively.
|
Only a copy constructor is required.
SpatialSortingTraits_d traits ( t); |
The following member functions to create instances of the above predicate object types must exist.
Point_dimension_d | traits.point_dimension_d_object () | |
Compute_coordinate_d | traits.compute_coordinate_d_object () | |
Less_coordinate_d | traits.less_coordinate_d_object () |
Any Cgal d dimensional kernel.
CGAL::Spatial_sort_traits_adapter_d<Base_traits,PointPropertyMap>.