bug in pcl_ros/src/transforms.cpp?

asked 2019-05-24 23:50:57 -0500

johnblack gravatar image

updated 2019-05-25 02:51:41 -0500

gvdhoorn gravatar image

straight dump of the error message:

/home/riki/catkin_ws/src/john/perception_pcl-melodic-devel/pcl_ros/src/transforms.cpp: In function ‘void pcl_ros::transformAsMatrix(const Transform&, Eigen::Matrix4f&)’:
/home/riki/catkin_ws/src/john/perception_pcl-melodic-devel/pcl_ros/src/transforms.cpp:287:37: error: invalid initialization of reference of type ‘const TransformStamped& {aka const geometry_msgs::TransformStamped_<std::allocator<void> >&}’ from expression of type ‘const Transform {aka const geometry_msgs::Transform_<std::allocator<void> >}’
   out_mat = tf2::transformToEigen(bt).matrix().cast<void>();
                                     ^
In file included from /home/riki/catkin_ws/src/john/perception_pcl-melodic-devel/pcl_ros/src/transforms.cpp:38:0:
/opt/ros/kinetic/include/tf2_eigen/tf2_eigen.h:46:17: note: in passing argument 1 of ‘Eigen::Affine3d tf2::transformToEigen(const TransformStamped&)’
 Eigen::Affine3d transformToEigen(const geometry_msgs::TransformStamped& t) {
                 ^
/home/riki/catkin_ws/src/john/perception_pcl-melodic-devel/pcl_ros/src/transforms.cpp:287:53: error: expected primary-expression before ‘void’
   out_mat = tf2::transformToEigen(bt).matrix().cast<void>();
                                                     ^
CMakeFiles/pcl_ros_tf.dir/build.make:62: recipe for target 'CMakeFiles/pcl_ros_tf.dir/src/transforms.cpp.o' failed
make[2]: *** [CMakeFiles/pcl_ros_tf.dir/src/transforms.cpp.o] Error 1
CMakeFiles/Makefile2:781: recipe for target 'CMakeFiles/pcl_ros_tf.dir/all' failed
make[1]: *** [CMakeFiles/pcl_ros_tf.dir/all] Error 2
Makefile:138: recipe for target 'all' failed
make: *** [all] Error 2
edit retag flag offensive close merge delete

Comments

1

Please edit your question to provide information to reproduce your workspace especially the versions of the code that you are using. http://wiki.ros.org/Support

tfoote gravatar image tfoote  ( 2019-05-25 02:58:57 -0500 )edit
1

Without seeing a minimal example which causes this error there's not much we can do to help.

However the error message appears to be saying that a Transform is being passed instead of a TransformStamped.

PeteBlackerThe3rd gravatar image PeteBlackerThe3rd  ( 2019-05-25 09:35:30 -0500 )edit