Getting shifted depth map from StereoSGBM

What I have done so far is calibrating these camera and extract a depth map from it.

There is a problem in the depth map. The correspondence points are shifted and I do not know why.

My code is not special at all and I tried many variations of stereo(gb)bm parameters.

StereoSGBM sgbm;
sgbm.numberOfDisparities = 5*16;
sgbm.SADWindowSize = 5;
// sgbm.disp.... and so on

remap(left, rleft, rmap[0][0], rmap[0][1], CV_INTER_LINEAR);
remap(right, rright, rmap[1][0], rmap[1][1], CV_INTER_LINEAR);

sgbm(rleft, rright, disparity);

I also thought that after stereoRectify the minimum disparity could be zero but I get better results (still worse) if I use negative values.

Here is the image (just one example): 在深度地图上移动

My input images (left, right, remapped left, remapped right): 左,右,重新映射左边,重新映射的权利

链接地址: http://www.djcxy.com/p/30626.html

上一篇: Kinect One使用OpenCV进行校准

下一篇: 从StereoSGBM获取移位的深度图