All Known Implementing Classes:
DistanceFunctionType, MinkowskiDistance

public interface DistanceFunction
Interface marking the implementing class as a distance function for noise generation.
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    distance(double x0, double x1)
    Gets the distance from a 1D point to another 1D point.
    double
    distance(double x0, double y0, double x1, double y1)
    Gets the distance from a 2D point to another 2D point.
    double
    distance(double x0, double y0, double z0, double x1, double y1, double z1)
    Gets the distance from a 3D point to another 3D point.
    double
    distance(double x0, double y0, double z0, double w0, double x1, double y1, double z1, double w1)
    Gets the distance from a 4D point to another 4D point.
  • Method Details

    • distance

      double distance(double x0, double x1)
      Gets the distance from a 1D point to another 1D point.
      Parameters:
      x0 - X-Coordinate of the first point.
      x1 - X-Coordinate of the second point.
      Returns:
      a positive distance between P(x0) and Q(x1)
    • distance

      double distance(double x0, double y0, double x1, double y1)
      Gets the distance from a 2D point to another 2D point.
      Parameters:
      x0 - X-Coordinate of the first point.
      y0 - Y-Coordinate of the first point.
      x1 - X-Coordinate of the second point.
      y1 - Y-Coordinate of the second point.
      Returns:
      a positive distance between P(x0, y0) and Q(x1, y1)
    • distance

      double distance(double x0, double y0, double z0, double x1, double y1, double z1)
      Gets the distance from a 3D point to another 3D point.
      Parameters:
      x0 - X-Coordinate of the first point.
      y0 - Y-Coordinate of the first point.
      z0 - Z-Coordinate of the first point.
      x1 - X-Coordinate of the second point.
      y1 - Y-Coordinate of the second point.
      z1 - Z-Coordinate of the second point.
      Returns:
      a positive distance between (x0, y0, z0) and (x1, y1, z1)
    • distance

      double distance(double x0, double y0, double z0, double w0, double x1, double y1, double z1, double w1)
      Gets the distance from a 4D point to another 4D point.
      Parameters:
      x0 - X-Coordinate of the first point.
      y0 - Y-Coordinate of the first point.
      z0 - Z-Coordinate of the first point.
      w0 - W-Coordinate of the first point.
      x1 - X-Coordinate of the second point.
      y1 - Y-Coordinate of the second point.
      z1 - Z-Coordinate of the second point.
      w1 - W-Coordinate of the second point.
      Returns:
      a positive distance between (x0, y0, z0, w0) and (x1, y1, z1, w1)