Reputation: 4532
I've got a bunch of 3D vertex positions & need to generate a convex hull containing them; does anyone know of any QHull bindings for .NET? or native 3D Delaunay triangulation algorithms?
Upvotes: 6
Views: 1685
Reputation: 96109
A 3d delaunay is tricky, I'm not sure it's even possible to strictly define a delaunay constraint for a 3d surface.
The normal technique if you just want to mesh a surface is to pick a direction and map that onto 2 coordinates and do a 2d delaunay. For a height map it's easy to just use x,y.
Then when you have the nodes forming each triangle you can of course use their 3d coordinates.
The best 2d code is probably http://www.cs.cmu.edu/~quake/triangle.html
This will also give you the convex hull
Upvotes: 2
Reputation: 2980
Seems like you need MI Convex Hull: https://miconvexhull.codeplex.com/
Upvotes: 2
Reputation: 2171
Since this is the top google hit for "convex hull generation", I want to point readers towards Stan Melax's hull generation code. It's been packaged by John Ratcliff as "stanhull". Easier to work with than QHull.
Edit: A link to stanhull
Upvotes: 0