CGAL 6.2 - Polygon Mesh Processing
Loading...
Searching...
No Matches
Miscellaneous Functions

Functions

template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Bbox_3 CGAL::Polygon_mesh_processing::bbox (const PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values())
 computes a bounding box of a polygon mesh.
 
template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Bbox_3 CGAL::Polygon_mesh_processing::vertex_bbox (typename boost::graph_traits< PolygonMesh >::vertex_descriptor vd, const PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values())
 computes a bounding box of the vertex of a polygon mesh.
 
template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Bbox_3 CGAL::Polygon_mesh_processing::edge_bbox (typename boost::graph_traits< PolygonMesh >::edge_descriptor ed, const PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values())
 computes a bounding box of an edge of a polygon mesh.
 
template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Bbox_3 CGAL::Polygon_mesh_processing::face_bbox (typename boost::graph_traits< PolygonMesh >::face_descriptor fd, const PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values())
 computes a bounding box of a face of a polygon mesh.
 
template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
void CGAL::Polygon_mesh_processing::add_bbox (PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values())
 adds an axis-aligned bounding box to a polygon mesh.
 
template<class Transformation , class PolygonMesh , class NamedParameters = parameters::Default_named_parameters>
void CGAL::Polygon_mesh_processing::transform (const Transformation &transformation, PolygonMesh &mesh, const NamedParameters &np=parameters::default_values())
 applies a transformation to every vertex of a PolygonMesh.
 
template<typename TriangleMesh , typename NamedParameters = CGAL::parameters::Default_named_parameters>
Triangle_3 CGAL::Polygon_mesh_processing::triangle (typename boost::graph_traits< TriangleMesh >::face_descriptor fd, const TriangleMesh &tmesh, const NamedParameters &np=parameters::default_values())
 computes a triangle for a face descriptor of a triangle mesh.
 

Function Documentation

◆ add_bbox()

template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
void CGAL::Polygon_mesh_processing::add_bbox ( PolygonMesh &  pmesh,
const NamedParameters &  np = parameters::default_values() 
)

#include <CGAL/Polygon_mesh_processing/bbox.h>

adds an axis-aligned bounding box to a polygon mesh.

Template Parameters
PolygonMesha model of MutableFaceGraph
NamedParametersa sequence of Named Parameters
Parameters
pmesha polygon mesh
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • a double used to scale the bounding box. The default value is 1 and the bounding box is the smallest possible axis-aligned bounding box.
  • Default: 1.
  • Precondition: bbox_scaling > 0
  • a Boolean used to specify whether the bounding box's faces should be triangulated or not. The default value is true, and faces are not triangulated.
  • Default: true
  • a property map associating points to the vertices of pmesh
  • Type: a class model of ReadWritePropertyMap with boost::graph_traits<PolygonMesh>::vertex_descriptor as key type and Point_3 as value type
  • Default: boost::get(CGAL::vertex_point, pmesh)
  • Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t must be available in PolygonMesh.
  • an instance of a geometric traits class model of Kernel.
See also
bbox()

◆ bbox()

template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Bbox_3 CGAL::Polygon_mesh_processing::bbox ( const PolygonMesh &  pmesh,
const NamedParameters &  np = parameters::default_values() 
)

#include <CGAL/Polygon_mesh_processing/bbox.h>

computes a bounding box of a polygon mesh.

Template Parameters
PolygonMesha model of VertexListGraph
NamedParametersa sequence of Named Parameters
Parameters
pmesha polygon mesh
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • a property map associating points to the vertices of pmesh
  • Type: a class model of ReadablePropertyMap with boost::graph_traits<PolygonMesh>::vertex_descriptor as key type and Point_3 as value type
  • Default: boost::get(CGAL::vertex_point, pmesh)
  • Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t must be available in PolygonMesh.

  • an instance of a geometric traits class providing the functor Construct_bbox_3 and the function Construct_bbox_3 construct_bbox_3_object(). Construct_bbox_3 must provide the functor Bbox_3 operator()(Point_3) where Point_3 is the value type of the vertex point map.

  • a double used to scale the bounding box. The default value is 1 and the bounding box is the smallest possible axis-aligned bounding box.
  • Default: 1.
  • Precondition: bbox_scaling > 0
See also
vertex_bbox()
edge_bbox()
face_bbox()

◆ edge_bbox()

template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Bbox_3 CGAL::Polygon_mesh_processing::edge_bbox ( typename boost::graph_traits< PolygonMesh >::edge_descriptor  ed,
const PolygonMesh &  pmesh,
const NamedParameters &  np = parameters::default_values() 
)

#include <CGAL/Polygon_mesh_processing/bbox.h>

computes a bounding box of an edge of a polygon mesh.

Template Parameters
PolygonMesha model of Graph
NamedParametersa sequence of Named Parameters
Parameters
eda descriptor of an edge in pmesh
pmesha polygon mesh
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • a property map associating points to the vertices of pmesh
  • Type: a class model of ReadablePropertyMap with boost::graph_traits<PolygonMesh>::vertex_descriptor as key type and Point_3 as value type
  • Default: boost::get(CGAL::vertex_point, pmesh)
  • Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t must be available in PolygonMesh.

  • an instance of a geometric traits class providing the functor Construct_bbox_3 and the function Construct_bbox_3 construct_bbox_3_object(). Construct_bbox_3 must provide Bbox_3 operator()(Point_3) where Point_3 is the value type of the vertex point map.
