Copter: restore pv_get_horizontal_distance_cm function

This commit is contained in:
Randy Mackay 2014-06-02 18:03:02 +09:00
parent 82ed70b25e
commit b027c71491
1 changed files with 6 additions and 0 deletions

View File

@ -24,3 +24,9 @@ float pv_get_bearing_cd(const Vector3f &origin, const Vector3f &destination)
} }
return bearing; return bearing;
} }
// pv_get_horizontal_distance_cm - return distance between two positions in cm
float pv_get_horizontal_distance_cm(const Vector3f &origin, const Vector3f &destination)
{
return pythagorous2(destination.x-origin.x,destination.y-origin.y);
}