Skip to content

JacoNeto/location_on_path

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Dart implementation of the bdcc GeoDistanceAlgorithm. The algorithm calculates if a single coordinate is near a polyline path in a given radius. This can be used to detect when it is a good moment to recalculate a route in navigation.

Features

This package has the following method:

  • isLocationOnPathWithRadius(List<LatLng> polyline, LatLng point, int radius) returns true if the distance from point to polyline is at least radius meters, and false if it is not.

Usage

if (isLocationOnPathWithRadius(ppoints, currentPosition, 20)) {
    // continue
} else {
    // recalculates the route
}

About

Dart implementation of the bdccGeoDistanceAlgorithm

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages