Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion AirLib/src/vehicles/multirotor/api/MultirotorApiBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -918,7 +918,7 @@ namespace airlib
//if auto mode requested for lookahead then calculate based on velocity
float command_period_dist = velocity * getCommandPeriod();
float lookahead = command_period_dist * (adaptive_lookahead > 0 ? min_factor : max_factor);
lookahead = std::max(lookahead, getDistanceAccuracy() * 1.5f); //50% more than distance accuracy
lookahead = (std::max)(lookahead, getDistanceAccuracy() * 1.5f); //50% more than distance accuracy (paren form: Windows min/max macros)
return lookahead;
}

Expand Down