I am trying to generate a disparity map from stereo images. These stereo images have quite a misalignment. There is a vertical and a horizontal shift.
I restify both images with rectifyStereoImages but it doesn't work:
[J1_BM, J2_BM] = rectifyStereoImages(img_left_2,img_right_2,stereoParams,'OutputView','valid');
The corresponding points in the images don't have the same row coordinates. They have a vertical shift and so the result is a noisy disparity map.
Can anyone suggest me how to correct this shift?