コード例 #1
0
ファイル: Flight.hpp プロジェクト: CnZoom/XcSoarWork
  /* Analyse flight */
  bool Analyse(const BrokenDateTime takeoff_time,
               const BrokenDateTime scoring_start_time,
               const BrokenDateTime scoring_end_time,
               const BrokenDateTime landing_time,
               ContestStatistics &olc_plus,
               ContestStatistics &dmst,
               PhaseList &phase_list,
               PhaseTotals &phase_totals,
               WindList &wind_list,
               const unsigned full = 512,
               const unsigned triangle = 1024,
               const unsigned sprint = 96,
               const unsigned max_iterations = 20e6,
               const unsigned max_tree_size = 5e6) {
    DebugReplay *replay = Replay();
    if (replay == nullptr) return false;

    ComputerSettings computer_settings;
    computer_settings.SetDefaults();

    AnalyseFlight(*replay, takeoff_time, scoring_start_time, scoring_end_time, landing_time,
                  olc_plus, dmst,
                  phase_list, phase_totals, wind_list, computer_settings,
                  full, triangle, sprint,
                  max_iterations, max_tree_size);
    delete replay;

    if (!qnh_available && computer_settings.pressure_available) {
      qnh = computer_settings.pressure;
      qnh_available = computer_settings.pressure_available;
    }

    return true;
  };
コード例 #2
0
ファイル: Flight.hpp プロジェクト: DRIZO/xcsoar
 /* Analyse flight */
 void Analyse(const BrokenDateTime takeoff_time,
              const BrokenDateTime release_time,
              const BrokenDateTime landing_time,
              ContestStatistics &olc_plus,
              ContestStatistics &dmst,
              PhaseList &phase_list,
              PhaseTotals &phase_totals,
              WindList &wind_list,
              const unsigned full = 512,
              const unsigned triangle = 1024,
              const unsigned sprint = 96,
              const unsigned max_iterations = 20e6,
              const unsigned max_tree_size = 5e6) {
   DebugReplay *replay = Replay();
   AnalyseFlight(*replay, takeoff_time, release_time, landing_time,
                 olc_plus, dmst,
                 phase_list, phase_totals, wind_list,
                 full, triangle, sprint,
                 max_iterations, max_tree_size);
   delete replay;
 };