Anybody??? Does anybody at least know how to determine a random distance along a polyline that may not relate to a vertex??
On Mar 23, 2:13 am, Doomsday <[email protected]> wrote: > So I have existing code that allows a user to plot a polyline. Now > what I would like to do is catch the mouse over the polyline event and > open a infowindow. > > All seems ok so far as I have seen that the API supports this event. > However in the infoWindow I'd like to show their distance along the > polyline relative to the start position of the polyline. So if the > polyline is 10kms long and they move the mouse over the polyline at > the halfway point then in the infoWindow it will show 5km, and as I > move my mouse along the polyline the infoWindow will also move > updating the mouses distance on the polyline from the start. > > Now I have been looking over the api and I don't really see a clear > cut way of doing this apart from some hack job. My main problem it > seems is that the position that the mouse is at on the polyline may > not have a vertex under it (ie the mouse is in the middle of a long > straight in the polyline between 2 points). Sure I could stop at the > vertex before or after the mouse position but accuracy is important. > > Is there anything in the api to help me with this that I am missing?? > > I would really appreciate some suggestions before I tackle this > problem. > > Thanks in advance > Joe --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Maps API" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/Google-Maps-API?hl=en -~----------~----~----~----~------~----~------~--~---
