1 | initial version |
It kind of depends on the gaps, can you produce some examples for us? But in general I would look at something like
findContours
.dilate
and erode
are useful here), keeping in mind that blobs split vertically should be merged, but horizontally should be left alone, because then you will connect neighboring letters.Good luck!