I have a list of vertices in 3d, in random order. I need to construct a polygon from them.
I've found a solution for this in 2d, that uses polar coordinates: ordering shuffled points that can be joined to form a polygon (in python)
It calculates the center of the shape, then arranges the vertices by polar coordinate. Problem is, in 3d there are 2 angles involved, if I use spherical coordinates. How do I sort my list of vertices in case of sphereical coordinates?