|
CGAL 5.0 - The Heat Method
|
#include <CGAL/Heat_method_3/Surface_mesh_geodesic_distances_3.h>
Class Surface_mesh_geodesic_distances_3 computes estimated geodesic distances for a set of source vertices where sources can be added and removed.
The class performs a preprocessing step that only depends on the mesh, so that the distance computation takes less time after changes to the set of sources.
| TriangleMesh | a triangulated surface mesh, model of FaceListGraph and HalfedgeListGraph |
| Mode | must be Intrinsic_Delaunay to indicate that an intrinsic Delaunay triangulation is internally constructed or Direct to indicate that the input mesh should be used as is. If Intrinsic_Delaunay, then the type TriangleMesh must have an internal property for vertex_point and its value type must be the same as the value type of VertexPointMap. |
| VertexPointMap | a model of ReadablePropertyMap with boost::graph_traits<TriangleMesh>::vertex_descriptor as key and Traits::Point_3 as value type. The default is typename boost::property_map< TriangleMesh, vertex_point_t>::const_type. |
| LA | a model of SparseLinearAlgebraWithFactorTraits_d. If CGAL_EIGEN3_ENABLED is defined, then Eigen_solver_traits<Eigen::SimplicialLDLT<typename Eigen_sparse_matrix<double>::EigenType > > is used as default |
| Traits | a model of HeatMethodTraits_3. The default is the Kernel of the value type of the vertex point map (extracted using Kernel_traits). |
Public Types | |
| typedef boost::graph_traits< TriangleMesh >::vertex_descriptor | vertex_descriptor |
| Vertex descriptor type. | |
| typedef unspecified_type | Vertex_const_range |
a model of ConstRange with an iterator that is model of ForwardIterator with vertex_descriptor as value type. | |
| typedef unspecified_type | Vertex_point_map |
Vertex point map type derived from VertexPointMap. | |
Public Member Functions | |
| Surface_mesh_geodesic_distances_3 (const TriangleMesh &tm) | |
| Constructor. | |
| Surface_mesh_geodesic_distances_3 (const TriangleMesh &tm, Vertex_point_map vpm) | |
| Constructor. | |
| const TriangleMesh & | triangle_mesh () const |
| returns the triangle mesh the algorithm is running on. | |
| bool | add_source (vertex_descriptor vd) |
adds vd to the source set, returning false if vd is already in the set. | |
| template<typename VertexConstRange > | |
| void | add_sources (const VertexConstRange &vrange) |
| adds the range of vertices to the source set. More... | |
| bool | remove_source (vertex_descriptor vd) |
removes vd from the source set, returning true if vd was in the set. | |
| void | clear_sources () |
| clears the current source set. | |
| double | estimate_geodesic_distance (vertex_descriptor vd) const |
get estimated distance from the current source set to a vertex vd. More... | |
| const Vertex_const_range & | sources () const |
| returns the source set. | |
| template<class VertexDistanceMap > | |
| void | estimate_geodesic_distances (VertexDistanceMap vdm) |
| fills the distance property map with the estimated geodesic distance of each vertex to the closest source vertex. More... | |
| void CGAL::Heat_method_3::Surface_mesh_geodesic_distances_3< TriangleMesh, Mode, VertexPointMap, LA, Traits >::add_sources | ( | const VertexConstRange & | vrange | ) |
adds the range of vertices to the source set.
| VertexConstRange | a model of the concept ConstRange with value type boost::graph_traits<TriangleMesh>::vertex_descriptor |
| double CGAL::Heat_method_3::Surface_mesh_geodesic_distances_3< TriangleMesh, Mode, VertexPointMap, LA, Traits >::estimate_geodesic_distance | ( | vertex_descriptor | vd | ) | const |
get estimated distance from the current source set to a vertex vd.
double even when used with an exact kernel. | void CGAL::Heat_method_3::Surface_mesh_geodesic_distances_3< TriangleMesh, Mode, VertexPointMap, LA, Traits >::estimate_geodesic_distances | ( | VertexDistanceMap | vdm | ) |
fills the distance property map with the estimated geodesic distance of each vertex to the closest source vertex.
| VertexDistanceMap | a property map model of WritablePropertyMap with vertex_descriptor as key type and double as value type. |
| vdm | the vertex distance map to be filled |
double even when used with an exact kernel.