Interface IIncrementalTinNavigator

  • All Superinterfaces:
    IProcessUsingTin

    public interface IIncrementalTinNavigator
    extends IProcessUsingTin
    Provides utilities for performing geometry-based query operations on an incremental tin.
    • Method Detail

      • getContainingTriangle

        SimpleTriangle getContainingTriangle​(double x,
                                             double y)
        Gets a triangle from the TIN that contains the specified coordinate point (if any). If the coordinates lie outside the bounds of the TIN, this method returns a null.
        Parameters:
        x - a valid Cartesian coordinate
        y - a valid Cartesian coordinate
        Returns:
        if successful, a valid triangle instance; otherwise, a null.
      • getNearestEdge

        NearestEdgeResult getNearestEdge​(double x,
                                         double y)
        Gets nearest edge to the specified coordinate point. If the coordinates are exterior to the tin, gets the outside element of the nearest perimeter edge. This method is slightly more costly than the getNeighborEdge() method (see below), but it provides more information.
        Parameters:
        x - a valid Cartesian coordinate
        y - a valid Cartesian coordinate
        Returns:
        if the TIN is properly initialized, a valid edge instance; otherwise, a null.
      • getNearestVertex

        Vertex getNearestVertex​(double x,
                                double y)
        Gets the nearest vertex to the specified coordinates
        Parameters:
        x - a valid Cartesian coordinate
        y - a valid Cartesian coordinate
        Returns:
        if the TIN is properly initialized, a valid vertex instance; otherwise, a null.
      • getNeighborEdge

        IQuadEdge getNeighborEdge​(double x,
                                  double y)
        Gets a neighboring edge for the coordinates. If the coordinates are exterior to the tin, gets the outside element of the nearest perimeter edge. The neighbor edge is not necessarily the nearest edge to the query point. If the query point is inside the bounds of the TIN, the neighbor edge will be any of the three edges from the triangle that contains the specified coordinate point.
        Parameters:
        x - a valid Cartesian coordinate
        y - a valid Cartesian coordinate
        Returns:
        if the TIN is properly initialized, a valid edge instance; otherwise, a null.
      • isPointInsideTin

        boolean isPointInsideTin​(double x,
                                 double y)
        Determines whether the point is inside the convex polygon boundary of the TIN. If the TIN is not bootstrapped, this method will return a value of false.
        Parameters:
        x - The x coordinate of interest
        y - THe y coordinate of interest
        Returns:
        true if the coordinates identify a point inside the boundary of the TIN; otherwise, false.
      • resetForChangeToTin

        void resetForChangeToTin()
        Reset the navigator due to a change in the TIN. This call is important because the navigators maintain state data about the TIN in order to expedite queries. If the TIN structure changes, that state data, is rendered obsolete and may cause serious error results. For reasons of efficiency, the Tinfour library offers no protection from changes to the TIN. So it is important that an application manage this issue correctly.

        Resetting the state data unnecessarily may result in a performance reduction when processing a large number of operations, but is otherwise harmless.

        Specified by:
        resetForChangeToTin in interface IProcessUsingTin