AP_Math: move location_diff to Location and rename

This commit is contained in:
Pierre Kancir
2019-04-08 08:00:52 -07:00
committed by Tom Pittenger
parent 06ed4f032a
commit 00fa07ef33
4 changed files with 15 additions and 15 deletions
+1 -9
View File
@@ -75,15 +75,7 @@ float location_path_proportion(const struct Location &location,
/*
return the distance in meters in North/East plane as a N/E vector
from loc1 to loc2
*/
Vector2f location_diff(const struct Location &loc1, const struct Location &loc2)
{
return Vector2f((loc2.lat - loc1.lat) * LOCATION_SCALING_FACTOR,
(loc2.lng - loc1.lng) * LOCATION_SCALING_FACTOR * loc1.longitude_scale());
}
/*
return the distance in meters in North/East/Down plane as a N/E/D vector