Beispiel #1
0
void 
AIRSPACE_ALT::set_flight_level(const AtmosphericPressure &press)
{
  static const fixed fl_feet_to_m(30.48);
  if (Base == abFL)
    Altitude = press.AltitudeToQNHAltitude(FL * fl_feet_to_m);
}
Beispiel #2
0
static bool
test_qnh_round()
{
  AtmosphericPressure pres;
  pres.FindQNH(fixed(100), fixed(120));
  fixed h0 = pres.AltitudeToQNHAltitude(fixed(100));
  if (verbose) {
    printf("%g\n",FIXED_DOUBLE(h0));
  }
  return fabs(h0-fixed(120))<fixed(1);
}