How do I go about identifying multiple instances of specific shapes?

I would like to identify Install maps from an image using OpenCV 2.3. I can successfully use findContours to highlight shapes: Setshapes .

How can I encode three shapes of interest and compare them with the image so that I can find them in different revolutions and sizes?

I do not ask permission, just suggestions for an approach.

+4
source share
1 answer

From the left image you can segment each map.

Then try using OpenSV matchShapes () to match these three forms.

Since matchShape () uses HuMoments, opencv doc described that Hu Moments are invariants to the scale, rotation and reflection of the image, except for the seventh ...

You can also refer to the opencv example code: cpp / squares.cpp to develop your own form-conforming program.

+1
source

All Articles