Ask Your Question
1

FREAK selectPairs Error

asked 2012-12-27 04:17:54 -0600

aliciadominica gravatar image

updated 2012-12-27 04:19:23 -0600

Hello, since I'm not happy with the results achieved via FREAK, I decided to use FREAK::selectPairs() . But I keep getting an error at a parameter. The error is: "illegal call of non-static member function" My code is below:

vector<Mat> images;
vector<vector<KeyPoint>> keypoints;

images[0].push_back(img1);
images[1].push_back(img2);
for (int i=0; i<keypointsB.size();i++)
{
    keypoints[0].push_back(keypointsB[i]);
}
for (int i=0; i<keypointsA.size();i++)
{
    keypoints[1].push_back(keypointsA[i]);
}

FREAK::selectPairs(images,keypoints,0.7,true);

Any help would be appreciated.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
2

answered 2012-12-27 06:01:04 -0600

Emmanuel gravatar image

updated 2012-12-27 06:01:47 -0600

Your syntax is incorrect. Since selectPairs() is not a declared as static function, it can only be called by an instance of the class.

So you have write something like this instead:

FREAK myFreak;
myFreak.selectPairs(images, keypoints, 0.7, true);
edit flag offensive delete link more

Comments

Thanks a lot. I figured the syntax was incorrect but since I'm not a computer scientist, didn't know why.

aliciadominica gravatar imagealiciadominica ( 2012-12-27 06:11:24 -0600 )edit

Question Tools

Stats

Asked: 2012-12-27 04:17:54 -0600

Seen: 411 times

Last updated: Dec 27 '12