MATLAB Answers

question on triangulate() function

조회 수: 1(최근 30일)
Richard
Richard 6 Jan 2020
댓글: Rik 6 Jan 2020
The triangulate() function takes 2 sets of matched points.
" matchedPoints1 - Coordinates of points in image 1, specified as an M-by-2 matrix of M number of [x y] coordinates "....
are these in image coordinates (origin is top left, x is column?)
or plot coordinates
(origin is bottom left)...
seems like they should be plot coordinates, but the source is usually an image....
I have coordinates from another source in image (pixel) coordinates and just want to know if I need to flip them....
Thanks

  댓글 수: 2

darova
darova 6 Jan 2020
You didn't attach images neither data. What is the question?
Rik
Rik 6 Jan 2020
Comment posted as answer by Richard:
the question doesnt need data.
are the coordinates for the matched points like this
(0,0)--------------> X
|
|
|
Y
or
Y
^
|
|
|
(0,0)-------------> X

로그인 to comment.

답변(1개)

Rik
Rik 6 Jan 2020
I don't see any reason why it would matter (as long as you use the same coordinate system for both inputs and the stereoParameters object), but the images in the doc all suggest you should use the image convention (so the origin in the top-left instead of bottom-left).

  댓글 수: 2

Rik
Rik 6 Jan 2020
Comment posted as answer by Richard:
i think it does matter because im getting -z coordinates on my output ( which i hand created in 3D program Paraview) and carefully ray traced the projections ) when they should be +z.
X and Y are "correct" within error tolerance.Z is flipped.
Rik
Rik 6 Jan 2020
Please stop using the answer field to post comments.
Of course it will matter for the signs of your coordinates, but on a fundamental level for the function itself it shouldn't matter. The function should run independently of wether or not the input is realistic. Try to make a MWE so we can run your code without any other dependencies and can reproduce your issue. Because right now it is impossible to tell if your stereoParameters object matches the coordinate system of your points, which could also plausibly result in incorrect z values.

로그인 to comment.

이 질문에 답변하려면 로그인을(를) 수행하십시오.

제품


릴리스

R2019b

Translated by