Convex Hull Algorithm application - gesture-recognition

For what purpose is Convex Hull algorithm used in Hand gesture recognition using image processing in MATLAB?

Gesture-recognition applications utilizes computational geometry features and algorithms. In mathematical description, Convex Hull is the smallest convex set that contains given set of points. So, you may think that; in "hand-gesture-recognition" domain the convex hull is used to find area of the hand on the given image or image stream.
Consider the example;
The example shows the formation of the hand when all fingers are open.
Then, think about other formations of the hand;
Basically; you can see that for different formations results in different convex hull geometry. By inspecting geometry you can count the number of fingers open etc.
For detailed information, see that paper.

Related

Flood-fill algorithm to define convex areas

I am looking to try and create a flood-fill type algorithm, but one which will break the space into convex regions.
In terms of what my application has in terms of data, all it has is a grid of squares where each square contains connections to the surrounding squares in the cardinal direction. If a square is blocked or invalid in some way, then the square I'm testing won't have a connection in that direction. Screenshot below illustrates what I mean, where black squares are invalid and represent the boundaries of objects:
What I want to do now is try to come up with an algorithm which means I can tag each grid square as belonging to a convex region, ideally with as few areas as possible (i.e. favouring larger convex areas rather than lots of little fragments). Something like the below where each colour represents a different convex region:
Is there a known algorithm for this? I've looked at a few flood-fill algorithms, but none of them seem to be able to form convex shapes like this.
Thanks!
K-means clustering can be used to try to find some interesting partitions.
Feel free to read more details here (https://www.cs.ubc.ca/~schmidtm/Courses/340-F17/L9.pdf)
Someone mentioned in the comments, you application look somehow like a Voronoi diagram.

Computing the upper convex hull in 3d using Qhull

I am trying to compute the upper convex hull of a cloud of point in 3D using Qhull. I do not know if there is a simple way to do it.
I've looked into several options of the modules ConvexHull and Delaunay, 'Qu' furthest site, but i do not think it does what I want, as it seems to be a way of computing the Delaunay triangulation using lower/upper convex hulls.
Another way of engineering a solution could be for each simplice of the convex hull to compute the normal and the center point of the surface, as to introduce a new point close to the center following a translation upon the normal.
Having added this point I could just compute the convex hull of the original ensemble plus this point and see if this point is interior to the hull or not.
I could then deduce if the simplice belongs to the upper and/or the lower hull.

Build constrained alpha shape of polygons

I have a quite specific task.
I need to compute alpha shape of a set of points. (You can frolic with already implemented algorith there)
The point is that I have predefined subsets of points (let's call them details) and I do not want their structure to be changed. For example, suppose these polygons to be details:
Then, the following hulls are ok depending on alpha-radius:
And the following is not:
In brief, I want the structure of specified subsets of points to stay unchanged during reducing the radius.
So, how do you think:
May I use any of already implemented algorithm or should I figure out some specific one?
Is there implemented example of Alpha-Shape algorithm with open source code anywhere? (Alpha-Shape, not Concave hull. It must split contour into several parts when reducing the radius)
Well, Finally I solved this using constrained Delaunay triangulation.
The idea (that Yves Daoust shared in comment to the question) was to use not just Delaunay triangulation during building Alpha shape, but constrained Delaunay triangulation.
Algorithm: In brief, I:
Took convex hull of the promoted polygons
Computed its constrained triangulation. (Constraining segments are polygon's edges)
On this step I used Triangle .NET library for C#. I guess, every popular language has alternatives to it.
Built alpha shape: threw away all triangles where any edge is longer than predefined alpha
Results of my struggles:
Alpha = 1000, alpha shape is just a convex hull
Alpha = 400
Alpha = 30. Only very small concavities are smoothened
Feel free to write me for a deeper explanation, if you wish.

Convex segmentation in 3D from just points?

I have a set of 3D points. The coordinates are all integers with no decimals to worry about.
I have to convert these points to a collection of convex hulls (point collections only - the triangulation code is already done and working).
The goal is to create pseudo-concave meshes from points via convex segmentation. Overlapping meshes as well as incorrect normals are not concerns in this case.
The points have no index nor connectivity structure amongst themselves. Rather, connectivity in my program is assumed by:
-All neighbors are considered. (Like 8-way searching in 2D).
-A neighbor in my program is exactly the same as in image processing - distances greater than 1 unit assume the points are not neighbors.
The question is, does an algorithm exist for this?
Here's an image to help describe the desired effect:
(Note that I don't have the 10 reputation points to post it directly. It's just a link.)
https://i.imgur.com/ii3hU1p.jpg

Numerical Integration of area defined by set of coordinates?

Suppose you have a general shape defined by a bunch of coordinate points that form something that looks like a circle, ellipse, or general closed curve - how do you find the area bounded by these points?
Find the convex hull of the set of points. Record down the points at the boundary.
Compute the area of the polygon bounded by those points.
If those points may not define a convex polygon, you need a concave hull algorithm in step 1.
you would typically use Monte Carlo integration or integration on the grid for multidimensional integration. you can adapt the same approach for flat surface as well.

Resources