Transform the coordinate system of the point cloud
flowchart LR
node([pointcloud_transformer])
topic__in["<a href="https://docs.ros2.org/foxy/api/sensor_msgs/msg/PointCloud2.html">sensor_msgs/msg/PointCloud2</a><br>~/in"]
topic__out["<a href="https://docs.ros2.org/foxy/api/sensor_msgs/msg/PointCloud2.html">sensor_msgs/msg/PointCloud2</a><br>~/out"]
topic__tf["/tf"]
param__frame_id[/"frame_id"/]
topic__in -- subscribe --> node -- publish --> topic__out
topic__tf -- listen --> node
param__frame_id -. Set .-> node -. Get .-> param__frame_id
cd (your ros2 workspace)/src
git clone https://github.com/shikishima-TasakiLab/pointcloud_transformer.git
cd ..
colcon build
source ./install/setup/bashros2 run pointcloud_transformer transformere.g.) Transform the point cloud data in "/in_pcd" into the "map" frame and publish it as "/out_pcd".
ros2 run pointcloud_transformer transformer --ros-args -r /in:=/in_pcd -r /out:=/out_pcd -p frame_id:=map