mirror of
https://github.com/gpxstudio/gpx.studio.git
synced 2025-12-27 21:49:59 +00:00
speed up wpt to segment matching
This commit is contained in:
@@ -59,13 +59,13 @@ function ramerDouglasPeuckerRecursive(
|
||||
}
|
||||
|
||||
export function crossarcDistance(
|
||||
point1: TrackPoint,
|
||||
point2: TrackPoint,
|
||||
point1: TrackPoint | Coordinates,
|
||||
point2: TrackPoint | Coordinates,
|
||||
point3: TrackPoint | Coordinates
|
||||
): number {
|
||||
return crossarc(
|
||||
point1.getCoordinates(),
|
||||
point2.getCoordinates(),
|
||||
point1 instanceof TrackPoint ? point1.getCoordinates() : point1,
|
||||
point2 instanceof TrackPoint ? point2.getCoordinates() : point2,
|
||||
point3 instanceof TrackPoint ? point3.getCoordinates() : point3
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user