Re: filling in a sphere's intersection with a plane

Andras Lasso <[email protected]> Sat, 12 Jan 2019 14:46:37 +0000
Newsgroups gmane.comp.lib.vtk.user
Message-ID <YTOPR0101MB1292A608705C9C0F2A85D54FD8860@YTOPR0101MB1292.CANPRD01.PROD.OUTLOOK.COM>
Thanks David, I’ve tried replacing stripper+cleaner+triangulator by  your vtkContourTriangulator and it worked very well. Need to do some more testing but probably will switch permanently.

Andras

From: David Gobbi <[email protected]>
Sent: Friday, January 11, 2019 1:27 PM
To: Andras Lasso <[email protected]>
Cc: The Merper <[email protected]>; VTK Users <[email protected]>
Subject: Re: [vtkusers] filling in a sphere's intersection with a plane

On Fri, Jan 11, 2019 at 11:04 AM Andras Lasso <[email protected]<mailto:[email protected]>> wrote:
In general, vtkCutter returns a random (unordered, non-continuous) list of line segments.

Can vtkContourTriangulator deal with that (merge points and order line segments to form closed contours)?

Yes.  If given unordered line segments, vtkContourTriangulator will sort them.  The nightly tests cover this feature.

Usually we apply vtkStripper with a very large MaximumLength on vtkCutter output to create polygons that can be triangulated and rendered. This works well almost every time, but in some cases (cutting very complex geometries with hundreds of thousand of points) stripping does not find closed polygons. It would be nice to have a somewhat simpler and more robust solution.

The vtkCountourTriangulator code has checks to deal with bad geometry.  It's not perfect, but it's much better than vtkPolygon::Triangulate().  I've avoided vtkDelaunay2D because certain geometries will cause it to crash.

I wrote vtkClipClosedSurface specifically to deal with complex 3D geometries (it uses vtkContourTriangulator as its final stage).  I had meant to write a similar filter called vtkCutClosedSurface filter for cutting (instead of clipping) but that never happened.

  David

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
https://vtk.org/mailman/listinfo/vtkusers