The goal of this tutorial is to learn how to use features2d and calib3d modules for detecting known planar objects in scenes.
Test data: use images in your data folder, for instance, box.png and box_in_scene.png.
Create a new console project. Read two input images.
Detect keypoints in both images.
Compute descriptors for each of the keypoints.
Now, find the closest matches between descriptors from the first image to the second:
Visualize the results:
Find the homography transformation between two sets of points:
Create a set of inlier matches and draw them. Use perspectiveTransform function to map points with homography:
Mat points1Projected; perspectiveTransform(Mat(points1), points1Projected, H);
Use drawMatches for drawing inliers.
'Camera Calibration' 카테고리의 다른 글
OpenCV API - Geometric Image Transformations (0) | 2013.03.18 |
---|---|
Perspective Projection (0) | 2013.03.18 |
Mahalanobis Distance (0) | 2013.03.18 |
최소자승법 Least Square (0) | 2013.03.17 |
Least Mean of Squares (0) | 2013.03.17 |