srl-freiburg / srl_global_planner

The SRL_GLOBAL_PLANNER package provides an implementation of the sampling based motion planners (RRT, RGG, RRT*, Theta*-RRT) as global planner plugin for Move-base, a ROS framework
BSD 3-Clause "New" or "Revised" License
123 stars 58 forks source link

No matching function for call to ‘costmap_2d::Costmap2DROS::getOrientedFootprint()’ #2

Closed Megacephalo closed 8 years ago

Megacephalo commented 8 years ago

Hi! When I tried to catkin_make the pkg, it simply pops up this error message every time. I tried moving"costmap_2d" file outside of the workspace, look into SMP to see if that's the source of the problem, creating a brand new workspace, but the problem persists. I already checked that I have

My colleague can successfully catkin_make the package, while I failed in both of my computers. What is the problem and how should I resolve it?

And the complete make and error message:

[  0%] [ 14%] Built target visualization_msgs_generate_messages_lisp
Built target SRLGLOBALPLANNER_KDTREE_LIB
[ 14%] [ 14%] [ 14%] [ 14%] [ 14%] [ 14%] Built target geometry_msgs_generate_messages_cpp
Built target costmap_2d_generate_messages_py
Built target visualization_msgs_generate_messages_py
Built target geometry_msgs_generate_messages_lisp
Built target geometry_msgs_generate_messages_py
Built target map_msgs_generate_messages_cpp
[ 14%] [ 14%] [ 14%] [ 14%] [ 14%] [ 14%] Built target map_msgs_generate_messages_lisp
Built target sensor_msgs_generate_messages_lisp
Built target roscpp_generate_messages_cpp
Built target tf_generate_messages_cpp
Built target actionlib_generate_messages_cpp
Built target tf_generate_messages_lisp
[ 14%] [ 14%] Built target actionlib_generate_messages_lisp
Built target actionlib_generate_messages_py
[ 14%] [ 14%] [ 14%] Built target rosgraph_msgs_generate_messages_cpp
Built target tf_generate_messages_py
Built target std_msgs_generate_messages_lisp
[ 14%] [ 14%] Built target actionlib_msgs_generate_messages_cpp
Built target std_msgs_generate_messages_cpp
[ 14%] [ 14%] [ 14%] Built target roscpp_generate_messages_py
Built target roscpp_generate_messages_lisp
Built target std_msgs_generate_messages_py
[ 14%] Built target costmap_2d_generate_messages_cpp
[ 14%] [ 14%] [ 14%] [ 14%] [ 14%] [ 14%] Built target dynamic_reconfigure_generate_messages_py
Built target dynamic_reconfigure_generate_messages_lisp
Built target sensor_msgs_generate_messages_py
Built target dynamic_reconfigure_generate_messages_cpp
[ 14%] Built target sensor_msgs_generate_messages_cpp
Built target rosgraph_msgs_generate_messages_lisp
Built target rosgraph_msgs_generate_messages_py
[ 14%] Built target tf2_msgs_generate_messages_cpp
[ 14%] [ 14%] [ 14%] [ 14%] [ 14%] Built target tf2_msgs_generate_messages_py
Built target costmap_2d_generate_messages_lisp
Built target actionlib_msgs_generate_messages_lisp
Built target dynamic_reconfigure_gencfg
Built target map_msgs_generate_messages_py
[ 14%] [ 14%] Built target nav_msgs_generate_messages_cpp
Built target actionlib_msgs_generate_messages_py
[ 14%] [ 14%] Built target nodelet_generate_messages_cpp
Built target costmap_2d_gencfg
[ 14%] [ 14%] [ 14%] [ 14%] Built target nodelet_generate_messages_lisp
Built target pcl_msgs_generate_messages_lisp
Built target tf2_msgs_generate_messages_lisp
Built target nav_msgs_generate_messages_lisp
[ 14%] [ 14%] Built target pcl_ros_gencfg
Built target nodelet_generate_messages_py
[ 14%] [ 14%] Built target visualization_msgs_generate_messages_cpp
Built target nav_msgs_generate_messages_py
[ 14%] Built target pcl_msgs_generate_messages_py
[ 14%] [ 14%] [ 14%] Built target bond_generate_messages_cpp
Built target bond_generate_messages_lisp
[ 14%] Built target bond_generate_messages_py
Built target topic_tools_generate_messages_py
[ 14%] [ 14%] [ 14%] Built target pcl_msgs_generate_messages_cpp
Built target topic_tools_generate_messages_cpp
Built target topic_tools_generate_messages_lisp
[ 28%] Building CXX object srl_global_planner/CMakeFiles/srl_global_planner.dir/src/srl_global_planner.cpp.o
In file included from /home/charly/indigo_ws2/src/srl_global_planner/include/srl_global_planner/srl_global_planner.h:75:0,
         from /home/charly/indigo_ws2/src/srl_global_planner/src/srl_global_planner.cpp:1:
