Advertisement

How to create a convex volume out of a "soup" of "points"?

Started by June 15, 2018 03:13 AM
2 comments, last by LorenzoGatti 6 years, 7 months ago

If I have a bunch of "Points" in my world, how is it possible to construct a convex volume out of them? I've checked with the recast source code, the original source of the convex volume is a soup of triangles or polygons. If I use the rubber band algorithm, I can end up with a contour, but it's way too many "vertices" around the contour. Is it the only thing I can do is to check when I trace along the contour, whether the direction of the lines have changed, if so, I create a vertex at wherever the direction changes?

thanks

Jack

https://en.wikipedia.org/wiki/Convex_hull_algorithms

Advertisement

If you think the convex hull of your points is too complex, you can always compute a convex enclosing volume that has a larger volume but less vertices, edges and faces. For example:

  • an enclosing sphere
  • a box, either axis-aligned (cheaper to compute) or oriented optimally (smaller volume)
  • simplifications of the convex hull, such as adding points to make several existing vertices sink into the interior.

What do you need an exact or approximate convex hull for? The costs affecting the volume vs. complexity tradeoff are hard to guess.

Omae Wa Mou Shindeiru

This topic is closed to new replies.

Advertisement