Functions
cv Namespace Reference

Functions

Mat estimateRigidTransform (InputArray src, InputArray dst, OutputArray inliers_mask, bool fullAffine)
 Computes an optimal affine transformation between two 2D point sets.
static void getRTMatrix (const Point2f *a, const Point2f *b, int count, Mat &M, bool fullAffine)

Function Documentation

Mat cv::estimateRigidTransform ( InputArray  src,
InputArray  dst,
OutputArray  inliers_mask,
bool  fullAffine 
)

Computes an optimal affine transformation between two 2D point sets.

Parameters:
srcFirst input 2D point set stored in std::vector or Mat
dstSecond input 2D point set of the same size and the same type as A
fullAffineIf true, the function finds an optimal affine transformation with no additional restrictions (6 degrees of freedom). Otherwise, the class of transformations to choose from is limited to combinations of translation, rotation, and uniform scaling (5 degrees of freedom).

This fuction is similar to cv::estimateRigidTransform. Key difference are:

does not support images as input output inliners in similar manner to cv::findHomography

The function finds an optimal affine transform *[A|b]* (a 2 x 3 floating-point matrix) that approximates best the affine transformation between:

Two point sets

In case of point sets, the problem is formulated as follows: you need to find a 2x2 matrix *A* and 2x1 vector *b* so that:

\[[A^*|b^*] = arg \min _{[A|b]} \sum _i \| \texttt{dst}[i] - A { \texttt{src}[i]}^T - b \| ^2\]

where src[i] and dst[i] are the i-th points in src and dst, respectively $[A|b]$ can be either arbitrary (when fullAffine=true ) or have a form of

\[\begin{bmatrix} a_{11} & a_{12} & b_1 \\ -a_{12} & a_{11} & b_2 \end{bmatrix}\]

when fullAffine=false.

See also:
getAffineTransform, getPerspectiveTransform, findHomography

Definition at line 136 of file estimate_rigid_transform.cpp.

static void cv::getRTMatrix ( const Point2f *  a,
const Point2f *  b,
int  count,
Mat &  M,
bool  fullAffine 
) [static]

Definition at line 58 of file estimate_rigid_transform.cpp.



map_merge
Author(s): Jiri Horner
autogenerated on Sun Mar 26 2017 03:48:10