Cropped rectified stereo images
Hello,
I'm using two RGB cameras. They are rotated, one clock-wise and the other counter clock-wise. I'm calibrating them with Ros Stereo Calibration node which is based on OpenCv. The output I get the camera matrix, projection matrix and R and T from cv::stereoCalibrate. The stereo_image_proc node outputs the rectified images that you can see below:
They seem rectified, they are both "facing" the right way but there is a HUGE area of only black pixels......why is that? Does it have to do with some parameter in cv::stereoRectify that I should change?
Thanks for the help.
I think your callibration is also doing some kind of resize... Have you used imageSize that is not the real one?
I'm using a ros node which has the calibration code embedded, but I looked into it and imageSize is not used....
I have just also checked that the rotation matrix R is correct, but the translation vector T is correct in the values but wrong in the magnitud. I know there is only a translation of 10cm in Y axis but T=[0, 0.01, 0] rather than T=[0, 0.1, 0].
After that fix, what is happening? what about magnitude?
What fix? I haven't changed any line of code.... I just checked that imageSize is not used and there is no "resizing" T either.....I still have my doubts about the uncalibrated images (raw ones, coming directly from the cameras) are flipped, one 90 degrees and the other one -90 degrees.....
what camera is it? PS I was talking about the T value
They are two UI-3241LE from IDS. I'm using the ueye_cam node to get the synchronized images.... About the T value, I measured the distance between the cameras with a ruler and checked the returned T value.....that's all I did. You don't think the problem comes from the cameras being rotated in opposite directions along the same axis (z)?
It may be the +90 and -90 that are because of the cameras rotations, but I do not think that is a big problem... I think that the problem may come from the displaying part... Aren't you using a big Mat and you display each of the images in 2 different that big Mat?
each rectified image is stored in a cv::Mat and in this case, individually published on a ros topic, that would be each "raw" cv::Mat returned from cv::stereoRectify
hm... I have no other idea for now....