ewoken / Leaflet.MovingMarker

A Leaflet plug-in to create moving marker
MIT License
341 stars 176 forks source link

Marker drifting off line when coords are across equator. #27

Open williamfalconeruk opened 7 years ago

williamfalconeruk commented 7 years ago

We have spotted an issue whereby if you place a moving marker to follow between 2 points on a polyline if one is in say "Paris", and the other end is in "Rio De Janeiro" the marker drifts off from the line to the right, then returns back to the line at the end.

Is there a way to fix this?

williamfalconeruk commented 7 years ago

Have found a solution to this - I have replaced the interpolation with one that mimics rhumb lines - see http://movable-type.co.uk/scripts/latlong.html

williamfalconeruk commented 7 years ago

Opening to create pull request

aakashbehal commented 6 years ago

@williamfalconeruk can you please send the pull request, need your solution. Thanks in advance.

Shivangi266 commented 6 years ago

Hi, Facing the same issue. Can you please let me know what is the solution? Thanks in advance.