Class AlphaShape


  • @Reference(authors="H. Edelsbrunner, D. G. Kirkpatrick, R. Seidel",
               title="On the shape of a set of points in the plane",
               booktitle="IEEE Trans. Inf. Theory 29(4)",
               url="https://doi.org/10.1109/TIT.1983.1056714",
               bibkey="DBLP:journals/tit/EdelsbrunnerKS83")
    public class AlphaShape
    extends java.lang.Object
    Compute the alpha-shape of a point set, using Delaunay triangulation.

    Reference:

    H. Edelsbrunner, D. G. Kirkpatrick, R. Seidel
    On the shape of a set of points in the plane
    IEEE Trans. Inf. Theory 29(4)

    Since:
    0.5.0
    Author:
    Erich Schubert
    • Constructor Summary

      Constructors 
      Constructor Description
      AlphaShape​(java.util.List<double[]> points, double alpha)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private void addEdge​(java.util.List<IntegerArray> open, int a, int b)
      Add an edge to the corresponding polygon.
      private void checkNeighbors​(java.util.List<IntegerArray> open, long[] visited, IntegerArray stack)  
      java.util.List<Polygon> compute()
      Compute the alpha shape.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • alpha2

        private double alpha2
        Alpha shape
      • points

        private java.util.List<double[]> points
        Points
    • Constructor Detail

      • AlphaShape

        public AlphaShape​(java.util.List<double[]> points,
                          double alpha)
        Constructor.
        Parameters:
        points - point set
        alpha - alpha parameter
    • Method Detail

      • compute

        public java.util.List<Polygon> compute()
        Compute the alpha shape.
        Returns:
        polygons
      • checkNeighbors

        private void checkNeighbors​(java.util.List<IntegerArray> open,
                                    long[] visited,
                                    IntegerArray stack)
      • addEdge

        private void addEdge​(java.util.List<IntegerArray> open,
                             int a,
                             int b)
        Add an edge to the corresponding polygon. This handles holes.
        Parameters:
        open - List of open polygons
        a - previous point
        b - next point