I try to thin a binary edge map to get single-pixel-width edges. I use
the Matlab's bwmorph(bw, 'thin') to implement this task. But there are
two problems that is not desirable in resultant edge map:
- The processed edge map by bwmorph(bw, 'thin') is not strictly
single-pixel-width. But in my application, all edges should be composed
of single pixel width strokes strictly.
- After thinning, there are many tiny 'stings' composed of several
pixel on the edge. I want to get rid of these 'stings' but keep the
edges 'untouched', so any filtering operation is not preferred.
Could somebody here give me some suggestions on these problems?
Thank you very much.