How can I connect my connected-components?

5 views (last 30 days)
Jh Qian
Jh Qian on 19 Mar 2019
Commented: Jh Qian on 19 Mar 2019
QQ浏览器截图20190319105427.png
This is a part of my binary image, and I got it by command "skel= bwmorph(BW,'skel',Inf)" .
I want to connect these white connected components, mergeing them into one connected component.
How can I do it?
THANKS! :)

Answers (1)

KSSV
KSSV on 19 Mar 2019
I = imread('QQ20190319105427.png') ;
I1 = rgb2gray(I) ;
imshow(I)
hold on
[c,h] = contour(I1) ;
  3 Comments
KSSV
KSSV on 19 Mar 2019
DRawing the contours....you will get your coordinates.....you want to join all the white lines?
Jh Qian
Jh Qian on 19 Mar 2019
Yes! I want to join all the white lines.

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!