From: mfranz Date: Sat, 31 Mar 2007 15:17:55 +0000 (+0000) Subject: use round() from SG, as this isn't available everywhere X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=b395c12fdb68662638bc638d339fb8fcbbaee778;p=flightgear.git use round() from SG, as this isn't available everywhere --- diff --git a/src/Instrumentation/altimeter.cxx b/src/Instrumentation/altimeter.cxx index 56516da2c..f5d6229d5 100644 --- a/src/Instrumentation/altimeter.cxx +++ b/src/Instrumentation/altimeter.cxx @@ -16,6 +16,7 @@ // Note non-default name, quantum, and tau values. #include +#include #include
#include
@@ -63,7 +64,7 @@ Altimeter::update (double dt) double press_alt = _press_alt_node->getDoubleValue(); // The mechanism settles slowly toward new pressure altitude: raw_PA = fgGetLowPass(raw_PA, _altimeter.press_alt_ft(pressure), trat); - _mode_c_node->setDoubleValue(100 * round(raw_PA/100)); + _mode_c_node->setDoubleValue(100 * SGMiscd::round(raw_PA/100)); _kollsman = fgGetLowPass(_kollsman, _altimeter.kollsman_ft(setting), trat); if (_quantum) press_alt = _quantum*round(raw_PA/_quantum);