geofence: remove unused function parameters

This commit is contained in:
bresch
2022-04-06 14:59:13 +02:00
committed by Mathieu Bresciani
parent 3f3a4ac5c1
commit e9a2b3f260
3 changed files with 3 additions and 6 deletions
+1 -2
View File
@@ -213,8 +213,7 @@ bool Geofence::checkAll(double lat, double lon, float altitude)
}
}
bool Geofence::check(const vehicle_global_position_s &global_position, const vehicle_gps_position_s &gps_position,
const home_position_s home_pos, bool home_position_set)
bool Geofence::check(const vehicle_global_position_s &global_position, const vehicle_gps_position_s &gps_position)
{
if (_param_gf_altmode.get() == Geofence::GF_ALT_MODE_WGS84) {
if (getSource() == Geofence::GF_SOURCE_GLOBALPOS) {
+1 -2
View File
@@ -88,8 +88,7 @@ public:
*
* @return true: system is obeying fence, false: system is violating fence
*/
bool check(const vehicle_global_position_s &global_position,
const vehicle_gps_position_s &gps_position, const home_position_s home_pos, bool home_position_set);
bool check(const vehicle_global_position_s &global_position, const vehicle_gps_position_s &gps_position);
/**
* Return whether a mission item obeys the geofence.
+1 -2
View File
@@ -1555,8 +1555,7 @@ bool Navigator::geofence_allows_position(const vehicle_global_position_s &pos)
(_geofence.getGeofenceAction() != geofence_result_s::GF_ACTION_WARN)) {
if (PX4_ISFINITE(pos.lat) && PX4_ISFINITE(pos.lon)) {
return _geofence.check(pos, _gps_pos, _home_pos,
home_position_valid());
return _geofence.check(pos, _gps_pos);
}
}