matchShapes
import { matchShapes } from '@banou/opencv-wasm'Use after await initOpenCV(). See the initialization and named imports guide.
Compares two shapes.
The function compares two shapes. All three implemented methods use the Hu invariants (see #HuMoments)
matchShapes(contour1: Mat, contour2: Mat, method: number, parameter: number): number;contour1First contour or grayscale image.
contour2Second contour or grayscale image.
methodComparison method, see #ShapeMatchModes
parameterMethod-specific parameter (not supported now).
Returns
The number result.
These signatures describe this package. Upstream documentation can mention optional backends that are absent from this build. Check runtime compatibility before choosing a backend or file format.