See also
vertex_bbox()
face_bbox()
bbox()

◆ face_bbox()

template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Bbox_3 CGAL::Polygon_mesh_processing::face_bbox ( typename boost::graph_traits< PolygonMesh >::face_descriptor  fd,
const PolygonMesh &  pmesh,
const NamedParameters &  np = parameters::default_values() 
)

#include <CGAL/Polygon_mesh_processing/bbox.h>

computes a bounding box of a face of a polygon mesh.

Template Parameters
PolygonMesha model of Graph
NamedParametersa sequence of Named Parameters
Parameters
fda descriptor of a face in pmesh
pmesha polygon mesh
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • a property map associating points to the vertices of pmesh
  • Type: a class model of ReadablePropertyMap with boost::graph_traits<PolygonMesh>::vertex_descriptor as key type and Point_3 as value type
  • Default: boost::get(CGAL::vertex_point, pmesh)
  • Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t must be available in PolygonMesh.

  • an instance of a geometric traits class providing the functor Construct_bbox_3 and the function Construct_bbox_3 construct_bbox_3_object(). Construct_bbox_3 must provide Bbox_3 operator()(Point_3) where Point_3 is the value type of the vertex point map.
  • Default: a CGAL Kernel deduced from the point type, using CGAL::Kernel_traits
See also
vertex_bbox()
edge_bbox()
bbox()

◆ transform()

template<class Transformation , class PolygonMesh , class NamedParameters = parameters::Default_named_parameters>
void CGAL::Polygon_mesh_processing::transform ( const Transformation &  transformation,
PolygonMesh &  mesh,
const NamedParameters &  np = parameters::default_values() 
)

#include <CGAL/Polygon_mesh_processing/transform.h>

applies a transformation to every vertex of a PolygonMesh.

Template Parameters
Transformationa functor that has an operator()(Point_3), with Point_3 the value_type of vertex_point_map (see below). Such a functor can be CGAL::Aff_transformation_3 for example.
PolygonMesha model of VertexListGraph
NamedParametersa sequence of Named Parameters
Parameters
transformationthe transformation functor to apply to the points of mesh.
meshthe PolygonMesh to transform.
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • a property map associating points to the vertices of mesh
  • Type: a class model of ReadWritePropertyMap with boost::graph_traits<PolygonMesh>::vertex_descriptor as key type and Point_3 as value type
  • Default: boost::get(CGAL::vertex_point, mesh)
  • Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t must be available in PolygonMesh.
Examples
Polygon_mesh_processing/hausdorff_bounded_error_distance_example.cpp.

◆ triangle()

template<typename TriangleMesh , typename NamedParameters = CGAL::parameters::Default_named_parameters>
Triangle_3 CGAL::Polygon_mesh_processing::triangle ( typename boost::graph_traits< TriangleMesh >::face_descriptor  fd,
const TriangleMesh &  tmesh,
const NamedParameters &  np = parameters::default_values() 
)

#include <CGAL/Polygon_mesh_processing/triangle.h>

computes a triangle for a face descriptor of a triangle mesh.

Template Parameters
TriangleMesha model of FaceGraph
NamedParametersa sequence of Named Parameters
Parameters
tmeshthe triangulated surface mesh
fdthe descriptor of the face to construct the triangle from
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • a property map associating points to the vertices of tmesh
  • Type: a class model of ReadablePropertyMap with boost::graph_traits<TriangleMesh>::vertex_descriptor as key type and Point_3 as value type
  • Default: boost::get(CGAL::vertex_point, tmesh)

  • an instance of a geometric traits class
  • Type: a class model of Kernel
  • Default: a CGAL Kernel deduced from the point type, using CGAL::Kernel_traits
  • Extra: The geometric traits class must be compatible with the vertex point type.

◆ vertex_bbox()

template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters>
CGAL::Bbox_3 CGAL::Polygon_mesh_processing::vertex_bbox ( typename boost::graph_traits< PolygonMesh >::vertex_descriptor  vd,
const PolygonMesh &  pmesh,
const NamedParameters &  np = parameters::default_values() 
)

#include <CGAL/Polygon_mesh_processing/bbox.h>

computes a bounding box of the vertex of a polygon mesh.

Template Parameters
PolygonMesha model of Graph
NamedParametersa sequence of Named Parameters
Parameters
vda descriptor of a vertex in pmesh
pmesha polygon mesh
npan optional sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • a property map associating points to the vertices of pmesh
  • Type: a class model of ReadablePropertyMap with boost::graph_traits<PolygonMesh>::vertex_descriptor as key type and Point_3 as value type
  • Default: boost::get(CGAL::vertex_point, pmesh)
  • Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t must be available in PolygonMesh.

  • an instance of a geometric traits class providing the functor Construct_bbox_3 and the function Construct_bbox_3 construct_bbox_3_object(). Construct_bbox_3 must provide Bbox_3 operator()(Point_3) where Point_3 is the value type of the vertex point map.
See also
edge_bbox()
face_bbox()
bbox()