// This is a piece of code for using in triangulation and
distance measurements for GPS style apps
// You make an array in real world apps to compare the
points. This is a single comparison between points.
// All values need to be set to the appropriate co-ordinates
// Pythagoras Theory allows you to get the radius
// Current/Central GPS Co-ordinates
var currentLocationLatitude;
var currentLocationLongitude;
// Get difference in latitude and longitude to the
current/Central GPS Co-ordinates
var locationNewLatitude = locationLatitude -
currentLocationLatitude;
var locationNewLongitude = locationLongitude -
currentLocationLongitude;
// Use Pythagoras for distance calculations
var Pythagoras = locationNewLongitude * locationNewLongitude
+ locationNewLatitude * locationNewLatitude;
var distance = Math.sqrt(Pythagoras);
Cheers
Levko Yaskewych
On Thu, Apr 21, 2011 at 7:48 PM, Andi <[email protected]> wrote:
> It will be grate if you can send me the code
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Maps API For Flash" 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-for-flash?hl=en.
>
--
You received this message because you are subscribed to the Google Groups
"Google Maps API For Flash" 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-for-flash?hl=en.