I am feature matching between stereo images using openCv, FAST feature detection and Brute force matching.
FastFeatureDetector detector(threshold);
detector.detect(img1, keypoints1);
detector.detect(img2, keypoints2);
OrbDescriptorExtractor extractor;
extractor.compute(img1, keypoints1, descriptors1);
extractor.compute(img2, keypoints2, descriptors2);
BFMatcher matcher(NORM_L2);
matcher.match(descriptors1, descriptors2, matches);
What I would like to do though, Is track points on the left frame using optical flow, THEN match those points on the right frame using feature matching.
Is it possible to feed a feature matching function the pixel coordinates of the point that you wish to match?
You can not specify this to the matcher but you can limit the points at extraction time. In your code keypoints1 and keypoints2 can be the inputs of the extractor for the points you wish to match only. Hence, you should do the following: