Solve the DLT system for the homogeneous point (smallest eigenvector of A).
| 149 | |
| 150 | // Solve the DLT system for the homogeneous point (smallest eigenvector of A). |
| 151 | inline bool SolveTriangulationDlt(const Eigen::Matrix4d& A, |
| 152 | Eigen::Vector3d* xyz) { |
| 153 | const Eigen::SelfAdjointEigenSolver<Eigen::Matrix4d> eigen_solver(A); |
| 154 | if (eigen_solver.info() != Eigen::Success || |
| 155 | eigen_solver.eigenvectors()(3, 0) == 0) { |
| 156 | return false; |
| 157 | } |
| 158 | *xyz = eigen_solver.eigenvectors().col(0).hnormalized(); |
| 159 | return true; |
| 160 | } |
| 161 | |
| 162 | } // namespace |
| 163 |
no outgoing calls
no test coverage detected