Filling regions in binary image ?
Ältere Kommentare anzeigen
I have this binary image that is the result of thresholding the saturation component of the HSV image. Link: satImage_afterthreshold
As you can see, before edge detection can be used, I need the regions within the image to be filled. This is what I tried so far, but the outcome isn't pretty.
se = strel('disk', 5); closeBW = imclose(satImage > graythresh(satImage_afterthreshold),se); imtool(closeBW);
This probably needs a combination of different morphological operations such as imfill, bwareaopen, etc. Any help?
edit01:
Slight enhancement: I used bwareaopen to remove the unwanted pixels on the bottom right of the image. Link: openBW This is the outcome after edge detection: closeBW_canny2 Still, it's not pretty.
Akzeptierte Antwort
Weitere Antworten (1)
yair suari
am 31 Jul. 2011
1 Stimme
there used to be a function in the exchange to do just that i dont remember the name but it was something like hfill_nans
1 Kommentar
Jason
am 3 Aug. 2011
Kategorien
Mehr zu Object Analysis finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!