HarborC / PL-SLAM

PL-SLAM: The method is implemented in《PL-SLAM:Real-time Monocular Visual SLAM with Points and Lines》
Other
223 stars 60 forks source link

CreateMapLines() #4

Closed LukyBird closed 3 years ago

LukyBird commented 4 years ago

// 保障不在同一对极平面上 //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// cv::Mat lineVector2 = (Mat_(2,1) << -keyline2_function(1), keyline2_function(0)); cv::Mat ray1Start = (Mat(3,1) << keyline1.startPointX, keyline1.startPointY, 1); cv::Mat ray1End = (Mat(3,1) << keyline1.endPointX, keyline1.endPointY, 1); cv::Mat R21 = Rcw2 Rwc1; cv::Mat t21 = Rcw2 ( Rwc2 tcw2 - Rwc1 tcw1 ); cv::Mat t21x = SkewSymmetricMatrix(t21); cv::Mat F21 = (K2.t()).inv() t21x R21 K1.inv(); cv::Mat Th1 = F21ray1Start; cv::Mat Th1 = (Mat(2,1) << -Th1.at(1, 0), Th1.at(0, 0)); float Result1 = Th1.dot(lineVector2) / (norm(Th1_) norm(lineVector2)); cv::Mat Th2 = F21ray1End; cv::Mat Th2 = (Mat(2,1) << -Th2.at(1, 0), Th2.at(0, 0)); float Result2 = Th2.dot(lineVector2) / (norm(Th2_) * norm(lineVector2));

            if(abs(Result1)>0.996 || abs(Result2)>0.996)
            {
                continue;
            }

这一段怎么理解

dzqiu commented 3 years ago

請問一下線特征沒有用pluker坐標嗎

HarborC commented 3 years ago

本代码中没不是使用pluker坐标