\( \newcommand{\E}{\mathrm{E}} \) \( \newcommand{\A}{\mathrm{A}} \) \( \newcommand{\R}{\mathrm{R}} \) \( \newcommand{\N}{\mathrm{N}} \) \( \newcommand{\Q}{\mathrm{Q}} \) \( \newcommand{\Z}{\mathrm{Z}} \) \( \def\ccSum #1#2#3{ \sum_{#1}^{#2}{#3} } \def\ccProd #1#2#3{ \sum_{#1}^{#2}{#3} }\)
CGAL 4.10 - 2D and 3D Linear Geometry Kernel
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
CGAL::compare_distance_to_point()

See Also
CGAL::compare_squared_distance()
CGAL::compare_signed_distance_to_line()
CGAL::compare_signed_distance_to_plane()
CGAL::has_larger_distance_to_point()
CGAL::has_larger_signed_distance_to_line()
CGAL::has_larger_signed_distance_to_plane()
CGAL::has_smaller_distance_to_point()
CGAL::has_smaller_signed_distance_to_line()
CGAL::has_smaller_signed_distance_to_plane()

Functions

template<typename Kernel >
Comparison_result CGAL::compare_distance_to_point (const CGAL::Point_2< Kernel > &p, const CGAL::Point_2< Kernel > &q, const CGAL::Point_2< Kernel > &r)
 compares the distances of points q and r to point p. More...
 
template<typename Kernel >
Comparison_result CGAL::compare_distance_to_point (const CGAL::Point_3< Kernel > &p, const CGAL::Point_3< Kernel > &q, const CGAL::Point_3< Kernel > &r)
 compares the distances of points q and r to point p. More...
 

Function Documentation

template<typename Kernel >
Comparison_result CGAL::compare_distance_to_point ( const CGAL::Point_2< Kernel > &  p,
const CGAL::Point_2< Kernel > &  q,
const CGAL::Point_2< Kernel > &  r 
)

compares the distances of points q and r to point p.

returns CGAL::SMALLER, iff q is closer to p than r, CGAL::LARGER, iff r is closer to p than q, and CGAL::EQUAL otherwise.

#include <CGAL/Kernel/global_functions.h>

template<typename Kernel >
Comparison_result CGAL::compare_distance_to_point ( const CGAL::Point_3< Kernel > &  p,
const CGAL::Point_3< Kernel > &  q,
const CGAL::Point_3< Kernel > &  r 
)

compares the distances of points q and r to point p.

returns CGAL::SMALLER, iff q is closer to p than r, CGAL::LARGER, iff r is closer to p than q, and CGAL::EQUAL otherwise.

#include <CGAL/Kernel/global_functions.h>