CGAL 6.2 - Boolean Operations on Meshes

Loading...
Searching...
No Matches
List of all members | Public Types | Public Member Functions | Public Attributes
CGAL::Polygon_mesh_processing::Corefinement::Non_manifold_output_visitor< TriangleMesh, VPM1, VPM2 > Struct Template Reference
Reference Manual » Corefinement and Autorefinement

`#include <CGAL/Polygon_mesh_processing/corefinement.h>`

## Inherits from

CGAL::Polygon_mesh_processing::Corefinement::Default_visitor< TriangleMesh >.

## Definition

template<class TriangleMesh, class VPM1 = typename boost::property_map<TriangleMesh, vertex_point_t>::type, class VPM2 = typename boost::property_map<TriangleMesh, vertex_point_t>::type>
struct CGAL::Polygon_mesh_processing::Corefinement::Non_manifold_output_visitor< TriangleMesh, VPM1, VPM2 >

Is model of
  `PMPCorefinementVisitor`

A model of `PMPCorefinementVisitor` that enables extracting non-manifold outputs from a corefinement-based Boolean Operations (Boolean Operations).

Template Parameters

  TriangleMesh | a model of `HalfedgeListGraph`, `FaceListGraph`, and `MutableFaceGraph`
  VPM1 | a class model of `ReadablePropertyMap` with `boost::graph_traits<TriangleMesh>::vertex_descriptor` as key type and an unspecified type `Point_3` as value type
  VPM2 | a class model of `ReadablePropertyMap` with `boost::graph_traits<TriangleMesh>::vertex_descriptor` as key type and the same value type as `VPM1`

## Public Types
typedef boost::graph_traits< TriangleMesh > | GT
typedef GT::face_descriptor | face_descriptor
typedef GT::vertex_descriptor | vertex_descriptor
typedef GT::halfedge_descriptor | halfedge_descriptor
typedef boost::property_map< TriangleMesh, CGAL::dynamic_face_property_t< bool > >::type | Classification_map
typedef std::unordered_map< vertex_descriptor, std::size_t > | Vertex_id_map
typedef boost::container::flat_map< const TriangleMesh *, Vertex_id_map > | Vertex_id_maps
Public Types inherited from CGAL::Polygon_mesh_processing::Corefinement::Default_visitor< TriangleMesh >
typedef boost::graph_traits< TriangleMesh > | GT
typedef GT::face_descriptor | face_descriptor
typedef GT::halfedge_descriptor | halfedge_descriptor
typedef GT::vertex_descriptor | vertex_descriptor

