mirror of https://github.com/CGAL/cgal
Replace vpmap constructor with np in Adaptive_sizing_field
This commit is contained in:
parent
3b4af4be31
commit
e9aa5b9b3b
|
|
@ -82,13 +82,21 @@ public:
|
|||
* edge lengths
|
||||
* @param face_range the range of triangular faces defining one or several surface patches
|
||||
* to be remeshed. It should be the same as the range of faces passed to `isotropic_remeshing()`.
|
||||
* \param vpmap is the input vertex point map that associates points to the vertices of
|
||||
* the input mesh.
|
||||
* @param pmesh a polygon mesh with triangulated surface patches to be remeshed. It should be the
|
||||
* same mesh as the one passed to `isotropic_remeshing()`.
|
||||
* @param np an optional sequence of \ref bgl_namedparameters "Named Parameters" among the ones listed below
|
||||
|
||||
* \cgalNamedParamsBegin
|
||||
* \cgalParamNBegin{vertex_point_map}
|
||||
* \cgalParamDescription{a property map associating points to the vertices of `pmesh`}
|
||||
* \cgalParamType{a class model of `ReadWritePropertyMap` with
|
||||
* `boost::graph_traits<PolygonMesh>::%vertex_descriptor`
|
||||
* as key type and `%Point_3` as value type}
|
||||
* \cgalParamDefault{`boost::get(CGAL::vertex_point, pmesh)`}
|
||||
* \cgalParamExtra{If this parameter is omitted, an internal property map for `CGAL::vertex_point_t`
|
||||
* must be available in `PolygonMesh`.}
|
||||
* \cgalParamNEnd
|
||||
*
|
||||
* \cgalParamNBegin{ball_radius}
|
||||
* \cgalParamDescription{`ball_radius` parameter passed to `interpolated_corrected_curvatures()`}
|
||||
* \cgalParamNEnd
|
||||
|
|
@ -99,13 +107,14 @@ public:
|
|||
Adaptive_sizing_field(const FT tol
|
||||
, const std::pair<FT, FT>& edge_len_min_max
|
||||
, const FaceRange& face_range
|
||||
, const VPMap& vpmap
|
||||
, PolygonMesh& pmesh
|
||||
, const NamedParameters& np = parameters::default_values())
|
||||
: tol(tol)
|
||||
, m_short(edge_len_min_max.first)
|
||||
, m_long(edge_len_min_max.second)
|
||||
, m_vpmap(vpmap)
|
||||
, m_vpmap(parameters::choose_parameter(
|
||||
parameters::get_parameter(np, internal_np::vertex_point),
|
||||
get_property_map(vertex_point, pmesh)))
|
||||
, m_vertex_sizing_map(get(Vertex_property_tag(), pmesh))
|
||||
{
|
||||
if (face_range.size() == faces(pmesh).size())
|
||||
|
|
@ -128,50 +137,6 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
/*!
|
||||
* returns an object to serve as criteria for adaptive curvature-based edge lengths. It calls
|
||||
* the first constructor using default values for the vertex point map of the input polygon mesh.
|
||||
*
|
||||
* @tparam FaceRange range of `boost::graph_traits<PolygonMesh>::%face_descriptor`,
|
||||
* model of `Range`. Its iterator type is `ForwardIterator`.
|
||||
* @tparam NamedParameters a sequence of \ref bgl_namedparameters "Named Parameters"
|
||||
*
|
||||
* @param tol the error tolerance, used together with curvature to derive target edge length.
|
||||
* Lower tolerance values will result in shorter mesh edges.
|
||||
* @param edge_len_min_max is the stopping criterion for minimum and maximum allowed
|
||||
* edge length.
|
||||
* @param face_range the range of triangular faces defining one or several surface patches
|
||||
* to be remeshed. It should be the same as the range of faces used for `isotropic_remeshing()`.
|
||||
* @param pmesh a polygon mesh with triangulated surface patches to be remeshed. It should be the
|
||||
* same mesh as the one used in `isotropic_remeshing()`. Additionally, the default vertex point
|
||||
* map of pmesh is used to construct the class.
|
||||
* @param np an optional sequence of \ref bgl_namedparameters "Named Parameters" among the ones listed below
|
||||
|
||||
* \cgalNamedParamsBegin
|
||||
* \cgalParamNBegin{ball_radius}
|
||||
* \cgalParamDescription{a scalar value specifying the radius used for expanding curvature measures.
|
||||
* It can potentially smooth the curvature and consequently the sizing field in the
|
||||
* case of noisy input.}
|
||||
* \cgalParamDescription{a scalar value specifying the radius used for expanding curvature measures.
|
||||
* It can effectively smooth the curvature field and consequently the sizing field.}
|
||||
* \cgalParamType{`Base::FT`}
|
||||
* \cgalParamDefault{`-1`}
|
||||
* \cgalParamExtra{If this parameter is omitted (`-1`), the expansion will just by a weightless sum of
|
||||
* measures on faces around the vertex.}
|
||||
* \cgalParamNEnd
|
||||
* \cgalNamedParamsEnd
|
||||
*/
|
||||
template <typename FaceRange
|
||||
, typename NamedParameters = parameters::Default_named_parameters>
|
||||
Adaptive_sizing_field(const FT tol
|
||||
, const std::pair<FT, FT>& edge_len_min_max
|
||||
, const FaceRange& face_range
|
||||
, PolygonMesh& pmesh
|
||||
, const NamedParameters& np = parameters::default_values())
|
||||
: Adaptive_sizing_field(tol, edge_len_min_max, face_range,
|
||||
get(CGAL::vertex_point, pmesh), pmesh, np)
|
||||
{}
|
||||
|
||||
///@}
|
||||
|
||||
private:
|
||||
|
|
|
|||
Loading…
Reference in New Issue