doc for SimplicialMeshCellBase_3 concept and class

This commit is contained in:
Jane Tournois 2022-03-24 14:11:43 +01:00
parent 6c243f9bf6
commit 01c97c1498
2 changed files with 38 additions and 97 deletions

View File

@ -3,9 +3,9 @@
\cgalConcept \cgalConcept
The concept `SimplicialMeshCellBase_3` describes the requirements The concept `SimplicialMeshCellBase_3` describes the requirements
for the `Cell` type of the triangulation for the `TriangulationDataStructure_3::Cell` type of the triangulation
used in the 3D simplicial mesh data structure. The type `SimplicialMeshCellBase_3` used in the 3D simplicial mesh data structure. The type `SimplicialMeshCellBase_3`
refines the concept `RegularTriangulationCellBaseWithWeightedCircumcenter_3` refines the concept `Cell`
and must be copy constructible. and must be copy constructible.
The concept `SimplicialMeshCellBase_3` The concept `SimplicialMeshCellBase_3`
includes a way to store and retrieve includes a way to store and retrieve
@ -19,8 +19,7 @@ and four additional helper markers
used in some operations to mark for instance used in some operations to mark for instance
the facets that have been visited. the facets that have been visited.
\cgalRefines `TriangulationCellBase_3 `
\cgalRefines `RegularTriangulationCellBaseWithWeightedCircumcenter_3`
\cgalRefines `CopyConstructible` \cgalRefines `CopyConstructible`
\cgalHasModel `CGAL::Compact_mesh_cell_base_3` \cgalHasModel `CGAL::Compact_mesh_cell_base_3`
@ -33,7 +32,6 @@ the facets that have been visited.
class SimplicialMeshCellBase_3 { class SimplicialMeshCellBase_3 {
public: public:
/// \todo update this file from here
/// \name Types /// \name Types
/// @{ /// @{
@ -50,19 +48,21 @@ of the 3D triangulation in which the mesh is embedded.
typedef unspecified_type Point; typedef unspecified_type Point;
/*! /*!
Type of indices for cells of the input complex. Must match the type `MeshDomain_3::Subdomain_index`. Type of indices for cells of the input complex.
Must match the type `MeshDomain_3::Subdomain_index` in the context of mesh generation.
*/ */
typedef unspecified_type Subdomain_index; typedef unspecified_type Subdomain_index;
/*! /*!
Type of indices for surface patches of the input complex. Must match the type `MeshDomain_3::Surface_patch_index`. Type of indices for surface patches of the input complex.
Must match the type `MeshDomain_3::Surface_patch_index` in the context of mesh generation.
*/ */
typedef unspecified_type Surface_patch_index; typedef unspecified_type Surface_patch_index;
/*! /*!
Type of indices to be stored at mesh vertices to characterize the lowest dimensional face Type of indices to be stored at mesh vertices to characterize the lowest dimensional face
of the input complex on which a possible future Steiner vertex lies. of the input complex on which a possible future Steiner vertex lies.
Must match the type `MeshDomain_3::Index`. Must match the type `MeshDomain_3::Index` in the context of mesh generation.
*/ */
typedef unspecified_type Index; typedef unspecified_type Index;
@ -97,85 +97,29 @@ sets `Surface_patch_index` of facet `i` to `index`.
*/ */
void set_surface_patch_index(int i, Surface_patch_index index); void set_surface_patch_index(int i, Surface_patch_index index);
/*!
Returns `true` iff `facet(i)` has been visited.
*/
bool is_facet_visited (int i);
/*!
Marks `facet(i)` as visited.
*/
void set_facet_visited (int i);
/*!
Marks `facet(i)` as non-visited.
*/
void reset_visited (int i);
/*!
Returns a const reference to the surface center of `facet(i)`.
*/
const Point_3& get_facet_surface_center(int i);
/*!
Sets the point `p` as the surface center of `facet(i)`.
*/
void set_facet_surface_center (int i, Point_3 p);
/*!
Sets the surface center index of `facet(i)` to `index`.
*/
void set_facet_surface_center_index(int i, Index index);
/*!
Returns the surface center index of `facet(i)`.
*/
Index get_facet_surface_center_index(int i);
/// Get the erase counter.
/// Only required by the parallel algorithms.
/// See `CGAL::Compact_container` for more details.
unsigned int erase_counter() const;
/// Sets the erase counter.
/// Only required by the parallel algorithms.
/// See `CGAL::Compact_container` for more details.
void set_erase_counter(unsigned int c);
/// Increments the erase counter.
/// Only required by the parallel algorithms.
/// See `CGAL::Compact_container` for more details.
void increment_erase_counter();
/// @} /// @}
/*! \name Internal /*! \name Internal
These functions are used internally by mesh optimizers. These functions are used internally by mesh optimizers and tetrahedral remeshing.
The class should provide storage, accessors and modificators for two `Vertex_handle` The class should provide storage, accessors and modificators for a cache value for sliverity.*/
and two `Cell_handle`.*/
/// @{ /// @{
/*! /*!
*/ */
Cell_handle next_intrusive() const; void set_sliver_value(double value);
/*! /*!
*/ */
void set_next_intrusive(Cell_handle); double sliver_value() const;
/*! /*!
*/ */
Cell_handle previous_intrusive() const; bool is_cache_valid() const;
/*! /*!
*/ */
void set_previous_intrusive(Cell_handle); void reset_cache_validity() const;
/// @} /// @}
}; /* end SimplicialMeshCellBase_3 */
}; /* end MeshCellBase_3 */

