I have a series of points. How can I convert them into a polygon similar to the one shown in the red box below?
I think maybe we should group by the specified distance and create polygons by grouping.
How you pick your set of points is a design decision that only you can make, but once you have a collection of points you can use the JTS ConcaveHull class to create a boundary around the points.