30 #ifndef NAVIT_ROUTE_PROTECTED_H
31 #define NAVIT_ROUTE_PROTECTED_H
38 #define RP_TRAFFIC_DISTORTION 1
39 #define RP_TURN_RESTRICTION 2
40 #define RP_TURN_RESTRICTION_RESOLVED 4
42 #define RSD_MAXSPEED(x) *((int *)route_segment_data_field_pos((x), attr_maxspeed))
157 #define HASH_SIZE 8192
attr_type
Definition: attr.h:34
char data
Definition: garmin_img.c:2
char type[3]
Definition: garmin_img.c:2
#define HASH_SIZE
Definition: route_protected.h:157
int route_graph_segment_is_duplicate(struct route_graph_point *start, struct route_graph_segment_data *data)
Checks if the route graph already contains a particular segment.
Definition: route.c:1589
struct route_graph_point * route_graph_add_point(struct route_graph *this, struct coord *f)
Inserts a point into the route graph at the specified coordinates.
Definition: route.c:1413
void route_recalculate_partial(struct route *this_)
Triggers partial recalculation of the route, based on the existing route graph.
Definition: route.c:2723
void route_remove_traffic_distortion(struct route *this_, struct item *item)
Removes a traffic distortion item from the route.
Definition: route.c:4204
void route_free_selection(struct map_selection *sel)
Destroys a list of map selections.
Definition: route.c:1077
void route_change_traffic_distortion(struct route *this_, struct item *item)
Changes a traffic distortion item on the route.
Definition: route.c:4134
struct route_graph_point * route_graph_get_point(struct route_graph *this, struct coord *c)
Gets the first route_graph_point with the specified coordinates.
Definition: route.c:1351
void route_graph_add_segment(struct route_graph *this, struct route_graph_point *start, struct route_graph_point *end, struct route_graph_segment_data *data)
Inserts a new segment into the route graph.
Definition: route.c:1614
void route_graph_free_segments(struct route_graph *this)
Destroys all segments of a route graph.
Definition: route.c:1867
void * route_segment_data_field_pos(struct route_segment_data *seg, enum attr_type type)
Returns the position of a certain field appended to a route graph segment.
Definition: route.c:1532
struct route_graph_point * route_graph_get_point_next(struct route_graph *this, struct coord *c, struct route_graph_point *last)
Gets the next route_graph_point with the specified coordinates.
Definition: route.c:1327
void route_graph_add_turn_restriction(struct route_graph *this, struct item *item)
Adds a turn restriction item to the route graph.
Definition: route.c:2480
void route_add_traffic_distortion(struct route *this_, struct item *item)
Adds a traffic distortion item to the route.
Definition: route.c:4121
struct route_graph * route_get_graph(struct route *this_)
Retrieves the route graph.
Definition: route.c:4183
struct map_selection * route_get_selection(struct route *this_)
Retrieves the map selection for the route.
Definition: route.c:1056
void route_graph_build_done(struct route_graph *rg, int cancel)
Releases all resources needed to build the route graph.
Definition: route.c:3140
void route_graph_free_points(struct route_graph *this)
Frees all the memory used for points in the route graph passed.
Definition: route.c:1427
Definition: callback.c:27
Definition: event_glib.c:115
Represents an object on a map.
Definition: item.h:115
Used to select data from a map.
Definition: map.h:58
Handle for a mapset in use.
Definition: mapset.c:150
A point in the route graph.
Definition: route_protected.h:50
struct route_graph_point * hash_next
Definition: route_protected.h:51
struct route_graph_segment * seg
Definition: route_protected.h:56
struct route_graph_segment * start
Definition: route_protected.h:52
struct route_graph_segment * end
Definition: route_protected.h:54
int rhs
Definition: route_protected.h:63
int value
Definition: route_protected.h:60
struct coord c
Definition: route_protected.h:69
int flags
Definition: route_protected.h:70
int dst_val
Definition: route_protected.h:65
struct route_graph_segment * dst_seg
Definition: route_protected.h:67
struct fibheap_el * el
Definition: route_protected.h:58
Data for a segment in the route graph.
Definition: route_protected.h:105
int flags
Definition: route_protected.h:110
int score
Definition: route_protected.h:116
int len
Definition: route_protected.h:111
struct size_weight_limit size_weight
Definition: route_protected.h:114
int maxspeed
Definition: route_protected.h:112
int dangerous_goods
Definition: route_protected.h:115
struct item * item
Definition: route_protected.h:106
int offset
Definition: route_protected.h:107
A segment in the route graph.
Definition: route_protected.h:125
struct route_graph_point * start
Definition: route_protected.h:131
struct route_graph_point * end
Definition: route_protected.h:132
struct route_graph_segment * start_next
Definition: route_protected.h:127
struct route_graph_segment * next
Definition: route_protected.h:126
struct route_graph_segment * end_next
Definition: route_protected.h:129
struct route_segment_data data
Definition: route_protected.h:133
A complete route graph.
Definition: route_protected.h:142
struct fibheap * heap
Definition: route_protected.h:156
struct vehicleprofile * vehicleprofile
Definition: route_protected.h:150
struct map_rect * mr
Definition: route_protected.h:149
struct route_graph_segment * avoid_seg
Definition: route_protected.h:155
struct callback * idle_cb
Definition: route_protected.h:151
struct route_graph_point * hash[HASH_SIZE]
Definition: route_protected.h:158
struct map_selection * sel
Definition: route_protected.h:146
struct callback * done_cb
Definition: route_protected.h:152
struct map * m
Definition: route_protected.h:148
struct route_graph_segment * route_segments
Definition: route_protected.h:154
struct event_idle * idle_ev
Definition: route_protected.h:153
int busy
Definition: route_protected.h:143
struct mapset_handle * h
Definition: route_protected.h:147
A segment in the route graph or path.
Definition: route_protected.h:78
int flags
Definition: route_protected.h:80
int len
Definition: route_protected.h:81
int score
Definition: route_protected.h:82
A complete route.
Definition: route.c:201
Size and weight limits for a route segment.
Definition: route_protected.h:94
int width
Definition: route_protected.h:95
int axle_weight
Definition: route_protected.h:99
int height
Definition: route_protected.h:97
int length
Definition: route_protected.h:96
int weight
Definition: route_protected.h:98
Definition: vehicleprofile.h:33