Exemple #1
0
void
RoutePlanner::reset()
{
  origin_last = AFlatGeoPoint(0,0,0);
  destination_last = AFlatGeoPoint(0,0,0);
  dirty = true;
  solution_route.clear();
  m_planner.clear();
  m_unique.clear();
  h_min = (short)-1;
  h_max = 0;
  m_search_hull.clear();
  reach.reset();
}
AirspaceRoute::ClearingPair
AirspaceRoute::GetBackupPairs(const SearchPointVector& spv,
                              const RoutePoint &_start,
                              const RoutePoint &intc) const
{
  SearchPointVector::const_iterator start = spv.NearestIndexConvex(intc);
  ClearingPair p(intc, intc);

  SearchPointVector::const_iterator i_left = spv.NextCircular(start);
  p.first = AFlatGeoPoint(i_left->GetFlatLocation(), _start.altitude); // @todo alt!

  SearchPointVector::const_iterator i_right = spv.PreviousCircular(start);
  p.second = AFlatGeoPoint(i_right->GetFlatLocation(), _start.altitude); // @todo alt!

  return p;
}
Exemple #3
0
AirspaceRoute::ClearingPair
AirspaceRoute::get_backup_pairs(const SearchPointVector& spv,
                                const RoutePoint &_start,
                                const RoutePoint &intc) const
{
  SearchPointVector::const_iterator start = nearest_index_convex(spv, intc);
  ClearingPair p(intc, intc);

  SearchPointVector::const_iterator i_left = start;
  circular_next(i_left, spv);
  p.first = AFlatGeoPoint(i_left->get_flatLocation(), _start.altitude); // @todo alt!

  SearchPointVector::const_iterator i_right = start;
  circular_previous(i_right, spv);
  p.second = AFlatGeoPoint(i_right->get_flatLocation(), _start.altitude); // @todo alt!

  return p;
}