mirror of
https://github.com/RustyRaptor/learnopencv.git
synced 2026-12-03 22:15:16 -07:00
More refinement on alignment code
This commit is contained in:
1 parent
1f66286e19
commit
c8e3ae2d2b
1 file changed
+2
-2
@@ -6,7 +6,7 @@ using namespace std;
|
||||
using namespace cv;
|
||||
using namespace cv::xfeatures2d;
|
||||
|
||||
const int MAX_MATCHES = 500;
|
||||
const int MAX_FEATURES = 500;
|
||||
const float GOOD_MATCH_PERCENT = 0.15f;
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@ void alignImages(Mat &im1, Mat &im2, Mat &im1Reg, Mat &h)
|
||||
Mat descriptors1, descriptors2;
|
||||
|
||||
// Detect ORB features and compute descriptors.
|
||||
Ptr<Feature2D> orb = ORB::create(MAX_MATCHES);
|
||||
Ptr<Feature2D> orb = ORB::create(MAX_FEATURES);
|
||||
orb->detectAndCompute(im1Gray, Mat(), keypoints1, descriptors1);
|
||||
orb->detectAndCompute(im2Gray, Mat(), keypoints2, descriptors2);
|
||||
|
||||
|
||||
Reference in new issue
Block a user