feat(costmap_2d): background reference graph, shared keys under root:
- ReferenceGraph / ReferenceGraphWorker: Voronoi ridges and one-way lanes are computed on a low-priority thread when the map changes (reference_graph_* keys, off with rolling_window), with unit tests. - Shared costmap keys can live in a root: map or flat at the top of the YAML; costmap_common_root_test covers both layouts. - Static and directional layers report map changes to the layered costmap.
This commit is contained in:
@@ -23,6 +23,7 @@ find_package(Boost REQUIRED COMPONENTS system thread filesystem)
|
||||
# still configure. The test block below requires it where it is actually used.
|
||||
find_package(GTest QUIET)
|
||||
find_package(yaml-cpp REQUIRED)
|
||||
find_package(Threads REQUIRED)
|
||||
# DepthCameraObstacleLayer only (voxel grid, kd-tree clearing, Euclidean clustering); the core
|
||||
# library and the other layers do not use PCL.
|
||||
find_package(PCL REQUIRED COMPONENTS common filters kdtree search segmentation)
|
||||
@@ -113,6 +114,8 @@ add_library(robot_costmap_2d SHARED
|
||||
src/layer.cpp
|
||||
src/layered_costmap.cpp
|
||||
src/direction_field.cpp
|
||||
src/reference_graph.cpp
|
||||
src/reference_graph_worker.cpp
|
||||
src/costmap_math.cpp
|
||||
src/footprint.cpp
|
||||
src/costmap_layer.cpp
|
||||
@@ -136,6 +139,7 @@ if(BUILDING_WITH_CATKIN)
|
||||
PRIVATE yaml-cpp
|
||||
PRIVATE dl
|
||||
PRIVATE ${TF3_LIBRARY}
|
||||
PUBLIC Threads::Threads
|
||||
)
|
||||
|
||||
else()
|
||||
@@ -157,6 +161,7 @@ else()
|
||||
yaml-cpp
|
||||
dl
|
||||
${TF3_LIBRARY}
|
||||
Threads::Threads
|
||||
)
|
||||
|
||||
set_target_properties(robot_costmap_2d PROPERTIES
|
||||
@@ -301,9 +306,18 @@ if(BUILD_COSTMAP_TESTS)
|
||||
find_package(Boost REQUIRED COMPONENTS system thread filesystem)
|
||||
find_library(TF3_LIBRARY NAMES tf3 PATHS /usr/lib /usr/local/lib /usr/lib/x86_64-linux-gnu)
|
||||
|
||||
add_executable(costmap_common_root_test test/costmap_common_root_test.cpp)
|
||||
target_link_libraries(costmap_common_root_test PRIVATE robot_costmap_2d GTest::GTest GTest::Main)
|
||||
|
||||
add_executable(direction_field_test test/direction_field_test.cpp)
|
||||
target_link_libraries(direction_field_test PRIVATE robot_costmap_2d GTest::GTest GTest::Main)
|
||||
|
||||
add_executable(reference_graph_test test/reference_graph_test.cpp)
|
||||
target_link_libraries(reference_graph_test PRIVATE robot_costmap_2d GTest::GTest GTest::Main)
|
||||
|
||||
add_executable(reference_graph_worker_test test/reference_graph_worker_test.cpp)
|
||||
target_link_libraries(reference_graph_worker_test PRIVATE robot_costmap_2d GTest::GTest GTest::Main Boost::thread)
|
||||
|
||||
add_executable(directional_layer_test test/directional_layer_test.cpp)
|
||||
target_link_libraries(directional_layer_test PRIVATE plugins robot_costmap_2d GTest::GTest GTest::Main Boost::thread ${TF3_LIBRARY})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user