## Public Member Functions
| Non_manifold_output_visitor (TriangleMesh &tm1, TriangleMesh &tm2, VPM1 vpm1=get(CGAL::vertex_point, tm1), VPM1 vpm2=get(CGAL::vertex_point, tm2))
| constructor where meshes are exactly the same as the one passed a function in Corefinement and Autorefinement.
template<typename PointRange , typename PolygonRange >
void | extract_intersection (PointRange &points, PolygonRange &triangles)
| fills a polygon soup with the intersection between input meshes provided in the constructor, after a call to either `corefine_and_compute_boolean_operations()` or `corefine_and_compute_intersection()`.
template<typename PointRange , typename PolygonRange >
void | extract_union (PointRange &points, PolygonRange &triangles)
| fills a polygon soup with the union between input meshes provided in the constructor, after a call to either `corefine_and_compute_boolean_operations()` or `corefine_and_compute_union()`.
template<typename PointRange , typename PolygonRange >
void | extract_tm1_minus_tm2 (PointRange &points, PolygonRange &triangles)
| fills a polygon soup with the difference between input meshes provided in the constructor, after a call to either `corefine_and_compute_boolean_operations()` or `corefine_and_compute_difference()`.
template<typename PointRange , typename PolygonRange >
void | extract_tm2_minus_tm1 (PointRange &points, PolygonRange &triangles)
| fills a polygon soup with the opposite difference between input meshes provided in the constructor, after a call to `corefine_and_compute_boolean_operations()`.
| Non_manifold_output_visitor (TriangleMesh &tm1, TriangleMesh &tm2, VPM1 vpm1, VPM2 vpm2)
| Non_manifold_output_visitor (TriangleMesh &tm1, TriangleMesh &tm2, VPM1 vpm1)
| Non_manifold_output_visitor (TriangleMesh &tm1, TriangleMesh &tm2)
void | intersection_point_detected (std::size_t node_id, int sdim, halfedge_descriptor h_e, halfedge_descriptor h_f, const TriangleMesh &tm_e, const TriangleMesh &tm_f, bool is_target_coplanar, bool is_source_coplanar)
void | new_vertex_added (std::size_t node_id, vertex_descriptor vh, TriangleMesh &tm)
template<class FaceIndexMap >
void | export_flags (FaceIndexMap fim, const std::vector< std::size_t > &tm_patch_ids, const boost::dynamic_bitset<> &is_patch_inside_other_tm, const boost::dynamic_bitset<> &coplanar_patches, const boost::dynamic_bitset<> &coplanar_patches_of_tm_for_union_and_intersection, const boost::dynamic_bitset<> &, TriangleMesh &tm)
template<bool inverse_tm1_faces, bool inverse_tm2_faces, class PointRange , class PolygonRange , class FCM >
void | extract_soup (PointRange &points, PolygonRange &triangles, FCM tm1_face_classification, FCM tm2_face_classification)
template<typename PointRange , typename PolygonRange >
void | extract_intersection (PointRange &points, PolygonRange &triangles)
template<typename PointRange , typename PolygonRange >
void | extract_union (PointRange &points, PolygonRange &triangles)
template<typename PointRange , typename PolygonRange >
void | extract_tm1_minus_tm2 (PointRange &points, PolygonRange &triangles)
template<typename PointRange , typename PolygonRange >
void | extract_tm2_minus_tm1 (PointRange &points, PolygonRange &triangles)
Public Member Functions inherited from CGAL::Polygon_mesh_processing::Corefinement::Default_visitor< TriangleMesh >
void | before_subface_creations (face_descriptor, const TriangleMesh &)
void | after_subface_creations (const TriangleMesh &)
void | before_subface_created (const TriangleMesh &)
void | after_subface_created (face_descriptor, const TriangleMesh &)
void | before_face_copy (face_descriptor, const TriangleMesh &, const TriangleMesh &)
void | after_face_copy (face_descriptor, const TriangleMesh &, face_descriptor, const TriangleMesh &)
void | subface_of_coplanar_faces_intersection (face_descriptor, const TriangleMesh &)
void | before_edge_split (halfedge_descriptor, const TriangleMesh &)
void | edge_split (halfedge_descriptor, const TriangleMesh &)
void | after_edge_split ()
void | add_retriangulation_edge (halfedge_descriptor, const TriangleMesh &)
void | before_edge_copy (halfedge_descriptor, const TriangleMesh &, const TriangleMesh &)
void | after_edge_copy (halfedge_descriptor, const TriangleMesh &, halfedge_descriptor, const TriangleMesh &)
void | before_edge_duplicated (halfedge_descriptor, const TriangleMesh &)
void | after_edge_duplicated (halfedge_descriptor, halfedge_descriptor, const TriangleMesh &)
void | intersection_edge_copy (halfedge_descriptor, const TriangleMesh &, halfedge_descriptor, const TriangleMesh &, halfedge_descriptor, const TriangleMesh &)
void | new_vertex_added (std::size_t, vertex_descriptor, const TriangleMesh &)
void | intersection_point_detected (std::size_t, int, halfedge_descriptor, halfedge_descriptor, const TriangleMesh &, const TriangleMesh &, bool, bool)
void | before_vertex_copy (vertex_descriptor, const TriangleMesh &, const TriangleMesh &)
void | after_vertex_copy (vertex_descriptor, const TriangleMesh &, vertex_descriptor, const TriangleMesh &)
void | start_filtering_intersections () const
void | progress_filtering_intersections (double) const
void | end_filtering_intersections () const
void | start_triangulating_faces (std::size_t) const
void | triangulating_faces_step () const
void | end_triangulating_faces () const
void | start_handling_intersection_of_coplanar_faces (std::size_t) const
void | intersection_of_coplanar_faces_step () const
void | end_handling_intersection_of_coplanar_faces () const
void | start_handling_edge_face_intersections (std::size_t) const
void | edge_face_intersections_step () const
void | end_handling_edge_face_intersections () const
void | start_building_output () const
void | end_building_output () const
void | filter_coplanar_edges () const
void | detect_patches () const
void | classify_patches () const
void | classify_intersection_free_patches (const TriangleMesh &) const
void | out_of_place_operation (Boolean_operation_type) const
void | in_place_operation (Boolean_operation_type) const
void | in_place_operations (Boolean_operation_type, Boolean_operation_type) const

## Public Attributes
std::shared_ptr< Vertex_id_maps > | vertex_id_maps
TriangleMesh & | m_tm1
TriangleMesh & | m_tm2
VPM1 | m_vpm1
VPM1 | m_vpm2
std::shared_ptr< std::array< Classification_map, 4 > > | m_face_classifications_tm1_ptr
std::shared_ptr< std::array< Classification_map, 4 > > | m_face_classifications_tm2_ptr

## Constructor & Destructor Documentation

## ◆ Non_manifold_output_visitor()

template<class TriangleMesh , class VPM1 = typename boost::property_map<TriangleMesh, vertex_point_t>::type, class VPM2 = typename boost::property_map<TriangleMesh, vertex_point_t>::type>

CGAL::Polygon_mesh_processing::Corefinement::Non_manifold_output_visitor< TriangleMesh, VPM1, VPM2 >::Non_manifold_output_visitor | ( | TriangleMesh & | tm1,
|  | TriangleMesh & | tm2,
|  | VPM1 | vpm1 = `get(CGAL::vertex_point, tm1)`,
|  | VPM1 | vpm2 = `get(CGAL::vertex_point, tm2)`
| ) |  |

