CGAL 5.1 - Polygon Mesh Processing
Intersection Functions

Functions to test if there are self intersections, and to report faces that do intersect.

## Functions

template<class ConcurrencyTag = Sequential_tag, class TriangleMesh , class FaceRange , class FacePairOutputIterator , class NamedParameters >
FacePairOutputIterator CGAL::Polygon_mesh_processing::self_intersections (const FaceRange &face_range, const TriangleMesh &tmesh, FacePairOutputIterator out, const NamedParameters &np)
collects intersections between a subset of faces of a triangulated surface mesh. More...

template<class ConcurrencyTag = Sequential_tag, class TriangleMesh , class FacePairOutputIterator , class NamedParameters >
FacePairOutputIterator CGAL::Polygon_mesh_processing::self_intersections (const TriangleMesh &tmesh, FacePairOutputIterator out, const NamedParameters &np)
collects intersections between all the faces of a triangulated surface mesh. More...

template<class ConcurrencyTag = Sequential_tag, class FaceRange , class TriangleMesh , class NamedParameters >
bool CGAL::Polygon_mesh_processing::does_self_intersect (const FaceRange &face_range, const TriangleMesh &tmesh, const NamedParameters &np)
tests if a set of faces of a triangulated surface mesh self-intersects. More...

template<class ConcurrencyTag = Sequential_tag, class TriangleMesh , class NamedParameters >
bool CGAL::Polygon_mesh_processing::does_self_intersect (const TriangleMesh &tmesh, const NamedParameters &np)
tests if a triangulated surface mesh self-intersects. More...

## ◆ does_self_intersect() [1/2]

template<class ConcurrencyTag = Sequential_tag, class FaceRange , class TriangleMesh , class NamedParameters >
 bool CGAL::Polygon_mesh_processing::does_self_intersect ( const FaceRange & face_range, const TriangleMesh & tmesh, const NamedParameters & np )

#include <CGAL/Polygon_mesh_processing/self_intersections.h>

tests if a set of faces of a triangulated surface mesh self-intersects.

This function depends on the package Intersecting Sequences of dD Iso-oriented Boxes

Precondition
CGAL::is_triangle_mesh(tmesh)
Template Parameters
 ConcurrencyTag enables sequential versus parallel algorithm. Possible values are Sequential_tag, Parallel_tag, and Parallel_if_available_tag. FaceRange a range of face_descriptor TriangleMesh a model of FaceListGraph NamedParameters a sequence of Named Parameters
Parameters
 face_range the set of faces to test for self-intersection tmesh the triangulated surface mesh to be tested np an 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 ReadWritePropertyMap with boost::graph_traits::vertex_descriptor as key type and Point_3 as value type Default: boost::get(CGAL::vertex_point, tmesh) Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t should be available for the vertices of tmesh. an instance of a geometric traits class Type: a class model of PMPSelfIntersectionTraits 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.
Returns
true if the faces in face_range self-intersect

## ◆ does_self_intersect() [2/2]

template<class ConcurrencyTag = Sequential_tag, class TriangleMesh , class NamedParameters >
 bool CGAL::Polygon_mesh_processing::does_self_intersect ( const TriangleMesh & tmesh, const NamedParameters & np )

#include <CGAL/Polygon_mesh_processing/self_intersections.h>

tests if a triangulated surface mesh self-intersects.

This function depends on the package Intersecting Sequences of dD Iso-oriented Boxes

Precondition
CGAL::is_triangle_mesh(tmesh)
Template Parameters
 ConcurrencyTag enables sequential versus parallel algorithm. Possible values are Sequential_tag, Parallel_tag, and Parallel_if_available_tag. TriangleMesh a model of FaceListGraph NamedParameters a sequence of Named Parameters
Parameters
 tmesh the triangulated surface mesh to be tested np an 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 ReadWritePropertyMap with boost::graph_traits::vertex_descriptor as key type and Point_3 as value type Default: boost::get(CGAL::vertex_point, tmesh) Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t should be available for the vertices of tmesh. an instance of a geometric traits class Type: a class model of PMPSelfIntersectionTraits 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.
Returns
true if tmesh self-intersects

## ◆ self_intersections() [1/2]

template<class ConcurrencyTag = Sequential_tag, class TriangleMesh , class FaceRange , class FacePairOutputIterator , class NamedParameters >
 FacePairOutputIterator CGAL::Polygon_mesh_processing::self_intersections ( const FaceRange & face_range, const TriangleMesh & tmesh, FacePairOutputIterator out, const NamedParameters & np )

#include <CGAL/Polygon_mesh_processing/self_intersections.h>

collects intersections between a subset of faces of a triangulated surface mesh.

Two faces are said to intersect if the corresponding triangles intersect and the intersection is not an edge nor a vertex incident to both faces.

This function depends on the package Intersecting Sequences of dD Iso-oriented Boxes

Precondition
CGAL::is_triangle_mesh(tmesh)
Template Parameters
 ConcurrencyTag enables sequential versus parallel algorithm. Possible values are Sequential_tag, Parallel_tag, and Parallel_if_available_tag. FaceRange a model of ConstRange with value type boost::graph_traits::face_descriptor. TriangleMesh a model of FaceListGraph FacePairOutputIterator a model of OutputIterator holding objects of type std::pair::face_descriptor, boost::graph_traits::face_descriptor> NamedParameters a sequence of Named Parameters
Parameters
 face_range the range of faces to check for self-intersection. tmesh the triangulated surface mesh to be checked out output iterator to be filled with all pairs of non-adjacent faces that intersect np an 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 ReadWritePropertyMap with boost::graph_traits::vertex_descriptor as key type and Point_3 as value type Default: boost::get(CGAL::vertex_point, tmesh) Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t should be available for the vertices of tmesh. an instance of a geometric traits class Type: a class model of PMPSelfIntersectionTraits 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.

## ◆ self_intersections() [2/2]

template<class ConcurrencyTag = Sequential_tag, class TriangleMesh , class FacePairOutputIterator , class NamedParameters >
 FacePairOutputIterator CGAL::Polygon_mesh_processing::self_intersections ( const TriangleMesh & tmesh, FacePairOutputIterator out, const NamedParameters & np )

#include <CGAL/Polygon_mesh_processing/self_intersections.h>

collects intersections between all the faces of a triangulated surface mesh.

Two faces are said to intersect if the corresponding triangles intersect and the intersection is not an edge nor a vertex incident to both faces.

This function depends on the package Intersecting Sequences of dD Iso-oriented Boxes

Precondition
CGAL::is_triangle_mesh(tmesh)
Template Parameters
 ConcurrencyTag enables sequential versus parallel algorithm. Possible values are Sequential_tag, Parallel_tag, and Parallel_if_available_tag. TriangleMesh a model of FaceListGraph FacePairOutputIterator a model of OutputIterator holding objects of type std::pair::face_descriptor, boost::graph_traits::face_descriptor> NamedParameters a sequence of Named Parameters
Parameters
 tmesh the triangulated surface mesh to be checked out output iterator to be filled with all pairs of non-adjacent faces that intersect. In case tmesh contains some degenerate faces, for each degenerate face f a pair (f,f) will be put in out before any other self intersection between non-degenerate faces. These are the only pairs where degenerate faces will be reported. np an 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 ReadWritePropertyMap with boost::graph_traits::vertex_descriptor as key type and Point_3 as value type Default: boost::get(CGAL::vertex_point, tmesh) Extra: If this parameter is omitted, an internal property map for CGAL::vertex_point_t should be available for the vertices of tmesh. an instance of a geometric traits class Type: a class model of PMPSelfIntersectionTraits 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.
Returns
out