\( \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 5.0 - K Discrete Oriented Polytope Tree (K-DOP Tree)
CGAL::KDOP_tree::Construct_kdop< GeomTraits, N > Class Template Reference

#include <CGAL/KDOP_tree/KDOP_kdop.h>

Definition

template<typename GeomTraits, unsigned int N>
class CGAL::KDOP_tree::Construct_kdop< GeomTraits, N >

Class Construct_kdop is to compute k-dops of primitives, including 3D points, rays and triangles.

Examples:
KDOP_tree/kdop_polytopes.cpp.

Public Member Functions

Vec_direction kdop_directions () const
 Return directions of a k-dop. More...
 

Type

typedef std::vector< Vector_3 > Vec_direction
 Type of all directions of a k-dop.
 
typedef std::array< FT, N > Array_height
 Type of support heights.
 
typedef std::array< std::pair< FT, FT >, N > Array_height_2
 Type of support heights of a ray, containing source and second points.
 
typedef CGAL::KDOP_tree::KDOP_kdop< GeomTraits, N > result_type
 Type of k-dop.
 

Constructor

 Construct_kdop ()
 Default constructor, use pre-defined directions which are defined as follows:
k = 6: (1, 0, 0), (0, 1, 0), (0, 0, 1) and their opposites;
k = 14: (1, 0, 0), (0, 1, 0), (0, 0, 1), (1, 1, 1), (-1, 1, 1), (-1, -1, 1), (1, -1, 1) and their opposites;
k = 18: (1, 0, 0), (0, 1, 0), (0, 0, 1), (1, 1, 0), (1, 0, 1), (0, 1, 1), (1, -1, 0), (1, 0, -1), (0, -1, 1) and their opposites;
k = 26: (1, 0, 0), (0, 1, 0), (0, 0, 1), (1, 1, 1), (-1, 1, 1), (-1, -1, 1), (1, -1, 1), (1, 1, 0), (1, 0, 1), (0, 1, 1), (1, -1, 0), (1, 0, -1), (0, -1, 1) and their opposites. More...
 
 Construct_kdop (const Vec_direction &directions)
 Constructor with directions of k-dop.
 

Operators

result_type operator() (const Point_3 &p) const
 Compute the k-dop of a point.
 
result_type operator() (const Ray_3 &r) const
 Compute the k-dop of a ray.
 
result_type operator() (const Triangle_3 &t) const
 Compute the k-dop of a triangle.
 

Constructor & Destructor Documentation

template<typename GeomTraits , unsigned int N>
CGAL::KDOP_tree::Construct_kdop< GeomTraits, N >::Construct_kdop ( )

Default constructor, use pre-defined directions which are defined as follows:
k = 6: (1, 0, 0), (0, 1, 0), (0, 0, 1) and their opposites;
k = 14: (1, 0, 0), (0, 1, 0), (0, 0, 1), (1, 1, 1), (-1, 1, 1), (-1, -1, 1), (1, -1, 1) and their opposites;
k = 18: (1, 0, 0), (0, 1, 0), (0, 0, 1), (1, 1, 0), (1, 0, 1), (0, 1, 1), (1, -1, 0), (1, 0, -1), (0, -1, 1) and their opposites;
k = 26: (1, 0, 0), (0, 1, 0), (0, 0, 1), (1, 1, 1), (-1, 1, 1), (-1, -1, 1), (1, -1, 1), (1, 1, 0), (1, 0, 1), (0, 1, 1), (1, -1, 0), (1, 0, -1), (0, -1, 1) and their opposites.

Member Function Documentation

template<typename GeomTraits , unsigned int N>
Vec_direction CGAL::KDOP_tree::Construct_kdop< GeomTraits, N >::kdop_directions ( ) const

Return directions of a k-dop.

If directions are not defined by the user, pre-defined directions according to the prescribed number of directions are returned.