CGAL 5.6.1 - Shape Detection
CGAL::Shape_detection::Polygon_mesh::Least_squares_plane_fit_sorting< GeomTraits, PolygonMesh, NeighborQuery, VertexToPointMap > Class Template Reference

#include <CGAL/Shape_detection/Region_growing/Polygon_mesh/Least_squares_plane_fit_sorting.h>

Definition

template<typename GeomTraits, typename PolygonMesh, typename NeighborQuery, typename VertexToPointMap = typename boost::property_map<PolygonMesh, CGAL::vertex_point_t>::const_type>
class CGAL::Shape_detection::Polygon_mesh::Least_squares_plane_fit_sorting< GeomTraits, PolygonMesh, NeighborQuery, VertexToPointMap >

Sorting of polygon mesh faces with respect to the local plane fit quality.

Items of faces in a polygon mesh are sorted with respect to the quality of the least squares plane fit applied to the vertices of incident faces of each face.

Template Parameters
GeomTraitsa model of Kernel
PolygonMesha model of FaceListGraph
NeighborQuerya model of NeighborQuery
VertexToPointMapa model of ReadablePropertyMap whose key type is the vertex type of a polygon mesh and value type is Kernel::Point_3
Examples:
Shape_detection/region_growing_planes_on_polygon_mesh.cpp.

Types

using Item = typename boost::graph_traits< PolygonMesh >::face_descriptor
 Item type.
 
using Seed_range = std::vector< Item >
 Seed range.
 

Initialization

template<typename NamedParameters = CGAL::parameters::Default_named_parameters>
 Least_squares_plane_fit_sorting (const PolygonMesh &pmesh, NeighborQuery &neighbor_query, const NamedParameters &np=parameters::default_values())
 initializes all internal data structures. More...
 

Sorting

void sort ()
 sorts Items of input faces.
 

Access

const Seed_rangeordered ()
 returns an instance of Seed_range to access the ordered Items of input faces.
 

Constructor & Destructor Documentation

◆ Least_squares_plane_fit_sorting()

template<typename GeomTraits , typename PolygonMesh , typename NeighborQuery , typename VertexToPointMap = typename boost::property_map<PolygonMesh, CGAL::vertex_point_t>::const_type>
template<typename NamedParameters = CGAL::parameters::Default_named_parameters>
CGAL::Shape_detection::Polygon_mesh::Least_squares_plane_fit_sorting< GeomTraits, PolygonMesh, NeighborQuery, VertexToPointMap >::Least_squares_plane_fit_sorting ( const PolygonMesh &  pmesh,
NeighborQuery neighbor_query,
const NamedParameters &  np = parameters::default_values() 
)

initializes all internal data structures.

Template Parameters
NamedParametersa sequence of Named Parameters
Parameters
pmeshan instance of PolygonMesh that represents a polygon mesh
neighbor_queryan instance of NeighborQuery that is used internally to access face's neighbors
npa sequence of Named Parameters among the ones listed below
Optional Named Parameters
  • an instance of VertexToPointMap that maps a polygon mesh vertex to Kernel::Point_3
  • Default: boost::get(CGAL::vertex_point, pmesh)
  • an instance of GeomTraits
  • Default: GeomTraits()
Precondition
faces(pmesh).size() > 0