Posted by
valerylo on
URL: http://official-rtab-map-forum.206.s1.nabble.com/Static-multi-rgbd-camera-mapping-with-gazebo-tp6454.html
Hello,
I am working on a simulation using static rgbd camera. My goal is to use these camera to generate a global costmap for a mobile robot. I followed the exemples I found and have a kind of result, but it does not match reallity. I guess I have a TF issue somewhere but I can not find it.
I work on ROS melodic.
Here is the node graphe I get:

Here is the tf tree

Here is the result I get in RVIZ. The costmap does not correspond to the 2 pointclouds (in color)

Here is the launch file I use for RTABmap:
<launch>
<arg name="localization" default="false"/>
<arg if="$(arg localization)" name="args" default=""/>
<arg unless="$(arg localization)" name="args" default="--delete_db_on_start"/>
<arg name="odom_topic" default="/odom" />
<arg name="wait_for_transform" default="true" />
<group ns="camera1">
<node pkg="nodelet" type="nodelet" name="camera1_nodelet_manager" args="manager"
output="screen" launch-prefix="">
</node>
<node pkg="nodelet" type="nodelet" name="rgbd_sync" args="load rtabmap_ros/rgbd_sync camera1_nodelet_manager">
<remap from="rgb/image" to="/fixed_camera_1/color/image_raw"/>
<remap from="depth/image" to="/fixed_camera_1/depth/image_raw"/>
<remap from="rgb/camera_info" to="/fixed_camera_1/color/camera_info"/>
</node>
</group>
<group ns="camera2">
<node pkg="nodelet" type="nodelet" name="camera2_nodelet_manager" args="manager"
output="screen" launch-prefix="">
</node>
<node pkg="nodelet" type="nodelet" name="rgbd_sync" args="load rtabmap_ros/rgbd_sync camera2_nodelet_manager">
<remap from="rgb/image" to="/fixed_camera_2/color/image_raw"/>
<remap from="depth/image" to="/fixed_camera_2/depth/image_raw"/>
<remap from="rgb/camera_info" to="/fixed_camera_2/color/camera_info"/>
</node>
</group>
<group ns="rtabmap">
<node name="rtabmap" pkg="rtabmap_ros" type="rtabmap" output="screen" args="$(arg args)">
<rosparam command="load" file="$(find global_local_map_validation)/params/rtabmap_static_cam.yaml" />
<remap from="rgbd_image0" to="/camera1/rgbd_image"/>
<remap from="rgbd_image1" to="/camera2/rgbd_image"/>
<remap from="grid_map" to="map" />
<remap from="odom" to="$(arg odom_topic)"/>
</node>
</group>
</launch>