ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

sensor_msgs::PointCloud2 not displaying in rviz

asked 2013-12-20 05:10:26 -0600

bvbdort gravatar image

updated 2013-12-20 07:35:33 -0600

hi,

I am new to ROS. I have read binary files of laser dataset and prepared sensor_msgs::PointCloud2 messages. But when i tried to view them in rviz, it not showing anything. Here is one of the pointcloud message from rostopic echo. I would like to know what is the problem.

--thanks

header: 
  seq: 107
  stamp: 
    secs: 0
    nsecs: 0
  frame_id: laser_link
height: 1
width: 98322
fields: 
  - 
    name: x
    offset: 0
    datatype: 7
    count: 1
  - 
    name: y
    offset: 4
    datatype: 7
    count: 1
  - 
    name: z
    offset: 8
    datatype: 7
    count: 1
  - 
    name: r
    offset: 12
    datatype: 7
    count: 1
is_bigendian: False
point_step: 16
row_step: 1573152
Data : [201, 186, 100, .........<largedata> ..................]
is_dense: True
---
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2013-12-22 03:17:00 -0600

demmeln gravatar image

In the pointcloud display in rviz under "Status", do you see that the one message arrived in rviz?

What is your 'Fixed Frame' (Global Options in rviz)? Set it to 'laser_link', or make sure there is a tf transform from the fixed frame to laser_link.

I'm not sure how exactly rviz handles timestamps, maybe the 0 timestamp of the message is an issue (but I guess it should still display).

edit flag offensive delete link more

Comments

@demmeln /map is my fixed frame and i am publishing /map to /odom tf and have static tf for /base to /odom and /base to /laser. its not showing number of messages recieved.

bvbdort gravatar image bvbdort  ( 2013-12-22 03:34:11 -0600 )edit
1

@bvbdort the point cloud's frame is /laser_link according to the message, but your tf tree does not seem to have it ... name mismatch? Also, if your fixed frame is /map, the point cloud message time stamp will need to match with that of the tf broadcasters. Is the point cloud visible when you set the fixed frame to laser_link?

VC gravatar image VC  ( 2013-12-22 04:57:17 -0600 )edit

@VC yes i mean /laser is /laser_link

bvbdort gravatar image bvbdort  ( 2013-12-22 05:06:07 -0600 )edit

@demmeln its not showing number of messages recieved

bvbdort gravatar image bvbdort  ( 2014-01-06 22:27:20 -0600 )edit

Hmmm... Can you check for errors with roswtf and then check if the publishing node and rviz are connected in rqt_graph?

demmeln gravatar image demmeln  ( 2014-01-07 10:21:26 -0600 )edit

@demmeln In rqt_graph its not showing anything related to rviz. No errors in roswtf.

bvbdort gravatar image bvbdort  ( 2014-01-07 22:36:30 -0600 )edit

Sorry for the late reply. Have you set your fixed frame to laser_link? Are you publishing the message repeatedly, or just once? The number of messages received should show up if you open the "Status" entry in rviz. In rqt_graph untick "Hide Debug" to see rviz.

demmeln gravatar image demmeln  ( 2014-01-20 04:15:46 -0600 )edit

the problem is with data of pointcloud. When reading pointcloud data properly its working fine.

bvbdort gravatar image bvbdort  ( 2014-01-20 21:45:25 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2013-12-20 05:10:26 -0600

Seen: 4,414 times

Last updated: Dec 22 '13