Livox-SDK / livox_ros_driver

Livox device driver under ros, support Lidar Mid-40, Mid-70, Tele-15, Horizon, Avia.
Other
352 stars 201 forks source link

compile issue #141

Closed grdiv closed 1 year ago

grdiv commented 1 year ago

I compiled it in ubuntu20.04 with ros noetic, and with problem: /home/xxx/ws_livox/src/livox_ros_driver/livox_ros_driver/lddc.cpp:343:31: required from here /opt/ros/noetic/include/ros/message_traits.h:125:14: error: ‘const class std::shared_ptr<pcl::PointCloud >’ has no member named ‘getMD5Sum’ 125 | return m.getMD5Sum().c_str(); | ^~~~~ ...... /opt/ros/noetic/include/ros/message_traits.h:142:14: error: ‘const class std::shared_ptr<pcl::PointCloud >’ has no member named ‘getDataType’ 142 | return m.getDataType().c_str(); ...... /home/xxx/ws_livox/src/livox_ros_driver/livox_ros_driver/lddc.cpp:343:31: required from here /opt/ros/noetic/include/ros/serialization.h:144:14: error: ‘const class std::shared_ptr<pcl::PointCloud >’ has no member named ‘serializationLength’ 144 | return t.serializationLength(); ...... /home/xxx/ws_livox/src/livox_ros_driver/livox_ros_driver/lddc.cpp:343:31: required from here /opt/ros/noetic/include/ros/serialization.h:127:7: error: ‘const class std::shared_ptr<pcl::PointCloud >’ has no member named ‘serialize’ 127 | t.serialize(stream.getData(), 0); | ^~~


where in the file: https://github.com/Livox-SDK/livox_ros_driver/blob/880c46a91aaa602dbecf20e204da4751747b3826/livox_ros_driver/livox_ros_driver/lddc.cpp#L343 and https://github.com/Livox-SDK/livox_ros_driver/blob/880c46a91aaa602dbecf20e204da4751747b3826/livox_ros_driver/livox_ros_driver/lddc.cpp#L346 it seems that the Problem is the transfom betwen pcl::shared_ptr cloud and sensor_msg::PointCloud2? someone met the questiopn?

grdiv commented 1 year ago

https://github.com/Livox-SDK/livox_ros_driver/pull/110 has mentioned.