Add flag to allow skipping calling node function for nodes with no tags.

This commit is contained in:
Daniel Patterson
2017-06-12 23:46:29 +02:00
committed by Patrick Niklaus
parent 5c8e2b6f78
commit cd8fb82215
9 changed files with 41 additions and 3 deletions
+5
View File
@@ -15,6 +15,11 @@ properties.continue_straight_at_waypoint = false
properties.weight_name = 'duration'
--properties.weight_name = 'cyclability'
-- Set to true if you need to call the node_function for every node.
-- Generally can be left as false to avoid unnecessary Lua calls
-- (which slow down pre-processing).
properties.call_tagless_node_function = false
local default_speed = 15
local walking_speed = 6
+6
View File
@@ -20,6 +20,12 @@ properties.weight_name = 'routability'
-- For shortest distance without penalties for accessibility
--properties.weight_name = 'distance'
-- Set to true if you need to call the node_function for every node.
-- Generally can be left as false to avoid unnecessary Lua calls
-- (which slow down pre-processing).
properties.call_tagless_node_function = false
local profile = {
default_mode = mode.driving,
default_speed = 10,
+5
View File
@@ -14,6 +14,11 @@ properties.continue_straight_at_waypoint = false
properties.weight_name = 'duration'
--properties.weight_name = 'routability'
-- Set to true if you need to call the node_function for every node.
-- Generally can be left as false to avoid unnecessary Lua calls
-- (which slow down pre-processing).
properties.call_tagless_node_function = false
local walking_speed = 5
local profile = {
+5
View File
@@ -3,6 +3,11 @@ api_version = 1
properties.force_split_edges = true
-- Set to true if you need to call the node_function for every node.
-- Generally can be left as false to avoid unnecessary Lua calls
-- (which slow down pre-processing).
properties.call_tagless_node_function = false
-- Minimalist node_ and way_functions in order to test source_ and segment_functions
function node_function (node, result)
+5
View File
@@ -1,6 +1,11 @@
api_version = 1
-- Rasterbot profile
-- Set to true if you need to call the node_function for every node.
-- Generally can be left as false to avoid unnecessary Lua calls
-- (which slow down pre-processing).
properties.call_tagless_node_function = false
-- Minimalist node_ and way_functions in order to test source_ and segment_functions
function node_function (node, result)
+5
View File
@@ -22,6 +22,11 @@ properties.use_turn_restrictions = true
properties.max_speed_for_map_matching = 30/3.6 --km -> m/s
properties.weight_name = 'duration'
-- Set to true if you need to call the node_function for every node.
-- Generally can be left as false to avoid unnecessary Lua calls
-- (which slow down pre-processing).
properties.call_tagless_node_function = false
local uturn_penalty = 20
local traffic_light_penalty = 7 -- seconds