Hello,
On which step are you filtering the dynamic objects? If you are detecting dynamic obstacles using the depth images of the kinect, you could put your node to filter the depth image input of rtabmap by setting depth pixels of the dynamic object to 0. In that way, when new node are added to the map, the dynamic depth pixels won't be shown. Example:
/camera/rgb/image_color_rect -------------------------------------------------------------------------------
\
/camera/rgb/camera_info --------------------------------------------------------------------------------- \
\ \
/camera/depth_registered/image_raw ---> [my_dynamic_objects_removal_node] ---> /depth_filtered ----> [rtabmap_node]
In the code, you could modify the input of:
-Standalone:
rtabmap::process()-ROS:
CoreWrapper::process()Note: I recommend to use an external node approach instead of modifying the functions above, the code interface has changed slightly in devel branch.
cheers