[vtkusers] How to triangulate two non-intersecting polylines (in 2D)

Bill Lorensen bill.lorensen at gmail.com
Fri Feb 23 14:33:16 EST 2018


Look at this example.

https://lorensen.github.io/VTKExamples/site/Cxx/PolyData/RuledSurfaceFilter/



On Feb 23, 2018 11:22 AM, "normanius" <juch at zhaw.ch> wrote:

> Let's be given two polylines in a plane as shown in the figure below. I
> assume that these two lines are not intersecting, but can have a generic
> shape (so they may be non-convex). Note that the number of points varies
> between the two lines. (In my example, the objects have been created using
> vtkRegularPolygonSource)
>
> Do you have an idea how I can triangulate the ring that is defined by the
> inner and outer polyline in vtk? (See second image, for an idea)
>
> Combining the polylines with vtkAppendPolyData does not work, because
> vtkTriangleFilter then would triangulate the two polylines separately. I
> guess the right way would be to create a polygon object that is composed of
> the two lines in a "clever way" and then to call vtkTriangleFilter on this
> data, but I could not manage.
>
> Many thanks for your inputs!
>
> <http://vtk.1045678.n5.nabble.com/file/t341102/Screen_Shot_
> 2018-02-23_at_19.png>
> <http://vtk.1045678.n5.nabble.com/file/t341102/triangulated.png>
>
>
>
> --
> Sent from: http://vtk.1045678.n5.nabble.com/VTK-Users-f1224199.html
> _______________________________________________
> 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
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://vtk.org/pipermail/vtkusers/attachments/20180223/3ad6cc86/attachment.html>


More information about the vtkusers mailing list