Hi All, I am unfamiliar with sending images from MATLAB to ROS. I am using MATLAB for the image processing algorithm then sending images back to ROS from the MATLAB master node. I am reading images from a rgbd PointCloud2 captured with my Intel RealSense camera. When I execute the readRGB and readXYZ commands they return MATLAB variables (image matricies) of data type double and single respectively. I am processing these and attemtping to send back to ROS. My first attempts have been sending via an RBG8 encoding by converting my processed matrices to data type uint8. This gave me a blank black image. However, when I read this image into MATLAB (getting a uint8 matrix) and convert to data type double I am able to see the image correctly. I have tried uint16 as well.
How should I be sending these images from MATLAB so that they are viewable in Rviz? I would like to send them as a double but I don't seem to see any way to do that.
Thank you for your help!!
Originally posted by cmfuhrman on ROS Answers with karma: 200 on 2018-05-17
Post score: 0