A flutter plugin that decodes encoded google polyline string into list of geo-coordinates suitable for showing route/polyline on maps
This package contains functions to decode google encoded polyline string which returns a list of co-ordinates indicating route between two geographical position
To use this package, add flutter_polyline_points as a dependency in your pubspec.yaml file.
Import the package
Get the list of points by Geo-coordinate
PolylinePoints polylinePoints = PolylinePoints(); List<PointLatLng> result = await polylinePoints.getRouteBetweenCoordinates(googleAPiKey, _originLatitude, _originLongitude, _destLatitude, _destLongitude); print(result);
Decode an encoded google polyline string e.g _p~iF~ps|U_ulLnnqC_mqNvxq`@
List<PointLatLng> result = decodePolyline("_p~iF~ps|U_ulLnnqC_mqNvxq`@"); print(result);
See the example directory for a complete sample app
- Foreign Function Interface for interoperability with the C programming language. [...]
- HTML elements and other resources for web-based applications that need to interact with the browser and the DOM (Document Object Model). [...]
- Utility methods to efficiently manipulate typed JSInterop objects in cases where the name to call is not known at runtime. You should only use these methods when the same effect cannot be achieved with @JS annotations. These methods would be extension methods on JSObject if Dart supported extension methods.