cv.matchShapes - MATLAB File Help
cv.matchShapes

Compares two shapes

result = cv.matchShapes(contour1, contour2)
result = cv.matchShapes(..., 'OptionName', optionValue, ...)

Input

Output

Options

The function compares two shapes. All three implemented methods use the Hu invariants (see cv.HuMoments).

The following shape matching methods are available:

where A denotes contour1, B denotes contour2, and:

m_i^A = sign(h_i^A) * log(h_i^A)
m_i^B = sign(h_i^B) * log(h_i^B)

and h_i^A, h_i^B are the Hu moments of A and B, respectively.

See also