[−][src]Function opencv::features2d::draw_matches
pub fn draw_matches(
img1: &Mat,
keypoints1: &VectorOfKeyPoint,
img2: &Mat,
keypoints2: &VectorOfKeyPoint,
matches1to2: &VectorOfDMatch,
out_img: &mut Mat,
match_color: Scalar,
single_point_color: Scalar,
matches_mask: &VectorOfchar,
flags: i32
) -> Result<()>
Draws the found matches of keypoints from two images.
Parameters
- img1: First source image.
- keypoints1: Keypoints from the first source image.
- img2: Second source image.
- keypoints2: Keypoints from the second source image.
- matches1to2: Matches from the first image to the second one, which means that keypoints1[i] has a corresponding point in keypoints2[matches[i]] .
- outImg: Output image. Its content depends on the flags value defining what is drawn in the output image. See possible flags bit values below.
- matchColor: Color of matches (lines and connected keypoints). If matchColor==Scalar::all(-1) , the color is generated randomly.
- singlePointColor: Color of single keypoints (circles), which means that keypoints do not have the matches. If singlePointColor==Scalar::all(-1) , the color is generated randomly.
- matchesMask: Mask determining which matches are drawn. If the mask is empty, all matches are drawn.
- flags: Flags setting drawing features. Possible flags bit values are defined by DrawMatchesFlags.
This function draws matches of keypoints from two images in the output image. Match is a line connecting two keypoints (circles). See cv::DrawMatchesFlags.
C++ default parameters
- match_color: Scalar::all(-1)
- single_point_color: Scalar::all(-1)
- matches_mask: std::vector
() - flags: DrawMatchesFlags::DEFAULT