The class Fuzzy_sphere<Traits> implements fuzzy d-dimensional spheres. A fuzzy sphere with radius r and fuzziness value ε has as outer approximation a sphere with radius r+ε and as inner approximation a sphere with radius r-ε.
#include <CGAL/Fuzzy_sphere.h>
Expects for the template argument a model of the concept SearchTraits, for example CGAL::Cartesian_d<double>.
Traits::Point_d | Point_d; | Point type. |
Traits::FT | FT; | Number type. |
Fuzzy_sphere<Traits> s ( Point_d center, FT radius, FT epsilon=FT(0), Traits t=Traits()); | |
Constructs a fuzzy sphere
centered at center with radius radius and fuzziness value epsilon.
|
In case Traits is Search_traits_adapter<Key,PointPropertyMap,BaseTraits>, the following constructor is also available:
Fuzzy_sphere<Traits> s ( Traits::Base::Point_d center, FT radius, FT epsilon=FT(0), Traits t=Traits()); | |
Constructs a fuzzy sphere centered at center with radius radius and fuzziness value epsilon.
|
bool | s.contains ( Point_d p) const | test whether s contains p. |
bool | s.inner_range_intersects ( Kd_tree_rectangle<FT> rectangle) const | |
test whether the inner sphere intersects the rectangle associated with a node of a tree. | ||
bool | s.outer_range_contains ( Kd_tree_rectangle<FT> rectangle) const | |
test whether the outer sphere encloses the rectangle associated with a node of a tree. |