Subject: CGAL users discussion list
List archive
[cgal-discuss] make_mesh_3 with manifold() specified outputing non-manifold mesh
Chronological Thread
- From: Kim <>
- To:
- Subject: [cgal-discuss] make_mesh_3 with manifold() specified outputing non-manifold mesh
- Date: Mon, 5 Oct 2020 10:52:27 -0500 (CDT)
- Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=SoftFail ; spf=Pass
- Ironport-phdr: 9a23:utBHYRAhO7sNRfBiFh+JUyQJP3N1i/DPJgcQr6AfoPdwSPT4oMbcNUDSrc9gkEXOFd2Cra4d1KyK6euxBSQp2tWoiDg6aptCVhsI2409vjcLJ4q7M3D9N+PgdCcgHc5PBxdP9nC/NlVJSo6lPwWB6nK94iQPFRrhKAF7Ovr6GpLIj8Swyuu+54Dfbx9HiTagY75+Nhq7oRveusQSjoZpN7o8xAbOrnZUYepd2HlmJUiUnxby58ew+IBs/iFNsP8/9MBOTLv3cb0gQbNXEDopPWY15Nb2tRbYVguA+mEcUmQNnRVWBQXO8Qz3UY3wsiv+sep9xTWaMMjrRr06RTiu86FmQwLuhSwaNTA27XvXh9R+gqxbvhyvpAFxzIHIb4+aL/d+YqHQcc8GSWZdQspdSSpMCZ68YYsVCOoBOP5VoYz8p1sLsBCzAgysBOL1xjBUgX/2x7c63PomEQ3cwAwvAdcOsGzTrNXvLqgSVfu4zK7VzTXfa/NW3jD96IvSfh89pvGMWKt9fMzMwkYgCw3LlE+fqZD5PzyLzOQNtXCW4uh9We6zhGMqpQF/rzusy8ouioTEmIYYxkzE+Ch53Io4Id+1RU5lbdCrDpZdtSGXOol1T888QmxluyY0x74atJO9YSMExpMnxxvFZPyGdYiF+hTjW/yKLjhjgHJqZqiziAq18UilzOD3S8q60E5SoyZYltTBsmoB2hLQ58SdSfZw/12t1DeO2g3V9+pKO1o7lbDBJJ4k2rMwloQcsUDEHiLunkX7g7WadkM+9eez8OvnZqvpqoWAOI9zjwHyKqUumsqhDuQkKgUCQmyW9OCm2LDt/kD1WrZHg/wsnqTYsZ3WPcEbqbS4Aw9R3IYj8RG/DzK+3dQdnHkLNk5KeBWdj4jzJV7OJ+r0DeuhjFSpiDdrwOrGMaflApjWKXjDjavhfbJ6605bywo/18xQ55VRCr0ZOvL8RlfxtMDEDh8+KwG73+nnB8951o8HRG2PA7SZP7/PsV+T/eIiOPKMZY8QuDblMfcp/f/ujXkjmV8cZ6alx5UXaGrrVshhdk6WaH6pjtYaGnoRpSI/SvbrgRuMS219fXG3CoE943lvDYPgBoDZXI2qxqCM2T+8BJRSTmdbFlSLFnSufIKBDaRfIBmOK9Nsx2RXHYOqTJUsgEn36F3KjoF/J++RwRU28Ir53YEuterOiRU18j8yBMOYgTnUEjNE21gQTjpz55hR5ExwzlDajPp+37peHNZZ4/4PWQA/Z8eFnr5KTuvqUweERe+nDVOvQ9GoGzY0F4ljxMISZ0F6GJOpiRWRhCc=
Hi everyone,
I am using make_mesh_3 to mesh an implicit domain and subsequently
extracting the surface triangulation, clipping it and doing some other
post-processing.
typedef CGAL::Exact_predicates_inexact_constructions_kernel Kernel;
typedef CGAL::Parallel_tag Concurrency_tag;
typedef CGAL::Polyhedron_3<Kernel, CGAL::Polyhedron_items_with_id_3>
PolygonMesh;
typedef CGAL::Labeled_mesh_domain_3<Kernel> Implicit_domain;
typedef CGAL::Mesh_triangulation_3<Implicit_domain, CGAL::Default,
Concurrency_tag>::type VTr;
typedef CGAL::Mesh_complex_3_in_triangulation_3<VTr> C3t3;
typedef CGAL::Mesh_criteria_3<VTr> Mesh_criteria;
Implicit_domain domain = Implicit_domain::create_implicit_mesh_domain(
myImplicitFunction, boundBox);
Mesh_criteria criteria(CGAL::parameters::facet_angle = facetAngle,
CGAL::parameters::facet_size = facetSize,
CGAL::parameters::facet_distance = facetDistance);
C3t3 c3t3 = CGAL::make_mesh_3<C3t3>(domain, criteria,
CGAL::parameters::manifold())
PolygonMesh scaffold;
CGAL::facets_in_complex_3_to_triangle_mesh(c3t3, scaffold);
// Clip mesh
PolygonMesh outer_shell;
CGAL::Polygon_mesh_processing::polygon_soup_to_polygon_mesh(points,
polygons, outer_shell);
CGAL::Polygon_mesh_processing::remove_isolated_vertices(scaffold); //
Temporary fix to bug!!!
if( CGAL::Polygon_mesh_processing::clip(scaffold, outer_shell,
CGAL::parameters::clip_volume(true).use_compact_clipper(true)) == false)
std::cout << "\n WARNING: Scaffold and clipper have only been
corefined!" << std::endl;
// Remove all but the largest component
CGAL::Polygon_mesh_processing::keep_largest_connected_components(scaffold,
1);
// Reorient all faces coherently
if (CGAL::is_closed(scaffold) == true) {
CGAL::Polygon_mesh_processing::orient(scaffold,
CGAL::parameters::outward_orientation(true));
} else {
std::cout << "\n WARNING: Polygon has border edges!" << std::endl;
}
The problem I am experiencing is that although I have specified I want a
manifold mesh make_mesh_3 does not seem to always output one. Some inputs
seem to always result in a non-manifold mesh while others may result in a
non-manifold mesh occasionally without any change in inputs. I get the same
behavior regardless of whether I use mesh optimizations or disable them. Am
I doing something incorrectly?
Kind regards,
Kim
--
Sent from: http://cgal-discuss.949826.n4.nabble.com/
- [cgal-discuss] make_mesh_3 with manifold() specified outputing non-manifold mesh, Kim, 10/05/2020
- Re: [cgal-discuss] make_mesh_3 with manifold() specified outputing non-manifold mesh, Sebastien Loriot (GeometryFactory), 10/05/2020
- Re: [cgal-discuss] make_mesh_3 with manifold() specified outputing non-manifold mesh, Sebastien Loriot (GeometryFactory), 10/05/2020
- Re: [cgal-discuss] make_mesh_3 with manifold() specified outputing non-manifold mesh, Sebastien Loriot (GeometryFactory), 10/05/2020
Archive powered by MHonArc 2.6.19+.