- the number of iterations for the sequence of the smoothing iterations performed
- Type: unsigned int
-
Default:
1
CGAL 5.6 - Polygon Mesh Processing
|
Functions to triangulate faces, and to refine and fair regions of a polygon mesh.
Classes | |
struct | CGAL::Polygon_mesh_processing::Triangulate_faces::Default_visitor< PolygonMesh > |
Default new face visitor model of PMPTriangulateFaceVisitor . More... | |
struct | CGAL::Polygon_mesh_processing::Triangulate_polygons::Default_visitor |
Default new polygon visitor model of PMPTriangulateFaceVisitor . More... | |
Functions | |
template<typename TriangleMesh , typename FaceRange , typename NamedParameters = parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::angle_and_area_smoothing (const FaceRange &faces, TriangleMesh &tmesh, const NamedParameters &np=parameters::default_values()) |
smooths a triangulated region of a polygon mesh. More... | |
template<typename TriangleMesh , typename NamedParameters = CGAL::parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::angle_and_area_smoothing (TriangleMesh &tmesh, const NamedParameters &np=parameters::default_values()) |
smooths a polygon mesh. More... | |
template<class InputMesh , class OutputMesh , class BottomFunctor , class TopFunctor , class NamedParameters1 = CGAL::parameters::Default_named_parameter, class NamedParameters2 = CGAL::parameters::Default_named_parameter> | |
void | CGAL::Polygon_mesh_processing::extrude_mesh (const InputMesh &input, OutputMesh &output, const BottomFunctor &bot, const TopFunctor &top, const NamedParameters1 &np_in=parameters::default_values(), const NamedParameters2 &np_out=parameters::default_values()) |
performs a generalized extrusion of input and puts it in output . More... | |
template<class InputMesh , class OutputMesh , class NamedParameters1 = CGAL::parameters::Default_named_parameter, class NamedParameters2 = CGAL::parameters::Default_named_parameter> | |
void | CGAL::Polygon_mesh_processing::extrude_mesh (const InputMesh &input, OutputMesh &output, Vector_3 v, const NamedParameters1 &np_in=parameters::default_values(), const NamedParameters2 &np_out=parameters::default_values()) |
fills output with a closed mesh bounding the volume swept by input when translating its vertices by v . More... | |
template<typename TriangleMesh , typename VertexRange , typename NamedParameters = parameters::Default_named_parameters> | |
bool | CGAL::Polygon_mesh_processing::fair (TriangleMesh &tmesh, const VertexRange &vertices, const NamedParameters &np=parameters::default_values()) |
fairs a region on a triangle mesh. More... | |
template<typename VertexRange , typename TriangleMesh , typename NamedParameters = parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::random_perturbation (VertexRange vertices, TriangleMesh &tmesh, const double &perturbation_max_size, const NamedParameters &np=parameters::default_values()) |
randomly perturbs the locations of non-border vertices of a triangulated surface mesh. More... | |
template<typename TriangleMesh , typename NamedParameters = parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::random_perturbation (TriangleMesh &tmesh, const double &perturbation_max_size, const NamedParameters &np=parameters::default_values()) |
randomly perturbs the locations of all non-border vertices of a triangulated surface mesh. More... | |
template<typename TriangleMesh , typename FaceRange , typename FaceOutputIterator , typename VertexOutputIterator , typename NamedParameters = parameters::Default_named_parameters> | |
std::pair< FaceOutputIterator, VertexOutputIterator > | CGAL::Polygon_mesh_processing::refine (TriangleMesh &tmesh, const FaceRange &faces, FaceOutputIterator faces_out, VertexOutputIterator vertices_out, const NamedParameters &np=parameters::default_values()) |
refines a region of a triangle mesh. More... | |
template<typename PolygonMesh , typename FaceRange , typename NamedParameters = parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::isotropic_remeshing (const FaceRange &faces, const double &target_edge_length, PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values()) |
remeshes a triangulated region of a polygon mesh. More... | |
template<typename PolygonMesh , typename EdgeRange , typename NamedParameters = parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::split_long_edges (const EdgeRange &edges, const double &max_length, PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values()) |
splits the edges listed in edges into sub-edges that are not longer than the given threshold max_length . More... | |
template<typename TriangleMeshIn , typename PolygonMeshOut , typename NamedParametersIn = parameters::Default_named_parameters, typename NamedParametersOut = parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::remesh_planar_patches (const TriangleMeshIn &tm_in, PolygonMeshOut &pm_out, const NamedParametersIn &np_in=parameters::default_values(), const NamedParametersOut &np_out=parameters::default_values()) |
generates a new triangle mesh pm_out with the minimal number of triangles while preserving the shape of tm_in . More... | |
template<typename TriangleMeshIn , typename PolygonMeshOut , typename FacePatchMap , typename EdgeIsConstrainedMap , typename VertexCornerMap , typename NamedParametersIn = parameters::Default_named_parameters, typename NamedParametersOut = parameters::Default_named_parameters> | |
bool | CGAL::Polygon_mesh_processing::remesh_almost_planar_patches (const TriangleMeshIn &tm_in, PolygonMeshOut &pm_out, std::size_t nb_patches, std::size_t nb_corners, FacePatchMap face_patch_map, VertexCornerMap vertex_corner_map, EdgeIsConstrainedMap ecm, const NamedParametersIn &np_in=parameters::default_values(), const NamedParametersOut &np_out=parameters::default_values()) |
generates a new triangle mesh pm_out with the minimal number of triangles from a partition of tm_in . More... | |
template<typename TriangleMesh , typename FaceRange , typename NamedParameters = parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::smooth_shape (const FaceRange &faces, TriangleMesh &tmesh, const double time, const NamedParameters &np=parameters::default_values()) |
smooths the overall shape of the mesh by using the mean curvature flow. More... | |
template<typename VertexRange , class TriangleMesh , class NamedParameters = parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::tangential_relaxation (const VertexRange &vertices, TriangleMesh &tm, const NamedParameters &np=parameters::default_values()) |
applies an iterative area-based tangential smoothing to the given range of vertices. More... | |
template<class TriangleMesh , typename NamedParameters = CGAL::parameters::Default_named_parameters> | |
void | CGAL::Polygon_mesh_processing::tangential_relaxation (TriangleMesh &tm, const NamedParameters &np=parameters::default_values()) |
applies tangential_relaxation() to all the vertices of tm . | |
template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters> | |
bool | CGAL::Polygon_mesh_processing::triangulate_face (typename boost::graph_traits< PolygonMesh >::face_descriptor f, PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values()) |
triangulates a single face of a polygon mesh. More... | |
template<typename FaceRange , typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters> | |
bool | CGAL::Polygon_mesh_processing::triangulate_faces (FaceRange face_range, PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values()) |
triangulates given faces of a polygon mesh. More... | |
template<typename PolygonMesh , typename NamedParameters = parameters::Default_named_parameters> | |
bool | CGAL::Polygon_mesh_processing::triangulate_faces (PolygonMesh &pmesh, const NamedParameters &np=parameters::default_values()) |
triangulates all faces of a polygon mesh. More... | |
template<typename PointRange , typename PolygonRange , typename NamedParameters = parameters::Default_named_parameters> | |
bool | CGAL::Polygon_mesh_processing::triangulate_polygons (const PointRange &points, PolygonRange &polygons, const NamedParameters &np=parameters::default_values()) |
triangulates all polygons of a polygon soup. More... | |
template<typename TriangleMesh , typename TriangleMeshOut = TriangleMesh, typename NamedParameters = parameters::Default_named_parameters> | |
TriangleMeshOut | CGAL::Polygon_mesh_processing::surface_Delaunay_remeshing (const TriangleMesh &tmesh, const NamedParameters &np=parameters::default_values()) |
remeshes a surface triangle mesh following the Delaunay refinement algorithm described in the 3D Mesh Generation package. More... | |
void CGAL::Polygon_mesh_processing::angle_and_area_smoothing | ( | const FaceRange & | faces, |
TriangleMesh & | tmesh, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/angle_and_area_smoothing.h>
smooths a triangulated region of a polygon mesh.
This function aims to make the triangle angle and area distributions as uniform as possible by moving (non-constrained) vertices.
Angle-based smoothing does not change the combinatorial information of the mesh. Area-based smoothing might change the combinatorial information, unless specified otherwise. It is also possible to make the smoothing algorithm "safer" by rejecting moves that, when applied, would worsen the quality of the mesh, e.g. that would decrease the value of the smallest angle around a vertex or create self-intersections.
Optionally, the points are reprojected after each iteration.
TriangleMesh | model of MutableFaceGraph . |
FaceRange | range of boost::graph_traits<TriangleMesh>::face_descriptor , model of Range . Its iterator type is ForwardIterator . |
NamedParameters | a sequence of Named Parameters |
tmesh | a polygon mesh with triangulated surface patches to be smoothed. |
faces | the range of triangular faces defining one or several surface patches to be smoothed. |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
| |
| |
| |
| |
| |
| |
| |
|
tmesh
does not contain any degenerate faces. void CGAL::Polygon_mesh_processing::angle_and_area_smoothing | ( | TriangleMesh & | tmesh, |
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/angle_and_area_smoothing.h>
smooths a polygon mesh.
This function aims to make the triangle angle and area distributions as uniform as possible by moving (non-constrained) vertices.
Angle-based smoothing does not change the combinatorial information of the mesh. Area-based smoothing might change the combinatorial information, unless specified otherwise. It is also possible to make the smoothing algorithm "safer" by rejecting moves that, when applied, would worsen the quality of the mesh, e.g. that would decrease the value of the smallest angle around a vertex or create self-intersections.
Optionally, the points are reprojected after each iteration.
See the overload which takes a face range as additonal parameter for a comprehensive description of the parameters.
void CGAL::Polygon_mesh_processing::extrude_mesh | ( | const InputMesh & | input, |
OutputMesh & | output, | ||
const BottomFunctor & | bot, | ||
const TopFunctor & | top, | ||
const NamedParameters1 & | np_in = parameters::default_values() , |
||
const NamedParameters2 & | np_out = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/extrude.h>
performs a generalized extrusion of input
and puts it in output
.
This function extrudes the open surface mesh input
and puts the result in output
. The mesh generated is a closed surface mesh with a bottom and top part, both having the same graph combinatorics as input
(except that the orientation of the faces of the bottom part is reversed). The bottom and the top parts are connected by a triangle strip between boundary cycles. The coordinates of the points associated to the vertices of the bottom and top part are first initialized to the same value as the corresponding vertices of input
. Then for each vertex, a call to bot
and top
is done for the vertices of the bottom part and the top part, respectively.
output
may be self intersecting.InputMesh | a model of FaceListGraph |
OutputMesh | a model of FaceListGraph and MutableFaceGraph |
NamedParameters1 | a sequence of Named Parameters for InputMesh |
NamedParameters2 | a sequence of Named Parameters for OutputMesh |
BottomFunctor | a functor providing void operator()(boost::graph_traits<InputMesh>::vertex_descriptor input_v,boost::graph_traits<OutputMesh>::vertex_descriptor output_v) output_v is the copy of input_v from input into the bottom part of output . |
TopFunctor | a functor providing a similar operator() as BottomFunctor . |
input | an open surface mesh to extrude. |
output | a surface mesh that will contain the result of the extrusion. |
bot | functor that will transform all points copied from input in order to shape the bottom part of the extrusion. |
top | functor that will transform all points copied from input in order to shape the top part of the extrusion. |
np_in | an optional sequence of Named Parameters among the ones listed below |
|
np_out | an optional sequence of Named Parameters among the ones listed below |
|
void CGAL::Polygon_mesh_processing::extrude_mesh | ( | const InputMesh & | input, |
OutputMesh & | output, | ||
Vector_3 | v, | ||
const NamedParameters1 & | np_in = parameters::default_values() , |
||
const NamedParameters2 & | np_out = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/extrude.h>
fills output
with a closed mesh bounding the volume swept by input
when translating its vertices by v
.
The mesh is oriented so that the faces corresponding to input
in output
have the same orientation.
output
may be self intersecting.InputMesh | a model of the concept FaceListGraph |
OutputMesh | a model of the concept FaceListGraph and MutableFaceGraph |
Vector_3 | vector type from the same CGAL kernel as the point of the vertex point map used for OutputMesh . |
NamedParameters1 | a sequence of Named Parameters for InputMesh |
NamedParameters2 | a sequence of Named Parameters for OutputMesh |
input | an open surface mesh to extrude |
output | a surface mesh that will contain the result of the extrusion |
v | the vector defining the direction of the extrusion |
np_in | an optional sequence of Named Parameters among the ones listed below |
|
np_out | an optional sequence of Named Parameters among the ones listed below |
|
bool CGAL::Polygon_mesh_processing::fair | ( | TriangleMesh & | tmesh, |
const VertexRange & | vertices, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/fair.h>
fairs a region on a triangle mesh.
The points of the selected vertices are relocated to yield an as-smooth-as-possible surface patch, based on solving a linear bi-Laplacian system with boundary constraints, described in [4]. The optional parameter fairing_continuity
gives the ability to control the tangential continuity C n of the output mesh.
The region described by vertices
might contain multiple disconnected components. Note that the mesh connectivity is not altered in any way, only vertex locations get updated.
Fairing might fail if fixed vertices, which are used as boundary conditions, do not suffice to solve constructed linear system.
Note that if the vertex range to which fairing is applied contains all the vertices of the triangle mesh, fairing does not fail, but the mesh gets shrunk to CGAL::ORIGIN
.
TriangleMesh | a model of FaceGraph and MutableFaceGraph |
VertexRange | a range of vertex descriptors of TriangleMesh , model of Range . Its iterator type is InputIterator . |
NamedParameters | a sequence of Named Parameters |
tmesh | the triangle mesh with patches to be faired |
vertices | the vertices of the patches to be faired (the positions of only those vertices will be changed) |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
|
true
if fairing is successful, otherwise no vertices are relocated.is_triangle_mesh(tmesh)
void CGAL::Polygon_mesh_processing::isotropic_remeshing | ( | const FaceRange & | faces, |
const double & | target_edge_length, | ||
PolygonMesh & | pmesh, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/remesh.h>
remeshes a triangulated region of a polygon mesh.
This operation sequentially performs edge splits, edge collapses, edge flips, tangential relaxation and projection to the initial surface to generate a smooth mesh with a prescribed edge length.
PolygonMesh | model of MutableFaceGraph . The descriptor types boost::graph_traits<PolygonMesh>::face_descriptor and boost::graph_traits<PolygonMesh>::halfedge_descriptor must be models of Hashable . |
FaceRange | range of boost::graph_traits<PolygonMesh>::face_descriptor , model of Range . Its iterator type is ForwardIterator . |
NamedParameters | a sequence of Named Parameters |
pmesh | a polygon mesh with triangulated surface patches to be remeshed |
faces | the range of triangular faces defining one or several surface patches to be remeshed |
target_edge_length | the edge length that is targeted in the remeshed patch. If 0 is passed then only the edge-flip, tangential relaxation, and projection steps will be done. |
np | an optional sequence of Named Parameters among the ones listed below |
target_edge_length
.
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
|
split_long_edges()
void CGAL::Polygon_mesh_processing::random_perturbation | ( | VertexRange | vertices, |
TriangleMesh & | tmesh, | ||
const double & | perturbation_max_size, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/random_perturbation.h>
randomly perturbs the locations of non-border vertices of a triangulated surface mesh.
By default, the vertices are re-projected onto the input surface after perturbation. Note that no geometric checks are performed after the perturbation (self-intersections might be introduced).
VertexRange | model of Range , holding vertices of type boost::graph_traits<TriangleMesh>::vertex_descriptor . Its iterator type is ForwardIterator . |
TriangleMesh | model of VertexListGraph . |
NamedParameters | a sequence of Named Parameters |
vertices | the range of vertices to be perturbed |
tmesh | the triangulated surface mesh |
perturbation_max_size | the maximal length of moves that can be applied to vertices of tmesh . |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
| |
| |
|
void CGAL::Polygon_mesh_processing::random_perturbation | ( | TriangleMesh & | tmesh, |
const double & | perturbation_max_size, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/random_perturbation.h>
randomly perturbs the locations of all non-border vertices of a triangulated surface mesh.
By default, the vertices are re-projected onto the input surface after perturbation. Note that no geometric checks are performed after the perturbation (self-intersections might be introduced).
TriangleMesh | model of VertexListGraph . |
NamedParameters | a sequence of Named Parameters |
tmesh | the triangulated surface mesh |
perturbation_max_size | the maximal length of moves that can be applied to vertices of tmesh . |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
| |
| |
|
std::pair<FaceOutputIterator, VertexOutputIterator> CGAL::Polygon_mesh_processing::refine | ( | TriangleMesh & | tmesh, |
const FaceRange & | faces, | ||
FaceOutputIterator | faces_out, | ||
VertexOutputIterator | vertices_out, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/refine.h>
refines a region of a triangle mesh.
TriangleMesh | model of MutableFaceGraph |
FaceRange | range of face descriptors, model of Range . Its iterator type is InputIterator . |
FaceOutputIterator | model of OutputIterator holding boost::graph_traits<TriangleMesh>::face_descriptor for patch faces |
VertexOutputIterator | model of OutputIterator holding boost::graph_traits<TriangleMesh>::vertex_descriptor for patch vertices |
NamedParameters | a sequence of Named Parameters |
tmesh | triangle mesh with patches to be refined |
faces | the range of faces defining the patches to refine |
faces_out | output iterator into which descriptors of new faces are recorded |
vertices_out | output iterator into which descriptors of new vertices are recorded |
np | an optional sequence of Named Parameters among the ones listed below |
| |
|
faces_out
and vertices_out
is_triangle_mesh(tmesh)
bool CGAL::Polygon_mesh_processing::remesh_almost_planar_patches | ( | const TriangleMeshIn & | tm_in, |
PolygonMeshOut & | pm_out, | ||
std::size_t | nb_patches, | ||
std::size_t | nb_corners, | ||
FacePatchMap | face_patch_map, | ||
VertexCornerMap | vertex_corner_map, | ||
EdgeIsConstrainedMap | ecm, | ||
const NamedParametersIn & | np_in = parameters::default_values() , |
||
const NamedParametersOut & | np_out = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/remesh_planar_patches.h>
generates a new triangle mesh pm_out
with the minimal number of triangles from a partition of tm_in
.
The terminology used here and the global idea is very similar to what is done by remesh_planar_patches()
except that here the partition into patches and corner identification is provided by the user. It allows to have a remeshing of almost coplanar regions, detected for example using the region growing algorithm with the functions region_growing_of_planes_on_faces()
and detect_corners_of_regions()
. If a patch cannot be triangulated, it is left untouched in the output and all its vertices become corners so that the output is still a valid conformal triangle mesh.
true
if all patches could be triangulated and false
otherwise.TriangleMeshIn | a model of HalfedgeListGraph and FaceListGraph |
PolygonMeshOut | a model of MutableFaceGraph |
FacePatchMap | a class model of ReadablePropertyMap with boost::graph_traits<TriangleMeshIn>::face_descriptor as key type and std::size_t as value type |
EdgeIsConstrainedMap | a class model of ReadablePropertyMap with boost::graph_traits<TriangleMeshIn>::edge_descriptor as key type and bool as value type |
VertexCornerMap | a class model of ReadablePropertyMap with boost::graph_traits<TriangleMeshIn>::vertex_descriptor as key type and std::size_t as value type |
NamedParametersIn | a sequence of Named Parameters |
NamedParametersOut | a sequence of Named Parameters |
tm_in | input triangle mesh |
pm_out | output polygon mesh |
nb_patches | the number of patches in the partition |
nb_corners | the number of corners |
face_patch_map | a property map that contains for each face the id of its patch in the range [0, nb_patches] |
vertex_corner_map | a property map that contains for each vertex that is a corner an id in the range [0, nb_corners - 1] , and std::size_t(-1) otherwise. |
ecm | a property map that contains true if an edge is on the border of a patch and false otherwise. |
np_in | an optional sequence of Named Parameters among the ones listed below: |
| |
| |
|
np_out | an optional sequence of Named Parameters among the ones listed below: |
| |
| |
| |
| |
|
void CGAL::Polygon_mesh_processing::remesh_planar_patches | ( | const TriangleMeshIn & | tm_in, |
PolygonMeshOut & | pm_out, | ||
const NamedParametersIn & | np_in = parameters::default_values() , |
||
const NamedParametersOut & | np_out = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/remesh_planar_patches.h>
generates a new triangle mesh pm_out
with the minimal number of triangles while preserving the shape of tm_in
.
In practice, this means that connected components of edge-connected faces belonging to the same plane are first extracted (each such connected component is called a patch). Then, the connected components of vertex-connected patch border edges belonging to the same line are extracted. Endpoints of such components and vertices incident to more than two patches (or two patches + one mesh boundary) are called corners. pm_out
contains the 2D constrained Delaunay triangulation of each patch using only corner vertices on the boundary of the patch.
tm_in
contains a non-manifold vertex, pm_out
will be empty. Those vertices must be duplicated with duplicate_non_manifold_vertices()
to get an output.TriangleMeshIn | a model of HalfedgeListGraph and FaceListGraph |
PolygonMeshOut | a model of MutableFaceGraph |
NamedParametersIn | a sequence of Named Parameters |
NamedParametersOut | a sequence of Named Parameters |
tm_in | input triangle mesh |
pm_out | output polygon mesh |
np_in | an optional sequence of Named Parameters among the ones listed below: |
| |
| |
| |
| |
| |
|
np_out | an optional sequence of Named Parameters among the ones listed below: |
| |
| |
| |
| |
|
void CGAL::Polygon_mesh_processing::smooth_shape | ( | const FaceRange & | faces, |
TriangleMesh & | tmesh, | ||
const double | time, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/smooth_shape.h>
smooths the overall shape of the mesh by using the mean curvature flow.
The effect depends on the curvature of each area and on a time step which represents the amount by which vertices are allowed to move. The result conformally maps the initial surface to a sphere.
TriangleMesh | model of MutableFaceGraph . |
FaceRange | range of boost::graph_traits<TriangleMesh>::face_descriptor , model of Range . Its iterator type is ForwardIterator . |
NamedParameters | a sequence of Named Parameters |
tmesh | a polygon mesh with triangulated surface patches to be smoothed. |
faces | the range of triangular faces defining one or several surface patches to be smoothed. |
time | a time step that corresponds to the speed by which the surface is smoothed. A larger time step results in faster convergence but details may be distorted to a larger extent compared to more iterations with a smaller step. Typical values scale in the interval (1e-6, 1]. |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
| |
| |
| |
|
angle_and_area_smoothing()
void CGAL::Polygon_mesh_processing::split_long_edges | ( | const EdgeRange & | edges, |
const double & | max_length, | ||
PolygonMesh & | pmesh, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/remesh.h>
splits the edges listed in edges
into sub-edges that are not longer than the given threshold max_length
.
Note this function is useful to split constrained edges before calling isotropic_remeshing()
with protection of constraints activated (to match the constrained edge length required by the remeshing algorithm to be guaranteed to terminate)
PolygonMesh | model of MutableFaceGraph that has an internal property map for CGAL::vertex_point_t . |
EdgeRange | range of boost::graph_traits<PolygonMesh>::edge_descriptor , model of Range . Its iterator type is InputIterator . |
NamedParameters | a sequence of Named Parameters |
pmesh | a polygon mesh |
edges | the range of edges to be split if they are longer than given threshold |
max_length | the edge length above which an edge from edges is split into to sub-edges |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
| |
|
isotropic_remeshing()
TriangleMeshOut CGAL::Polygon_mesh_processing::surface_Delaunay_remeshing | ( | const TriangleMesh & | tmesh, |
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/surface_Delaunay_remeshing.h>
remeshes a surface triangle mesh following the Delaunay refinement algorithm described in the 3D Mesh Generation package.
TriangleMesh | model of FaceListGraph |
TriangleMeshOut | model of FaceListGraph , model of DefaultConstructible , with an internal property map for CGAL::vertex_point_t with geom_traits::Point_3 as value type. |
NamedParameters | a sequence of Named Parameters |
tmesh | a triangle surface mesh |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
|
tmesh
must be free of self-intersections.edge_is_constrained_map
, polyline_constraints
, and features_angle_bound
. The selected edges are protected only if protect_constraints
is set to true
. void CGAL::Polygon_mesh_processing::tangential_relaxation | ( | const VertexRange & | vertices, |
TriangleMesh & | tm, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/tangential_relaxation.h>
applies an iterative area-based tangential smoothing to the given range of vertices.
Each vertex v
is relocated to its gravity-weighted centroid, and the relocation vector is projected back to the tangent plane to the surface at v
, iteratively. The connectivity remains unchanged.
TriangleMesh | model of FaceGraph and VertexListGraph . The descriptor types boost::graph_traits<TriangleMesh>::face_descriptor and boost::graph_traits<TriangleMesh>::halfedge_descriptor must be models of Hashable . |
VertexRange | range of boost::graph_traits<TriangleMesh>::vertex_descriptor , model of Range . Its iterator type is ForwardIterator . |
NamedParameters | a sequence of Named Parameters |
vertices | the range of vertices which will be relocated by relaxation |
tm | the triangle mesh to which vertices belong |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
| |
| |
| |
| |
|
bool CGAL::Polygon_mesh_processing::triangulate_face | ( | typename boost::graph_traits< PolygonMesh >::face_descriptor | f, |
PolygonMesh & | pmesh, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/triangulate_faces.h>
triangulates a single face of a polygon mesh.
This function depends on the package 2D Triangulations.
PolygonMesh | a model of FaceListGraph and MutableFaceGraph |
NamedParameters | a sequence of Named Parameters |
f | face to be triangulated |
pmesh | the polygon mesh to which the face to be triangulated belongs |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
|
This function calls CGAL::Polygon_mesh_processing::triangulate_hole_polyline()
. Refer to its documentation for its named parameters.
f
is not degenerate.true
if the face has been triangulated.triangulate_faces()
bool CGAL::Polygon_mesh_processing::triangulate_faces | ( | FaceRange | face_range, |
PolygonMesh & | pmesh, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/triangulate_faces.h>
triangulates given faces of a polygon mesh.
This function depends on the package 2D Triangulations.
FaceRange | range of boost::graph_traits<PolygonMesh>::face_descriptor , model of Range . Its iterator type is InputIterator . |
PolygonMesh | a model of FaceListGraph and MutableFaceGraph |
NamedParameters | a sequence of Named Parameters |
face_range | the range of faces to be triangulated |
pmesh | the polygon mesh to be triangulated |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
|
This function calls CGAL::Polygon_mesh_processing::triangulate_hole_polyline()
for each face. Refer to its documentation for its named parameters.
face_range
is degenerate.true
if all the faces have been triangulated.bool CGAL::Polygon_mesh_processing::triangulate_faces | ( | PolygonMesh & | pmesh, |
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/triangulate_faces.h>
triangulates all faces of a polygon mesh.
This function depends on the package 2D Triangulations.
PolygonMesh | a model of FaceListGraph and MutableFaceGraph |
NamedParameters | a sequence of Named Parameters |
pmesh | the polygon mesh to be triangulated |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
|
This function calls CGAL::Polygon_mesh_processing::triangulate_hole_polyline()
on all the faces of the polygon mesh. Refer to its documentation for its named parameters.
pmesh
is degenerate.true
if all the faces have been triangulated.bool CGAL::Polygon_mesh_processing::triangulate_polygons | ( | const PointRange & | points, |
PolygonRange & | polygons, | ||
const NamedParameters & | np = parameters::default_values() |
||
) |
#include <CGAL/Polygon_mesh_processing/triangulate_faces.h>
triangulates all polygons of a polygon soup.
This function depends on the package 2D Triangulations.
PointRange | a model of ConstRange . The value type of its iterator is the point type. |
PolygonRange | a model of the concepts SequenceContainer and Swappable , whose value_type is itself a model of the concept SequenceContainer whose value_type is std::size_t . |
NamedParameters | a sequence of Named Parameters |
points | the point geometry of the soup to be triangulated |
polygons | the polygons to be triangulated |
np | an optional sequence of Named Parameters among the ones listed below |
| |
| |
|
This function calls CGAL::Polygon_mesh_processing::triangulate_hole_polyline()
for each polygon. Refer to its documentation for its named parameters.
polygons
is degenerate.true
if all the polygons have been triangulated.triangulate_faces()