[ros-users] Rivz Display

#TAN ZHI PING# TANZ0066 at e.ntu.edu.sg
Wed Sep 8 07:59:46 UTC 2010


Hi all,

I tried to run this program in rivz.

------------------------------- _Start_Program_---------------------------------
        sensor_msgs::PointCloud cloud;
        cloud.header.stamp = ros::Time::now();
        cloud.header.frame_id = "sensor_frame";
        cloud.set_point_size(NUM_POINT);

        //we'll also add an intensity channel to the cloud
        cloud.set_channels_size(1);
        cloud.channels[0].name = "intensities";
        cloud.channels[0].set_values_size(NUM_POINT);

        for(unsigned int i =0; i<num_points; ++i){
            cloud.points[i].x = 1 + count;
            cloud.points[i].y = 2 + count;
            cloud.points[i].z = 3 + count;
            cloud.channels[0].values[i] = 10

        cloud_pub.publish(cloud);
        ++count;
-------------------------------------_End_program_-----------------------------------------------

Although there is display on the RIVZ, the old data is always removed by the new data. What is the setting required to retain the data?

With thanks,
Zhiping

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osuosl.org/pipermail/ros-users/attachments/20100908/ca76971d/attachment-0002.html>


More information about the ros-users mailing list