Trimming the outline of an image systematically

2 visualizzazioni (ultimi 30 giorni)
Michael S
Michael S il 30 Nov 2018
Hi all,
I'm attempting to reduce the thickness of lines in the figure of an image systematically while keeping the skeleton of the figure the same. What this effectively comes down to is trimming the outer layer of pixels along the perimeter of the figure. Ultimately, I am trying to match the # of pixels between different images by thinning or thickening the lines that make up the figures while keeping the original size and shape of each figure the same.
I have played around with several functions such as bwboundaries, bwmorph ('skel', 'thin', 'remove', etc.) but I am pretty sure these functions are not the right ones to do the job that I want, or I am just using these functions the wrong way. I attached an example of what I am trying to accomplish featuring a BW image of the letter 'R' and one that I " thinned" crudely by hand. Thanks in advance!

Risposte (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by