33fcdb581aaf07cd7a871453a9284f1b8d29b5cb
[navit-package] / src / route.h
1 #include "types.h"
2
3 struct route_path_segment {
4         struct route_path_segment *next;
5         int country;
6         s32 segid;
7         int offset;
8         int dir;
9         int time;
10         int length;
11         struct coord c[2];
12 };
13
14 struct route_crossing {
15         s32 segid;
16         int dir;
17 };
18
19 struct route_crossings {
20         int count;
21         struct route_crossing crossing[0];
22 };
23
24 struct route;
25 struct map_data;
26 struct container;
27 struct route_info;
28
29 struct route *route_new(void);
30 int route_destroy(void *t);
31 void route_mapdata_set(struct route *this, struct map_data *mdata);
32 struct map_data* route_mapdata_get(struct route *this);
33 void route_display_points(struct route *this, struct container *co);
34 void route_click(struct route *this, struct container *co, int x, int y);
35 void route_start(struct route *this, struct container *co);
36 void route_set_position(struct route *this, struct coord *pos);
37 void route_set_destination(struct route *this, struct coord *dst);
38 struct coord *route_get_destination(struct route *this);
39 struct route_path_segment *route_path_get(struct route *, s32 segid);
40 struct route_path_segment *route_path_get_all(struct route *this);
41 void route_trace(struct container *co);
42 struct street_str *route_info_get_street(struct route_info *rt);
43 struct block_info *route_info_get_block(struct route_info *rt);
44 struct route_info *route_find_nearest_street(struct map_data *mdata, struct coord *c);
45 void route_find_point_on_street(struct route_info *rt_inf);
46 void route_do_start(struct route *this, struct route_info *rt_start, struct route_info *rt_end);
47 int route_find(struct route *this, struct route_info *rt_start, struct route_info *rt_end);
48 struct tm *route_get_eta(struct route *this);
49 double route_get_len(struct route *this);
50 struct route_crossings *route_crossings_get(struct route *this, struct coord *c);
51