meshpro / pygalmesh

:spider_web: A Python interface to CGAL's meshing tools
GNU General Public License v3.0
597 stars 57 forks source link

polygon soup orientation not checked for volume meshing #103

Closed bigfooted closed 4 years ago

bigfooted commented 4 years ago

When a surface mesh is remeshed using remesh-surface, the result is saved without proper orientation. cgal also does this. When loading this surface into a polyhedron instance for volume meshing, the loading fails (In my case always).

A solution for volume meshing is to read the points and polygons from file separately and then call CGAL::Polygon_mesh_processing::orient_polygon_soup() and CGAL::Polygon_mesh_processing::polygon_soup_to polygon_mesh () when a bad orientation is found, or do it always.

nschloe commented 4 years ago

Sure. Can you prepare a PR? Best make it an option, default False.

bigfooted commented 4 years ago

No problem, I will add an activation switch.

nschloe commented 4 years ago

Fixed by #104.