00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #define WIN_WIDTH 1000
00019 #define WIN_HEIGHT 500
00020 #define EPSILON 1.0e-3
00021
00022 #define NO_POINT 0
00023 #define ONE_POINT 1
00024 #define MANY_POINTS 2
00025
00026 #define N_OBST 200
00027 #define N_ROBST 100
00028
00029 #define THICKNESS 3
00030 #define GENERATE_RANDOMLY 0
00031
00032 char my_screen[WIN_WIDTH][WIN_HEIGHT];
00033
00034 typedef struct {
00035 double x1;
00036 double y1;
00037 double x2;
00038 double y2;
00039 } my_obstacle;
00040
00041
00042 double my_distance_func(double[],double[]);
00043 int my_random_path(int,int,int,JMA_Configuration,JMA_Configuration*);
00044 int my_local_planner(double[],double[]);
00045 int my_ptp_collision(double[],double[]);
00046 int my_goal_func(double[]);
00047 int segments_intersection(double,double,double,double,double,double,
00048 double,double,double*,double*);
00049 int in_plane(double,double,double,double,double,double);
00050 int generate_path_planning_problem(int, my_obstacle[],JMA_Configuration*,double[]);
00051 void show_trajectory(JMA_Roadmap_Tree*,int[],int,double[]);
00052 double switch_random();
00053 void switch_srandom(int);