Ask Your Question

How to remap freenect_launch /camera/depth_registered/points?

asked 2018-06-20 12:34:37 -0500

tetamusha gravatar image

updated 2018-06-25 10:39:18 -0500

I have a package that listens for image data from a Kinect on /dodo_detector_ros/image_feed and for point cloud data on /dodo_detector_ros/pointcloud_feed. When I use the kinect2_bridge package with Kinect v2, I am able to remap topics from kinect2_bridge to the addresses my package listens to, like so.

<remap from="/kinect2/hd/image_color" to="/dodo_detector_ros/image_feed"/>
<remap from="/kinect2/hd/points" to="/dodo_detector_ros/pointcloud_feed"/>
<include file="$(find kinect2_bridge)/launch/kinect2_bridge.launch"/>

I am also able to remap a camera's image topic to the address my package listens to and it works (here I am ignoring the point cloud).

<remap from="/image_raw" to="/dodo_detector_ros/image_feed"/>
<node name="camera" output="screen" pkg="uvc_camera" type="uvc_camera_node" />

However, when I use freenect_launch with Kinect v1 and remap its topics like so, only the image topic is remapped. The remapped point cloud topic is created, but nothing is published on /dodo_detector_ros/pointcloud_feed.

<remap from="/camera/rgb/image_color" to="/dodo_detector_ros/image_feed"/>
<remap from="/camera/depth_registered/points" to="/dodo_detector_ros/pointcloud_feed"/>
<include file="$(find freenect_launch)/launch/examples/freenect-registered-xyzrgb.launch"/>

If I remove the remap commands from this last launch file and create subscribers that point directly to /camera/rgb/image_color and /camera/depth_registered/points, my package works fine. This is odd as it seems I am following the same pattern in all three launch files. Can someone help me?

edit retag flag offensive close merge delete


Can you create an answer and post your solution in there?

jayess gravatar image jayess  ( 2018-06-25 00:20:45 -0500 )edit

@jayess done.

tetamusha gravatar image tetamusha  ( 2018-06-25 10:39:56 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2018-06-25 10:39:44 -0500

tetamusha gravatar image

I discovered my problem was specifically in remapping the /camera/depth_registered/points topic, provided by the freenect_launch package and its freenect-registered-xyzrgb.launch launch file. While I was unable to remap this specific topic, I solved my problem by using another point cloud topic, like so:

<remap from="/camera/rgb/image_color" to="/dodo_detector_ros/image_feed"/>
<remap from="/camera/depth/points" to="/dodo_detector_ros/pointcloud_feed"/>
<include file="$(find freenect_launch)/launch/freenect.launch"/>

This one does not come with RGB data attached to the points, but I was able to work with it. Still, I'll leave the question here since I couldn't solve my original problem.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2018-06-20 12:34:37 -0500

Seen: 452 times

Last updated: Jun 25 '18