OpenCV: cv::detail::AffineBestOf2NearestMatcher Class Reference

| OpenCV 3.4.2 Open Source Computer Vision

Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
cv::detail::AffineBestOf2NearestMatcher Class Reference
Images stitching » Features Finding and Images Matching

Features matcher similar to cv::detail::BestOf2NearestMatcher which finds two best matches for each feature and leaves the best one only if the ratio between descriptor distances is greater than the threshold match_conf. More...

`#include "matchers.hpp"`

Inheritance diagram for cv::detail::AffineBestOf2NearestMatcher:

## Public Member Functions
| AffineBestOf2NearestMatcher (bool full_affine=false, bool try_use_gpu=false, float match_conf=0.3f, int num_matches_thresh1=6)
| Constructs a "best of 2 nearest" matcher that expects affine trasformation between images. More...
Public Member Functions inherited from cv::detail::BestOf2NearestMatcher
| BestOf2NearestMatcher (bool try_use_gpu=false, float match_conf=0.3f, int num_matches_thresh1=6, int num_matches_thresh2=6)
| Constructs a "best of 2 nearest" matcher. More...
void | collectGarbage () CV_OVERRIDE
| Frees unused memory allocated before if there is any. More...
Public Member Functions inherited from cv::detail::FeaturesMatcher
virtual | ~FeaturesMatcher ()
bool | isThreadSafe () const
void | operator() (const ImageFeatures &features1, const ImageFeatures &features2, MatchesInfo &matches_info)
void | operator() (const std::vector< ImageFeatures > &features, std::vector< MatchesInfo > &pairwise_matches, const cv::UMat &mask=cv::UMat())
| Performs images matching. More...

## Protected Member Functions
void | match (const ImageFeatures &features1, const ImageFeatures &features2, MatchesInfo &matches_info) CV_OVERRIDE
| This method must implement matching logic in order to make the wrappers detail::FeaturesMatcher::operator()_ work. More...
Protected Member Functions inherited from cv::detail::FeaturesMatcher
| FeaturesMatcher (bool is_thread_safe=false)

## Protected Attributes
bool | full_affine_
Protected Attributes inherited from cv::detail::BestOf2NearestMatcher
Ptr< FeaturesMatcher > | impl_
int | num_matches_thresh1_
int | num_matches_thresh2_
Protected Attributes inherited from cv::detail::FeaturesMatcher
bool | is_thread_safe_

## Detailed Description

Features matcher similar to cv::detail::BestOf2NearestMatcher which finds two best matches for each feature and leaves the best one only if the ratio between descriptor distances is greater than the threshold match_conf.

Unlike cv::detail::BestOf2NearestMatcher this matcher uses affine transformation (affine trasformation estimate will be placed in matches_info).

See also
  cv::detail::FeaturesMatcher cv::detail::BestOf2NearestMatcher

## Constructor & Destructor Documentation

## ◆ AffineBestOf2NearestMatcher()

cv::detail::AffineBestOf2NearestMatcher::AffineBestOf2NearestMatcher | ( | bool | full_affine = `false`,
|  | bool | try_use_gpu = `false`,
|  | float | match_conf = `0.3f`,
|  | int | num_matches_thresh1 = `6`
| ) |  |
| inline

Constructs a "best of 2 nearest" matcher that expects affine trasformation between images.

Parameters

  full_affine | whether to use full affine transformation with 6 degress of freedom or reduced transformation with 4 degrees of freedom using only rotation, translation and uniform scaling
  try_use_gpu | Should try to use GPU or not
  match_conf | Match distances ration threshold
  num_matches_thresh1 | Minimum number of matches required for the 2D affine transform estimation used in the inliers classification step

See also
  cv::estimateAffine2D cv::estimateAffinePartial2D

## Member Function Documentation

## ◆ match()

void cv::detail::AffineBestOf2NearestMatcher::match | ( | const ImageFeatures & | features1,
|  | const ImageFeatures & | features2,
|  | MatchesInfo & | matches_info
| ) |  |
| protectedvirtual

This method must implement matching logic in order to make the wrappers detail::FeaturesMatcher::operator()_ work.

Parameters

  features1 | first image features
  features2 | second image features
  matches_info | found matches

Reimplemented from cv::detail::BestOf2NearestMatcher.

## Member Data Documentation

## ◆ full_affine_

bool cv::detail::AffineBestOf2NearestMatcher::full_affine_
| protected

The documentation for this class was generated from the following file:

- stitching/include/opencv2/stitching/detail/matchers.hpp