Class ConvexHull2DPtr


  • public class ConvexHull2DPtr
    extends java.lang.Object
    Ptr stores a pointer and optionally takes ownership of the value.
    • Constructor Detail

      • ConvexHull2DPtr

        public ConvexHull2DPtr​(long cPtr,
                               boolean cMemoryOwn)
      • ConvexHull2DPtr

        public ConvexHull2DPtr()
        Default constructor yielding a NULL-pointer.
      • ConvexHull2DPtr

        public ConvexHull2DPtr​(ConvexHull2D ptr)
        Do not take ownership of ptr.

        ptr can be null.

        The constructor is implicit on purpose.
    • Method Detail

      • delete

        public void delete()
      • deref

        public ConvexHull2D deref()
        The pointer stored in the object.
      • __ref__

        public ConvexHull2D __ref__()
        Dereferencing operator.
      • getDeref

        public ConvexHull2D getDeref()
        Member access operator.
      • isShared

        public boolean isShared()
        check if this Ptr has shared ownership or none
        ownership
        Returns:
        true if Ptr has shared ownership, false if it has no ownership.
      • isNull

        public boolean isNull()
        checks if the pointer is null
        Returns:
        Returns true if the pointer is null
      • isInside

        public boolean isInside​(Vector2D vertex)
        test if the given vertex is inside the convex hull
      • getMinDist

        public double getMinDist​(Vector2D vertex)
        if the vertex is inside the convex hull the minimum distance
        to any of the half-spaces of the hull is returned. If its not inside
        0 is returned.
        Parameters:
        vertex -
        Returns:
        minimum distance to vertex