#include <CGAL/Shape_detection/Region_growing/Region_growing_on_polygon_mesh/One_ring_neighbor_query.h>
template<typename PolygonMesh, typename FaceRange = typename PolygonMesh::Face_range>
class CGAL::Shape_detection::Polygon_mesh::One_ring_neighbor_query< PolygonMesh, FaceRange >
Edge-adjacent faces connectivity in a polygon mesh.
This class returns all faces, which are edge-adjacent to a query face in a polygon mesh being a PolygonMesh
.
- Template Parameters
-
- Is Model Of:
NeighborQuery
- Examples:
- Shape_detection/region_growing_planes_on_polygon_mesh.cpp.
◆ One_ring_neighbor_query()
template<typename PolygonMesh , typename FaceRange = typename PolygonMesh::Face_range>
initializes all internal data structures.
- Parameters
-
pmesh | an instance of a PolygonMesh that represents a polygon mesh |
- Precondition
faces(pmesh).size() > 0
◆ operator()()
template<typename PolygonMesh , typename FaceRange = typename PolygonMesh::Face_range>
implements NeighborQuery::operator()()
.
This operator retrieves indices of all faces, which are edge-adjacent to the face with the index query_index
. These indices are returned in neighbors
.
- Parameters
-
query_index | index of the query face |
neighbors | indices of faces, which are neighbors of the query face |
- Precondition
query_index >= 0 && query_index < faces(pmesh).size()