Stereo vision using only one camera - Rectification output is weird

3 ビュー (過去 30 日間)
Luca
Luca 2023 年 9 月 26 日
回答済み: Asim 2023 年 10 月 5 日
Hi
I'm doing a project based on a stereo vision system that works with only one camera: I take two photos with the same camera at different angles and use them as two photos taken from two different cameras. The setup looks like this:
The calibration is quite good: 0.5 px error (with 15 photos).
After the calibration I shot two photos using the template as "object" and I want to estimate its distance from the camera using my code (I located the template at 1000mm from the camera).
This is the photo at 0°:
and this is the one at 10°:
After that I use this code:
load stereoparams10.mat
left=imread("Foto/1000/0.png");
right=imread("Foto/1000/10.png");
figure
imshowpair(left,right,"montage")
[leftRect,rightRect,reprojectionMatrix]=rectifyStereoImages(left,right,stereoParams10,'output','full');
figure
A=stereoAnaglyph(leftRect,rightRect);
imtool(A)
using the 0° image as "left" and the 10° image as "right", and the image A looks like this:
Which is a problem because then I do the pointCloud using these rectified images and the it comes out inclinated as in photo.
Maybe is because the two cameras are pointing two different directions (and not the same direction as in the classic stereo vision)?
Or maybe because the baseline (distance between the two cameras) is equal to zero?
If so, do you know how can i fix that problem?
Thanks!

回答 (1 件)

Asim
Asim 2023 年 10 月 5 日
Hello @Luca,
I understand that the output you are getting is inclined, which is not the desired result. The issues you are seeing could be due to using single camera at different angles, effectively simulating a zero baseline and cameras pointing in different directions.
To rectify this:
I hope these suggestions helps in resolving the issue.
Best Regards,
Asim Asrar

カテゴリ

Help Center および File ExchangeComputer Vision Toolbox についてさらに検索

製品


リリース

R2023a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by