CGAL 6.1 - 3D Convex Hulls
Loading...
Searching...
No Matches
CGAL::Convex_hull_hierarchy< PolygonMesh > Struct Template Reference

#include <CGAL/convex_hull_hierarchy.h>

Definition

template<class PolygonMesh>
struct CGAL::Convex_hull_hierarchy< PolygonMesh >

This class wrapp a convex hull with a data structure optimized for finding the extreme point of the convex hull in a given direction.

In particular, this operation is called by CGAL::Convex_hull_3::do_intersect and therefore, this class is optimized for very fast intersection tests.

Template Parameters
PolygonMeshThe polygon mesh structure used to construct each level of the hierarchy. Must be a model of MutableFaceGraph. an internal property map for CGAL::vertex_point_t must be available A point type Point is deduced from it. There is no requirement on Point, besides being default constructible and assignable. In typical use cases it will be a 3D point type.

Public Types

typedef PolygonMesh::Point Point
 The point type.
 

Public Member Functions

template<typename VertexListGraph , typename NamedParameters = parameters::Default_named_parameters>
 Convex_hull_hierarchy (const VertexListGraph &g, const NamedParameters &np=parameters::default_values)
 constructor taking the points associated to the vertices of g.
 
template<typename RangeIterator , typename Traits = typename Convex_hull_3::internal::Default_traits_for_Chull_3<Point>::type>
 Convex_hull_hierarchy (RangeIterator begin, RangeIterator end, const Traits &traits=Traits())
 constructor taking the points in the range [first, last).
 
template<class Direction_3 , typename NamedParameters = parameters::Default_named_parameters>
const Point extreme_point (const Direction_3 &dir, const NamedParameters &np=parameters::default_values) const
 computes the furthest point of the convex hull along the direction.
 

Constructor & Destructor Documentation

◆ Convex_hull_hierarchy() [1/2]

template<class PolygonMesh >
template<typename VertexListGraph , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Convex_hull_hierarchy< PolygonMesh >::Convex_hull_hierarchy ( const VertexListGraph g,
const NamedParameters &  np = parameters::default_values 
)

constructor taking the points associated to the vertices of g.

Template Parameters
VertexListGrapha model of VertexListGraph
NamedParametersa sequence of named parameters
Parameters
gthe graph
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters

◆ Convex_hull_hierarchy() [2/2]

template<class PolygonMesh >
template<typename RangeIterator , typename Traits = typename Convex_hull_3::internal::Default_traits_for_Chull_3<Point>::type>
CGAL::Convex_hull_hierarchy< PolygonMesh >::Convex_hull_hierarchy ( RangeIterator  begin,
RangeIterator  end,
const Traits &  traits = Traits() 
)

constructor taking the points in the range [first, last).

Template Parameters
RangeIteratormust be an input iterator with a value type equivalent to Traits::Point_3
Traitsmust be a model of the concept ConvexHullTraits_3. For the purposes of checking the postcondition that the convex hull is valid, Traits must also be a model of the concept IsStronglyConvexTraits_3. Furthermore, Traits must define a type PolygonMesh that is a model of MutableFaceGraph.

Member Function Documentation

◆ extreme_point()

template<class PolygonMesh >
template<class Direction_3 , typename NamedParameters = parameters::Default_named_parameters>
const Point CGAL::Convex_hull_hierarchy< PolygonMesh >::extreme_point ( const Direction_3 dir,
const NamedParameters &  np = parameters::default_values 
) const

computes the furthest point of the convex hull along the direction.

Template Parameters
NamedParametersa sequence of named parameters
Parameters
dirthe direction
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • a property map associating points to the vertices of the convex hull
  • Type: a model of ReadWritePropertyMap whose value type is a point type
  • Default: If this parameter is omitted, Point have to be a 3D point type of the same kernel that dir