View File

@ -33,19 +33,10 @@
namespace CGAL { namespace CGAL {
/*! //Class Simplicial_mesh_vertex_3
\ingroup PkgSMDS3Classes //Adds information to Vb about the localization of the vertex in regards
Class Simplicial_mesh_vertex_base_3 //to the 3D input complex.
Adds information to Vb about the localization of the vertex in regards //\cgalModels `SimplicialMeshVertexBase_3`
to the 3D input complex.
\cgalModels `SimplicialMeshVertexBase_3`
\sa `CGAL::Mesh_complex_3_in_triangulation_3<Tr,CornerIndex,CurveIndex>`
\sa `CGAL::Mesh_vertex_base_3`
\sa `MeshDomain_3`
\sa `MeshDomainWithFeatures_3`
*/
template<class GT, template<class GT,
typename Subdomain_index, typename Subdomain_index,
typename Surface_patch_index, typename Surface_patch_index,
@ -55,13 +46,15 @@ template<class GT,
class Simplicial_mesh_vertex_3 class Simplicial_mesh_vertex_3
: public Vb : public Vb
{ {
private :
using Cmvb3_base = Vb;
public: public:
typedef Vb Cmvb3_base; using Vertex_handle = typename Vb::Vertex_handle;
typedef typename Vb::Vertex_handle Vertex_handle;
// Types // Types
typedef boost::variant<Subdomain_index, Surface_patch_index, Curve_index, Corner_index> Index; using Index = boost::variant<Subdomain_index, Surface_patch_index, Curve_index, Corner_index>;
typedef typename GT::FT FT; using FT = typename GT::FT;
// Constructor // Constructor
Simplicial_mesh_vertex_3() Simplicial_mesh_vertex_3()
@ -210,30 +203,34 @@ public:
/*! /*!
\ingroup PkgMesh3MeshClasses \ingroup PkgSMDS3Classes
The class `Simplicial_mesh_vertex_base_3` is a model of the concept The class `Simplicial_mesh_vertex_base_3` is a model of the concept
`SimplicialMeshVertexBase_3`. `SimplicialMeshVertexBase_3`.
It is designed to serve as vertex base class for... It is designed to serve as vertex base class for 3D simplicial mesh data structures.
It stores and gives access to data about the complex the vertex belongs to, such as the
index of the subcomplex it belongs to.
\tparam GT is the geometric traits class. \tparam Gt is the geometric traits class.
It must be a model of the concept It must be a model of the concept `RemeshingTriangulationTraits_3`
\tparam Vb is the vertex base class. It has to be a model \tparam Vb is the vertex base class. It has to be a model
of the concept `TriangulationVertexBase_3` and defaults to of the concept `TriangulationVertexBase_3` and defaults to
`Triangulation_vertex_base_3<GT>`. `Triangulation_vertex_base_3<Gt>`.
\cgalModels `SimplicialMeshVertexBase_3` \cgalModels `SimplicialMeshVertexBase_3`
\sa `CGAL::Mesh_complex_3_in_triangulation_3<Tr,CornerIndex,CurveIndex>` \sa `CGAL::Mesh_complex_3_in_triangulation_3`
\sa `CGAL::Mesh_vertex_base_3` \sa `CGAL::Mesh_vertex_base_3`
\sa `MeshDomain_3`
\sa `MeshDomainWithFeatures_3`
*/ */
template<class GT, template<class Gt,
typename Subdomain_index, typename Subdomain_index,
typename Surface_patch_index, typename Surface_patch_index,
typename Curve_index, typename Curve_index,
typename Corner_index, typename Corner_index,
class Vb = Triangulation_vertex_base_3<GT> > class Vb = Triangulation_vertex_base_3<Gt> >
struct Simplicial_mesh_vertex_base_3 struct Simplicial_mesh_vertex_base_3
{ {
using Triangulation_data_structure = internal::Dummy_tds_3; using Triangulation_data_structure = internal::Dummy_tds_3;
@ -243,7 +240,7 @@ struct Simplicial_mesh_vertex_base_3
template < class TDS3 > template < class TDS3 >
struct Rebind_TDS { struct Rebind_TDS {
using Vb3 = typename Vb::template Rebind_TDS<TDS3>::Other; using Vb3 = typename Vb::template Rebind_TDS<TDS3>::Other;
using Other = Simplicial_mesh_vertex_3 <GT, using Other = Simplicial_mesh_vertex_3 <Gt,
Subdomain_index, Subdomain_index,
Surface_patch_index, Surface_patch_index,
Curve_index, Curve_index,