Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I'm looking at implementing a PHP based application, where by you have a certain route for example London to Edinburgh. Along this route, I want to calculate say a 10mi Radius or Polygon around the whole route/driving directions, check whether certain defined points/lat-lon's are within this radius. If so - Add them to the waypoint list, re-calculate the route and re-generate the driving directions.

I know there's various different API's for Google Maps, but I'm basically looking for some advice on which API's I should be looking through. I believe the phrase I'm looking for is 'Geofencing', and for that I've seen the Google Tracks API has methods incorporating that (https://developers.google.com/maps/documentation/tracks/geofences) - But I can't seem to work out how that would help me, or how I'd be able to use it.

Is it possible to do the lookup in an alternative method? For example, producing driving directions using 1 API call, storing all of the waypoints of this route in a MySQL DB and then using something along the lines of http://stackoverflow.com/questions/1078386/see-if-lat-long-falls-within-a-polygon-using-mysql? to see if each point is within the polygon/geofenced route?

share|improve this question
2  
Hello Christian and welcome. I've dropped the question in the GIS Stack Exchange chat room, to get a few more eyes on it. If you don't find a satisfactory answer here in a couple of days, it might make sense to migrate the question to GIS. –  Yannis Rizos Jan 16 '13 at 11:40
    
Thanks Yannis, appreciate it. –  christian.thomas Jan 16 '13 at 12:02

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.