publishing image data as sensor_msgs
I am working on ubuntu platform and I have an ueye usb camera. Using ueye_api I have managed to write a .cpp program which captures a frame and stores it in a memory space allocated according to image size and bit depth. The program returns pointer to this memory space (say ppcImgMem) and it is of char type. ppcImgMem is a single array with ppcImgMem[0] corresponding to the pixel value of the first image pixel in unsigned format.
Now, I want to publish this image as sensor message (sensor_msgs) using image_transport. I have created a package which successfully does the same for frames captured by my webcam using gscam driver. But I do not have a driver for the ueye usb cam. I also tried to publish the array as a standard message and it is working but I think it would be better if I can publish it as sensor_msgs/Image form for further processing. Can somebody tell me how can I proceed from here onwards ?
-Abhinav