laxnpander/OpenREALM

algorithm about SurfaceGeneration

tsingjinyun opened this issue · 2 comments

https://github.com/laxnpander/OpenREALM/blob/master/modules/realm_core/src/camera.cpp#L348
cv::Mat u = (cv::Mat_(3, 1) << img_bounds.at(i, 0), img_bounds.at(i, 1), 1.0);
double s = (pt - m_t).dot(n) / (m_R * m_K.inv() * u).dot(n);
cv::Mat p = m_R * (s * m_K.inv() * u) + m_t;
here code use algorithm,has any reference paper?

Hmm, not really and can't remember. The second line should be the algebraic form of line -> plane intersection:
https://en.wikipedia.org/wiki/Line%E2%80%93plane_intersection
The third line is a inverse pinhole projection:
https://towardsdatascience.com/inverse-projection-transformation-c866ccedef1c

thank you, and great project