/home/charly/indigo_ws2/src/srl_global_planner/include/smp/components/collision_checkers/collisionCostMap.hpp: In member function ‘int smp::collision_checker_costmap<typeparams, NUM_DIMENSIONS>::check_collision_state(smp::collision_checker_costmap<typeparams, NUM_DIMENSIONS>::state_t*)’:
/home/charly/indigo_ws2/src/srl_global_planner/include/smp/components/collision_checkers/collisionCostMap.hpp:155:82: error: no matching function for call to ‘costmap_2d::Costmap2DROS::getOrientedFootprint(double&, double&, double&, std::vector<geometry_msgs::Point_<std::allocator<void> > >&)’
     costmap_ros_->getOrientedFootprint(x_bot , y_bot , orient_bot, footprint_spec);
                                          ^
/home/charly/indigo_ws2/src/srl_global_planner/include/smp/components/collision_checkers/collisionCostMap.hpp:155:82: note: candidate is:
In file included from /home/charly/indigo_ws2/src/srl_global_planner/include/srl_global_planner/costmap_model.h:43:0,
         from /home/charly/indigo_ws2/src/srl_global_planner/include/srl_global_planner/thetastar_leading_rrt.h:4,
         from /home/charly/indigo_ws2/src/srl_global_planner/include/srl_global_planner/srl_global_planner.h:14,
         from /home/charly/indigo_ws2/src/srl_global_planner/src/srl_global_planner.cpp:1:
/opt/ros/indigo/include/costmap_2d/costmap_2d_ros.h:190:8: note: void costmap_2d::Costmap2DROS::getOrientedFootprint(std::vector<geometry_msgs::Point_<std::allocator<void> > >&) const
   void getOrientedFootprint(std::vector<geometry_msgs::Point>& oriented_footprint) const;
    ^
/opt/ros/indigo/include/costmap_2d/costmap_2d_ros.h:190:8: note:   candidate expects 1 argument, 4 provided
In file included from /home/charly/indigo_ws2/src/srl_global_planner/include/srl_global_planner/srl_global_planner.h:79:0,
         from /home/charly/indigo_ws2/src/srl_global_planner/src/srl_global_planner.cpp:1:
/home/charly/indigo_ws2/src/srl_global_planner/include/smp/components/multipurpose/minimum_time_reachability_thetastar.hpp: In member function ‘int smp::minimum_time_reachability<typeparams, NUM_DIMENSIONS>::getCostFromMap(double, double, double)’:
/home/charly/indigo_ws2/src/srl_global_planner/include/smp/components/multipurpose/minimum_time_reachability_thetastar.hpp:127:82: error: no matching function for call to ‘costmap_2d::Costmap2DROS::getOrientedFootprint(double&, double&, double&, std::vector<geometry_msgs::Point_<std::allocator<void> > >&)’
     costmap_ros_->getOrientedFootprint(x_bot , y_bot , orient_bot, footprint_spec);
                                          ^
/home/charly/indigo_ws2/src/srl_global_planner/include/smp/components/multipurpose/minimum_time_reachability_thetastar.hpp:127:82: note: candidate is:
In file included from /home/charly/indigo_ws2/src/srl_global_planner/include/srl_global_planner/costmap_model.h:43:0,
         from /home/charly/indigo_ws2/src/srl_global_planner/include/srl_global_planner/thetastar_leading_rrt.h:4,
         from /home/charly/indigo_ws2/src/srl_global_planner/include/srl_global_planner/srl_global_planner.h:14,
         from /home/charly/indigo_ws2/src/srl_global_planner/src/srl_global_planner.cpp:1:
/opt/ros/indigo/include/costmap_2d/costmap_2d_ros.h:190:8: note: void costmap_2d::Costmap2DROS::getOrientedFootprint(std::vector<geometry_msgs::Point_<std::allocator<void> > >&) const
   void getOrientedFootprint(std::vector<geometry_msgs::Point>& oriented_footprint) const;
    ^
/opt/ros/indigo/include/costmap_2d/costmap_2d_ros.h:190:8: note:   candidate expects 1 argument, 4 provided
make[2]: *** [srl_global_planner/CMakeFiles/srl_global_planner.dir/src/srl_global_planner.cpp.o] Error 1
make[1]: *** [srl_global_planner/CMakeFiles/srl_global_planner.dir/all] Error 2
make: *** [all] Error 2
Invoking "make -j8 -l8" failed

Thank you so much in advance !!

palmieri commented 8 years ago

Hi Megacephalo,

I have just updated a newer version of the planner. The error that you showed is related to a recent change in the Costmap_2D API.

You can fork or merge the new commits that I pushed on my repo.

Best,

L.

Megacephalo commented 8 years ago

Dear Luigi Palmieri,

Thank you for your help! I synchronized my branch with yours and it does not complain anymore on the linkage to costmap. However, there is another error that I cannot resolve on my own. The compiler cannot find where to import spencer_nav_msgs with the following error

-- +++ processing catkin package: 'srl_global_planner'
-- ==> add_subdirectory(srl_global_planner)
-- Compiling with maximum optimization, will only work on Core i7 processors! (-mavx -march=corei7-avx -msse4.2 -O3 -funroll-loops -fomit-frame-pointer -ftree-vectorize ...)
CMake Warning at srl_global_planner/CMakeLists.txt:18 (MESSAGE):
  Compiling with AVX off

-- Using these message generators: gencpp;genlisp;genpy
CMake Error at /opt/ros/indigo/share/catkin/cmake/catkinConfig.cmake:75 (find_package):
  Could not find a package configuration file provided by "spencer_nav_msgs"
  with any of the following names:

    spencer_nav_msgsConfig.cmake
    spencer_nav_msgs-config.cmake

  Add the installation prefix of "spencer_nav_msgs" to CMAKE_PREFIX_PATH or
  set "spencer_nav_msgs_DIR" to a directory containing one of the above
  files.  If "spencer_nav_msgs" provides a separate development package or
  SDK, be sure it has been installed.
Call Stack (most recent call first):
  srl_global_planner/CMakeLists.txt:29 (find_package)

-- Configuring incomplete, errors occurred!
See also "/home/iceira/indigo_ws/build/CMakeFiles/CMakeOutput.log".
See also "/home/iceira/indigo_ws/build/CMakeFiles/CMakeError.log".
make: *** [cmake_check_build_system] Error 1
Invoking "make cmake_check_build_system" failed

I have installed spencer_people_tracking before so I have the mesages

But even though I searched through SRL_RHCF_PLANNER, I could not find any definition of spencer_nav_msgs either, I guess it should be something like a "msg" folder with all the message files in it. Would you mind pointing me out a way to link the message? I totally appreciate your help and patience !! :)

palmieri commented 8 years ago

Please just comment line 29 of the CMakeLists.txt out, it should work.

Megacephalo commented 8 years ago

Thank you! That would do.

Cheers !