globalFractionToSegmentIndexAndLocalFraction Method

Convert a global linestring fraction to a segment index and local fraction.

globalFractionToSegmentIndexAndLocalFraction(globalFraction: number): { fraction: number, index: number }

@returns segment index and local fraction

Parameter Type Description
globalFraction number a fraction f in [0,1] in the linestring parameterization, where the i_th segment
(0 <= i < N) is parameterized by i/N <= f <= (i+1)/N.

Returns - { fraction: number, index: number }

segment index and local fraction

Defined in

Last Updated: 29 March, 2024