CGAL 6.1 - 2D and 3D Linear Geometry Kernel
Loading...
Searching...
No Matches

Functions

template<typename Kernel >
CGAL::Point_2< KernelCGAL::midpoint (const CGAL::Point_2< Kernel > &p, const CGAL::Point_2< Kernel > &q)
 computes the midpoint of the segment pq.
 
template<typename Kernel >
CGAL::Point_2< KernelCGAL::midpoint (const CGAL::Segment_2< Kernel > &s)
 computes the midpoint of the segment s.
 
template<typename Kernel >
CGAL::Point_3< KernelCGAL::midpoint (const CGAL::Point_3< Kernel > &p, const CGAL::Point_3< Kernel > &q)
 computes the midpoint of the segment pq.
 
template<typename Kernel >
CGAL::Point_3< KernelCGAL::midpoint (const CGAL::Segment_3< Kernel > &s)
 computes the midpoint of the segment s.
 

Function Documentation

◆ midpoint() [1/4]

template<typename Kernel >
CGAL::Point_2< Kernel > CGAL::midpoint ( const CGAL::Point_2< Kernel > &  p,
const CGAL::Point_2< Kernel > &  q 
)

#include <CGAL/Kernel/global_functions.h>

computes the midpoint of the segment pq.

Examples
Kernel_23/exact.cpp, and Kernel_23/points_and_segment.cpp.

◆ midpoint() [2/4]

template<typename Kernel >
CGAL::Point_3< Kernel > CGAL::midpoint ( const CGAL::Point_3< Kernel > &  p,
const CGAL::Point_3< Kernel > &  q 
)

#include <CGAL/Kernel/global_functions.h>

computes the midpoint of the segment pq.

◆ midpoint() [3/4]

template<typename Kernel >
CGAL::Point_2< Kernel > CGAL::midpoint ( const CGAL::Segment_2< Kernel > &  s)

#include <CGAL/Kernel/global_functions.h>

computes the midpoint of the segment s.

◆ midpoint() [4/4]

template<typename Kernel >
CGAL::Point_3< Kernel > CGAL::midpoint ( const CGAL::Segment_3< Kernel > &  s)

#include <CGAL/Kernel/global_functions.h>

computes the midpoint of the segment s.