Ask Your Question
1

combining small white blobs to one blob..

asked 2015-04-02 15:27:58 -0600

215 gravatar image

I have this binary image, which have contours.. I am looking for method which fill out the contours, such that when i draw a Rect around the contour, i will not draw multiple small rect to cover the same person...

ex.

http://imgur.com/SjHf1lw

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
4

answered 2015-04-02 16:14:57 -0600

Witek gravatar image

Use morphological operations like dilation or closing to merge small adjacent blobs.

edit flag offensive delete link more

Comments

3

The downside is that you can never know how many closing or dilation operations you need to perform to reach the desired result. You could make it dependant on center distances of blobs. If the distance between two centers is smaller than a threshold that you select, then perform merging and closing to bring them together basing the amount of iterations on the distance between the centers. Do this for each combination of close blobs! However you will notice that this will still yield problems!

StevenPuttemans gravatar imageStevenPuttemans ( 2015-04-03 04:54:55 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2015-04-02 15:27:58 -0600

Seen: 1,742 times

Last updated: Apr 02 '15