Is there a Matlab version of the OpenCV function initUndist​ortRectify​Map()?

10 ビュー (過去 30 日間)
Yuval Levental
Yuval Levental 2020 年 11 月 10 日
コメント済み: ft28 2022 年 6 月 15 日
I need the undistortion and rectification transformation maps for a project.

採用された回答

Yuval Levental
Yuval Levental 2020 年 11 月 15 日
Answering my own question. There isn't such a function, but finding the (x, y) bounds and Homography matrices from ComputeRectificationParams.m, then using the Homography and undistortion equations, then using interp2 to move forward gives accurate rectification. See https://www.mathworks.com/help///visionhdl/ug/stereoscopic-rectification.html for details.
  1 件のコメント
ft28
ft28 2022 年 6 月 15 日
Hi Yuval, I am also looking for the mapx and mapy calculation like in OpenCV cvInitUndistortRectifyMap().
How did you solve that with using homography matrix and x,y bounds?
I received these information by using paramStruct = toStruct(stereoParams) and get H1, H2, XBounds, YBounds, but dont have any idea how to proceed now. Do you have any code to share?
Thx
Fatih

サインインしてコメントする。

その他の回答 (1 件)

Debasish Samal
Debasish Samal 2020 年 11 月 13 日
Hi,
The rectifyStereoImages function returns undistorted and rectified versions of the input images using the stereo parameters. I think, this is what you are looking for. Please refer to the documentation of the same to know more about the function.
Thanks.
-Debasish
  1 件のコメント
Yuval Levental
Yuval Levental 2020 年 11 月 13 日
Hello, I know about this function, but I need something that specifically returns the x and y transformation maps.
For instance, the Undistortion block outputs coordinates (u,v) at https://www.mathworks.com/help///visionhdl/ug/stereoscopic-rectification.html
Is there a similar command in Matlab?

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeGeometric Transformation and Image Registration についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by