Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

confusion about the projection matrix used #2

Closed
ChemJeff opened this issue Oct 7, 2020 · 2 comments
Closed

confusion about the projection matrix used #2

ChemJeff opened this issue Oct 7, 2020 · 2 comments
Assignees
Labels
question Further information is requested

Comments

@ChemJeff
Copy link

ChemJeff commented Oct 7, 2020

Hi Max,
Can you further explain your code for perspective unproject matrix? It confuses me for a while since it's not seems like in form of some standard projection matrix. Especially the following line:

at(2, 3) = (2 * near * far) / (near - far);

Thanks!

@themasterlink
Copy link
Contributor

I sadly do not remember exactly where I got this equation from, but it is also used in this tutorial:

http://www.songho.ca/opengl/gl_projectionmatrix.html

More precise in this picture:

Be aware that I flipped near and far value, which is the reason why there is no minus in front of it.

But I am sure there would be other solutions to this problem. But I am no expert on intrinsic camera calibration and the forms it can take.

@themasterlink themasterlink self-assigned this Oct 7, 2020
@themasterlink themasterlink added the question Further information is requested label Oct 7, 2020
@ChemJeff
Copy link
Author

ChemJeff commented Oct 7, 2020

Thanks, that helps me a lot.

@ChemJeff ChemJeff closed this as completed Oct 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants