What are the difference between rgb and greyscale images in the image msg Data vector?
Hi everyone,
I'm trying to convert with another program the ROS image msg to an OpenCV matrix. The image source is a multi camera plugin in Gazebo: "libgazeborosmulticamera.so". I've been able to convert correctly a RGB (R8G8B8 image format) image with size 640x480, in this case I get a value of 921600 image msg Data length . However, if I switch to GREYSCALE (L8 image format) keeping the same dimensions I get the same value of 921600 image msg Data length and a wrong conversion. Can someone please help me in understanding why the Data vector size is the same? What are the differences between a RBG image and a Greyscale image in the Data vector?
Thanks in advance.
Asked by Mondo on 2018-02-22 05:16:33 UTC
Comments