I have a PointGrey BlackFly USB3 2MP camera that reads as three 8-bit channels in Python's Numpy array of shape (rows, cols, 3). However, each cell (pixel) has the same value, so I end up with a gray-scale image-like by default. The size of the image is correct, though.
I tried several conversions of color, but Bayer cannot go from 3 channels to anything else. Does anyone know which property to set for this VideoCapture object or any other suggestion? I'm not sure which Video Data Output it's using, perhaps it's 24-bit digital data it's giving 24-bits per pixel as (8,8,8), but maybe not.
How to find out the video format within OpenCV? If I ask for
my_capture_device.get(cv2.CAP_PVAPI_PIXELFORMAT_RGB24)
it says 15.0,
my_capture_device.get(cv2.get(CAP_PVAPI_PIXELFORMAT_BAYER16)
, I get 480.0, and
my_capture_device.get(cv2.get(CAP_PVAPI_PIXELFORMAT_BAYER8)
I get 640.0.
Any other PIXELFORMAT
option gives -1.
I don't understand what these values mean. Please, help if you know how to set the color space for these PointGrey cameras. I know that OpenCV is wrapping around libdc1394
to interface the camera since PointGray doesn't provide drivers for OS X.
Thanks in advance!