00001 #ifndef CAJUN_INTERP_RNDF_H
00002 #define CAJUN_INTERP_RNDF_H
00003
00004 #include "data_type.H"
00005 #include "base_interpolator.H"
00006 #include "rndf.H"
00007 #include <queue>
00008
00009 namespace cajun
00010 {
00011 void add_base_point ( rndf_t const *rndf_,
00012 base_interpolator_t::uniform_path_t &base_points_,
00013 rndf_t::waypoint_id_t const &start_id_,
00014 rndf_t::waypoint_id_t const &end_id_, double dis_);
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027 void interp_for_wp_pair (rndf_t const *rndf_,
00028 base_interpolator_t *interp_,
00029 rndf_t::waypoint_id_t const &start_id,
00030 rndf_t::waypoint_id_t const &end_id,
00031 rndf_lane_data_t &lane_data_);
00032
00033 void interp_from_wp (rndf_t const *rndf_,
00034 base_interpolator_t *interp_,
00035 std::vector<rndf_lane_data_t> &lane_list_,
00036 rndf_t::waypoint_id_t wp_id);
00037
00038 void interp_wp_from_zones (rndf_t const *rndf_,
00039 base_interpolator_t *interp_,
00040 std::vector<rndf_lane_data_t> &lane_list_,
00041 rndf_t::waypoint_id_t exit_wp_id);
00042
00043 void interp_all_wp_segments (rndf_t const *rndf_,
00044 base_interpolator_t *interp_,
00045 std::vector<rndf_lane_data_t> &lane_list_);
00046
00047
00048 void interp_intersection (rndf_t const *rnfd_,
00049 base_interpolator_t *interp_,
00050 rndf_t::waypoint_id_t const &start_id,
00051 rndf_t::waypoint_id_t const &end_id,
00052 rndf_lane_data_t &lane_data_);
00053
00054 void add_arc_points (rndf_lane_data_t &lane_data_,
00055 double bx, double by,
00056 double cx, double cy, double rad,
00057 double start_ang, double end_ang);
00058 void add_arc_points (std::deque<path_wp_t> &path_,
00059 double cx, double cy, double rad,
00060 double start_ang, double end_ang,
00061 double min_speed_, double max_speed_);
00062 void add_linear_points (rndf_lane_data_t &lane_data_,
00063 double bx, double by,
00064 double start_x, double start_y,
00065 double end_x, double end_y,
00066 base_interpolator_t *interp_);
00067 void add_linear_points (std::deque <path_wp_t> &path_,
00068 double start_x, double start_y,
00069 double end_x, double end_y,
00070 base_interpolator_t *interp_,
00071 double min_speed_, double max_speed_);
00072 double compute_radius (double p1x, double p1y, double ang_1,
00073 double p2x, double p2y, double ang_2);
00074 void compute_start_end_ang (double const start_tangent_,
00075 double const end_tangent_,
00076 double &start_ang_, double &end_ang_);
00077 void fill_initial_values (rndf_lane_data_t &lane_data_,
00078 rndf_t::waypoint_id_t const &start_id_,
00079 rndf_t::waypoint_id_t const &end_id_,
00080 double bx, double by);
00081
00082 void extended_intersection_points (
00083 rndf_t const *rndf_,
00084 rndf_t::waypoint_id_t const &start_id_,
00085 rndf_t::waypoint_id_t const &end_id_,
00086 double &sx, double &sy, double &ex, double &ey);
00087 };
00088
00089 #endif