Adds .properties file to osrm-extract ouput
This file contains global properties set by the lua profile, such as enabling uturns at vias and penalties. This file will be consumed by the server.
This commit is contained in:
@@ -288,6 +288,8 @@ void ExtractionContainers::PrepareEdges(lua_State *segment_state)
|
||||
const auto all_edges_list_end_ = all_edges_list.end();
|
||||
const auto all_nodes_list_end_ = all_nodes_list.end();
|
||||
|
||||
auto has_segment_function = util::lua_function_exists(segment_state, "segment_function");
|
||||
|
||||
while (edge_iterator != all_edges_list_end_ && node_iterator != all_nodes_list_end_)
|
||||
{
|
||||
// skip all invalid edges
|
||||
@@ -323,7 +325,7 @@ void ExtractionContainers::PrepareEdges(lua_State *segment_state)
|
||||
edge_iterator->source_coordinate,
|
||||
util::Coordinate(node_iterator->lon, node_iterator->lat));
|
||||
|
||||
if (util::lua_function_exists(segment_state, "segment_function"))
|
||||
if (has_segment_function)
|
||||
{
|
||||
luabind::call_function<void>(
|
||||
segment_state, "segment_function", boost::cref(edge_iterator->source_coordinate),
|
||||
|
||||
Reference in New Issue
Block a user