]> err.no Git - mapper/commitdiff
Add noaccess flag.
authorKaj-Michael Lang <milang@angel.tal.org>
Tue, 24 Jul 2007 20:35:43 +0000 (23:35 +0300)
committerKaj-Michael Lang <milang@angel.tal.org>
Tue, 24 Jul 2007 20:35:43 +0000 (23:35 +0300)
Add osm_location struct.
Start to add route waypoint structs

src/osm.h

index a3dc6bc6732d99d2d8049d9e3dc670cd229923a5..f661f001e581f45ba87d2b5f5c9b7aa2fbab4996 100644 (file)
--- a/src/osm.h
+++ b/src/osm.h
@@ -7,6 +7,7 @@
 #define W_LINK         (1 << 3)
 #define W_AREA         (1 << 4)
 #define W_NOEXIT       (1 << 5)
+#define W_NOACCESS     (1 << 6)
 
 #define ILAT_TURKU 911084432
 #define ILON_TURKU 265542144
@@ -105,6 +106,14 @@ typedef enum {
        WAY_OTHER
 } way_type_t;
 
+/* Route waypoint types */
+typedef enum {
+       WPT_START,
+       WPT_STOP,
+       WPT_END
+} waypoint_type_t;
+
+/* A place (city,town,village,suburb) */
 typedef struct _osm_place osm_place;
 struct _osm_place {
        guint32 id;
@@ -116,6 +125,15 @@ struct _osm_place {
        guint32 isin;
 };
 
+/* Way node */
+typedef struct _osm_way_node osm_way_node;
+struct _osm_way_node {
+       guint num;
+       gint lat;
+       gint lon;
+};
+
+/* Way */
 typedef struct _osm_way osm_way;
 struct _osm_way {
        guint32 id;
@@ -125,17 +143,28 @@ struct _osm_way {
        guint32 isin;
        guint node_num;
        gdouble dist;
+       gdouble distance;
        gchar *name;
        gchar *ref;
        gchar *int_ref;
+       osm_way_node *node_f;
+       osm_way_node *node_t;
+       gshort direction;
        GList *nodes;
 };
 
-typedef struct _osm_way_node osm_way_node;
-struct _osm_way_node {
-       guint num;
-       gint lat;
-       gint lon;
+/* Route waypoint */
+typedef struct _osm_waypoint osm_waypoint;
+struct _osm_waypoint {
+       osm_way *way;
+       waypoint_type_t type;
+};
+
+typedef struct _osm_location osm_location;
+struct _osm_location {
+       osm_way *street;
+       osm_place *primary;
+       osm_place *secondary;
 };
 
 #endif