constructor where meshes are exactly the same as the one passed a function in Corefinement and Autorefinement.

The visitor cannot be reused for several calls to the aforementioned function.

Parameters

  tm1 | first triangle mesh in the same order as in the function in Corefinement and Autorefinement
  tm2 | second triangle mesh in the same order as in the function in Corefinement and Autorefinement
  vpm1 | vertex point map for `tm1`
  vpm2 | vertex point map for `tm2`

## Member Function Documentation

## ◆ extract_intersection()

template<class TriangleMesh , class VPM1 = typename boost::property_map<TriangleMesh, vertex_point_t>::type, class VPM2 = typename boost::property_map<TriangleMesh, vertex_point_t>::type>
template<typename PointRange , typename PolygonRange >

void CGAL::Polygon_mesh_processing::Corefinement::Non_manifold_output_visitor< TriangleMesh, VPM1, VPM2 >::extract_intersection | ( | PointRange & | points,
|  | PolygonRange & | triangles
| ) |  |

fills a polygon soup with the intersection between input meshes provided in the constructor, after a call to either `corefine_and_compute_boolean_operations()` or `corefine_and_compute_intersection()`.

Template Parameters

  PointRange | a model of the concept `RandomAccessContainer` whose value type is the value type of `VPM1` and `VPM2`.
  PolygonRange | a model of the concepts `RandomAccessContainer` and `BackInsertionSequence` whose `value_type` is itself a model of the concepts `RandomAccessContainer` and `BackInsertionSequence` whose `value_type` is an unsigned integer type convertible to `std::size_t`

## ◆ extract_tm1_minus_tm2()

template<class TriangleMesh , class VPM1 = typename boost::property_map<TriangleMesh, vertex_point_t>::type, class VPM2 = typename boost::property_map<TriangleMesh, vertex_point_t>::type>
template<typename PointRange , typename PolygonRange >

void CGAL::Polygon_mesh_processing::Corefinement::Non_manifold_output_visitor< TriangleMesh, VPM1, VPM2 >::extract_tm1_minus_tm2 | ( | PointRange & | points,
|  | PolygonRange & | triangles
| ) |  |

fills a polygon soup with the difference between input meshes provided in the constructor, after a call to either `corefine_and_compute_boolean_operations()` or `corefine_and_compute_difference()`.

Template Parameters

  PointRange | a model of the concept `RandomAccessContainer` whose value type is the value type of `VPM1` and `VPM2`.
  PolygonRange | a model of the concepts `RandomAccessContainer` and `BackInsertionSequence` whose `value_type` is itself a model of the concepts `RandomAccessContainer` and `BackInsertionSequence` whose `value_type` is an unsigned integer type convertible to `std::size_t`

## ◆ extract_tm2_minus_tm1()

template<class TriangleMesh , class VPM1 = typename boost::property_map<TriangleMesh, vertex_point_t>::type, class VPM2 = typename boost::property_map<TriangleMesh, vertex_point_t>::type>
template<typename PointRange , typename PolygonRange >

void CGAL::Polygon_mesh_processing::Corefinement::Non_manifold_output_visitor< TriangleMesh, VPM1, VPM2 >::extract_tm2_minus_tm1 | ( | PointRange & | points,
|  | PolygonRange & | triangles
| ) |  |

fills a polygon soup with the opposite difference between input meshes provided in the constructor, after a call to `corefine_and_compute_boolean_operations()`.

Template Parameters

  PointRange | a model of the concept `RandomAccessContainer` whose value type is the value type of `VPM1` and `VPM2`.
  PolygonRange | a model of the concepts `RandomAccessContainer` and `BackInsertionSequence` whose `value_type` is itself a model of the concepts `RandomAccessContainer` and `BackInsertionSequence` whose `value_type` is an unsigned integer type convertible to `std::size_t`

## ◆ extract_union()

template<class TriangleMesh , class VPM1 = typename boost::property_map<TriangleMesh, vertex_point_t>::type, class VPM2 = typename boost::property_map<TriangleMesh, vertex_point_t>::type>
template<typename PointRange , typename PolygonRange >

void CGAL::Polygon_mesh_processing::Corefinement::Non_manifold_output_visitor< TriangleMesh, VPM1, VPM2 >::extract_union | ( | PointRange & | points,
|  | PolygonRange & | triangles
| ) |  |

fills a polygon soup with the union between input meshes provided in the constructor, after a call to either `corefine_and_compute_boolean_operations()` or `corefine_and_compute_union()`.

Template Parameters

  PointRange | a model of the concept `RandomAccessContainer` whose value type is the value type of `VPM1` and `VPM2`.
  PolygonRange | a model of the concepts `RandomAccessContainer` and `BackInsertionSequence` whose `value_type` is itself a model of the concepts `RandomAccessContainer` and `BackInsertionSequence` whose `value_type` is an unsigned integer type convertible to `std::size_t`