how can remove circle from an image?
이전 댓글 표시
hi I have this image

how can I remove the circles that are not fill?? when I use imfiil the images merge but I want to obtain this image as result:

채택된 답변
추가 답변 (1개)
If thickness of circle boundary is exactly 1 pixel, then its easy.
Loop over each point. For any point, (i,j) there are four pairs of surrounding points:
left (i, j-1) right (i, j+1)
top (i-1, j) bottom (i+1, j)
top-left (i-1, j-1) bottom-right (i+1, j+1)
top-right (i-1, j+1) bottom-left (i+1, j-1)
If there is at least one pair with both points black AND at least one pair with both points white, then make the point black.
Maybe you can extend the idea to circles whose boundary has > 1 thickness.
카테고리
도움말 센터 및 File Exchange에서 Convert Image Type에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
