Open lucasw opened 5 years ago
Look at non pcl dependent pointcloud2 conversions: https://github.com/ros2/rviz/blob/ros2/rviz_default_plugins/src/rviz_default_plugins/displays/pointcloud/transformers/xyz_pc_transformer.cpp for subscribing (findChannelindex https://github.com/ros2/rviz/blob/ros2/rviz_default_plugins/include/rviz_default_plugins/displays/pointcloud/point_cloud_helpers.hpp#L61) and https://github.com/ros2/turtlebot2_demo/blob/master/depthimage_to_pointcloud2/src/depthimage_to_pointcloud2_node.cpp for publishing.
pcl ros isn't available, but pcl conversions is?
Need to generate a test point cloud, look at it in rviz2 and verify it is the same in viz3d.
https://answers.ros.org/question/312587/generate-and-publish-pointcloud2-in-ros2/
https://github.com/ros2/pcl_conversions/issues/3 "toROSMsg builds and links fine with only pcl_conversions linked in, but fromROSMsg needs pcl::console::print"
Next could add accumulation mode, just have a bunch of shapes but don't really want to see all of this in the shapes area of the viz3d window.
Also want the colors of the points to be emission by default- this will be a change to the shaders, and new uniform to control it- or just add emission textures that every surface can have?
Subscribe to pointcloud2 topic and then display the received points.
Standard options for only showing latest, for accumulating with a certain number of message, points, or time limit.