#define FILE_BUFFER (128*1024)
-static guint node_cnt=0;
-static guint node_skip_cnt=0;
-static guint noded_cnt=0;
-static guint way_cnt=0;
-static guint way_names=0;
-static guint way_refs=0;
+static guint node_cnt=0; /* Nodes */
+static guint node_skip_cnt=0; /* Skipped nodes */
+static guint noded_cnt=0; /* Nodes with (usable) data */
+static guint way_cnt=0; /* Ways */
+static guint way_names=0; /* Ways with name */
+static guint way_refs=0; /* Ways with ref or int_ref */
static guint dbnode_cnt=0;
static guint dbnoded_cnt=0;
db_insert_node(n);
if (dbnode_cnt % 20000==0)
g_printf("\rNodes: %f%% (%u/%u)\n",
- ((float)dbnode_cnt/(float)node_cnt)*100,
+ ((float)dbnode_cnt/(float)(node_cnt-node_skip_cnt))*100,
dbnode_cnt, node_cnt);
}
return FALSE;
}
-
if (!osm_db_create(db)) {
g_printerr("Failed to create osm tables or indexes\n");
return FALSE;