gis-tools-ts - v0.6.0
    Preparing search index...

    Class LengthMetric

    1D Length Metric

    Hierarchy (View Summary)

    Index

    Constructors

    • Parameters

      • deriv: number

        The "deriv" value of a metric is a derivative, and must be multiplied by a length or area in (s,t)-space to get a useful value.

      Returns LengthMetric

    Properties

    deriv: number

    The "deriv" value of a metric is a derivative, and must be multiplied by a length or area in (s,t)-space to get a useful value.

    dim: number

    The dimension of the metric

    Methods

    • Return the level at which the metric has approximately the given value. For example, K_AVG_EDGE.getClosestLevel(0.1) returns the level at which the average cell edge length is approximately 0.1. The return value is

      Parameters

      • value: number

        The value at which to compute the level

      Returns number

      • the minimum level such that the metric is at most the given value
    • Return the minimum level such that the metric is at most the given value, or S2CellId::kMaxLevel if there is no such level. For example, K_MAX_DIAG.getLevelForMaxValue(0.1) returns the minimum level such that all cell diagonal lengths are 0.1 or smaller. The return value is always a valid level.

      Parameters

      • value: number

        The value at which to compute the level

      Returns number

      • the minimum level such that the metric is at most the given value
    • Return the maximum level such that the metric is at least the given value, or 0 if there is no such level. For example, K_MAX_DIAG.getLevelForMinValue(0.1) returns the maximum level such that all cells have a minimum width of 0.1 or larger. The return value is always a valid level.

      Parameters

      • value: number

        The value at which to compute the level

      Returns number

      • the maximum level such that the metric is at least the given value
    • Return the value of a metric for cells at the given level. The value is either a length or an area on the unit sphere, depending on the particular metric.

      Parameters

      • level: number

        The level at which to compute the metric

      Returns number

      The value of the metric