Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] meshing with hard feature boundary: using all edges as features

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] meshing with hard feature boundary: using all edges as features


Chronological Thread 
  • From: Michel Audette <>
  • To:
  • Subject: Re: [cgal-discuss] meshing with hard feature boundary: using all edges as features
  • Date: Wed, 15 Jun 2011 14:12:44 -0400

Hi Laurent,

I've sent you my data and code snippet privately. The reason that the polygon's edges are important and should be preserved are in part driven by the clinical aspect of the application: I'm trying to model one of the Sylvian fissures, and without these edges as hard boundaries, it would be easy for the mesh generation to fuse the opposing boundaries together, in which case the mesh would no longer be separable at this fissure, which invalidates the mesh as a practical anatomical model. If you have another way of getting around that, I'm willing to discuss it.

Thanks for your kind continued support.

Best wishes,

Michel



In this example, the domain to be meshed is the union of those intersecting
sphere. The polyline 'polyline' is a closed polyline with 361 vertices that
corresponds to the circle that is the intersection between the two spheres.
That means that this polyline will be represented in the final mesh, probably
remeshed with less than 360 vertices.

In your example, the domain to be meshed seems is a polyhedron. You defined
only *one* polyline that contains all vertices of the polyhedron. That cannot
be correct. If you want to preserve *all* edges of the polyhedron (a very bad
idea in my opinion), the code would be something like:

// ...
Polylines polylines;
Polyhedron::Edge_iterator itr_e;
for(itr_e= polyhedron.edges_begin(); itr_e!= polyhedron.edges_end(); ++itr_e )
{
 Polyline new_polyline;
 new_polyline.push_back(itr_e->vertex()->point());
 new_polyline.push_back(itr_e->opposite()->vertex()->point());

 // push the polyline (actually a segment) to the set of polylines
 polylines.push_back(new_polyline);
}
domain.add_features(polylines.begin(), polylines.end());
// ...

That is probably not a good idea to push all edges of a polyhedron as feature
polylines. Because the CGAL 3D mesher will start by sampling all edges of the
polyhedron.


--
Laurent Rineau, PhD
R&D Engineer at GeometryFactory           http://www.geometryfactory.com/
Release Manager of the CGAL Project       http://www.cgal.org/

--
You are currently subscribed to cgal-discuss.
To unsubscribe or access the archives, go to
https://lists-sop.inria.fr/wws/info/cgal-discuss




--
Michel Audette, Ph.D.
R & D Engineer,
Kitware Inc.,
Chapel Hill, N.C.




Archive powered by MHonArc 2.6.16.

Top of Page