示例#1
0
void CensureDetector::GetKeypoints(std::vector<Keypoint>& v)
{
    for(int lv=0;lv<7;lv++)
    {
//        std::cout<<"lv="<<lv<<std::endl;
        int margin = extFilterSize[lv+1>6?6:lv+1]/2;
        for(int i=margin;i<bufy-margin;i++)
        {
//            std::cout<<"[";
            for(int j=margin;j<bufx-margin;j++)
            {
                filterResponse[lv][i*bufx+j] = CensureFilter(j,i,lv);
//                std::cout<<filterResponse[lv].at<float>(i,j)<<", ";
            }
//            std::cout<<"],"<<std::endl;
        }
//        FindMaximum(lv);
    }
    FindKeypoints(v);
}
示例#2
0
 Frame::Frame(const cv::Mat& img, const cv::Mat& K):
         isKeyframe(false), mK(K)
 {
     nThisId = nNextId++;
     FindKeypoints(img);
 }