Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes for vertex/cell classes of SMDS_3 and Tetrahedral_remeshing #7610

Merged
merged 12 commits into from
Sep 13, 2023

Conversation

MaelRL
Copy link
Member

@MaelRL MaelRL commented Jul 20, 2023

Summary of Changes

The main point of this PR is to restore the API of Remeshing_cell_base_3 to the initial state (since CGAL 5.1), which was changed with the introduction of SMDS_3 in CGAL 5.6 (#5693).

In CGAL 5.5, the class Remeshing_cell_base_3 is templated by a geom traits and a cell base.
In CGAL 5.6, the class became templated by only two index types, removing the possibility to derive from custom (TDS) base cell types.

Also:

  • Decompactify Simplicial_cell_base_3, allowing a cell base to be used
  • Changed the API of Remeshing_vertex_base_3 to match that of Remeshing_cell_base_3 (and other CGAL triangulations): a Gt and a Vb
  • Proper rebind mechanism for VB/CB of SMDS_3 / Tetrahedral remeshing
  • Various fixes of the SMDS_3 / Tetrahedral_remeshing doc.

TODO:

  • Announce the breaking changes in CHANGES.md
  • Introduce Compact_simplicial_cell_base_3?

Release Management

  • Affected package(s): SMDS_3, Tetrahedral_remeshing
  • Issue(s) solved (if any): -
  • Feature/Small Feature (if any): n/a
  • License and copyright ownership: no change

MaelRL added 6 commits July 19, 2023 22:35
Give it a cell base instead of re-implementing everything.
- Restore its correct API (as in CGAL 5.5): two templates, a traits,
and a cell base.
- It is not a model of SimplicialMeshCellBase_3, but of RemeshingCellBase_3
- It should not hardcode an inheritance to Simplicial_cell_base_3,
but take it as a template paramter's default value.
- Use FT instead of hardcoding 'double'
It needs only to document a traits and a vertex base, not expose
index types as these are relevant to the Simplicial_vertex_base_3
class, which is not the systematic base.

It is a model of RemeshingVertexBase_3, not MeshVertexBase_3

The base needs to be a model of SimplicialVertexBase_3, not
TriangulationCellBase_3

Use the proper Rebind mechanism like the other vertex/cell classes
If you have the following construct:

  class V : public Vb;

  class V_base
  {
    struct Rebind --> V;
  }

then you cannot rebind twice. More vicious, if Vb
can rebind twice multiple times (e.g. it's a T3 Vb),
then it'll silently drop V in the stack, and rebind
only up to the rebound Vb!

Rebinding multiple times happens for example in
Triangulation_hierarchy_3 (Delaunay_triangulation_3
with Fast_locate).
@MaelRL
Copy link
Member Author

MaelRL commented Jul 21, 2023

Note that the issue fixed in 3ad1825 probably affects Mesh_3 vertex/cell bases classes. It is quite unlikely that we would rebind multiple times these vertex/cell base classes, but that ought to be fixed too.

Formerly known as Simplicial_mesh_cell_base_3, this cell base
is more efficient in memory, but cannot inherit a base.
@sloriot

This comment was marked as outdated.

@sloriot sloriot added Tests failing Batch_1 First Batch of PRs under testing and removed Under Testing labels Aug 9, 2023
@sloriot
Copy link
Member

sloriot commented Sep 13, 2023

Successfully tested in CGAL-6.0-Ic-61

@sloriot sloriot added Tested and removed Ready to be tested Under Testing Batch_1 First Batch of PRs under testing labels Sep 13, 2023
@github-actions github-actions bot removed the Tested label Sep 13, 2023
@github-actions
Copy link

This pull-request was previously marked with the label Tested, but has been modified with new commits. That label has been removed.

@sloriot sloriot added the Tested label Sep 13, 2023
@lrineau lrineau merged commit 3a54848 into CGAL:master Sep 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants