how to convert an image into binary image while selecting multiple regions?
조회 수: 1 (최근 30일)
이전 댓글 표시
Hi, I use free hand drawing to select the regions in the image.
I segmented this image and converted to bw
and the next one is the binary image(binaryImage) of the above segmented image
hFH = imfreehand();
% Create a binary image ("mask") from the ROI object.
binaryImage = hFH.createMask();
----(binaryImage)-
i did inside contouring and selected the inner region,
this is the binary image of the inner region that i got after contouring
---binaryImage1----
and in order to get the binary image for the segmented image with the inner region i did
segmentedImageMask=binaryImage-binaryImage1;
I performed contouring of multiple regions, which means selected regions one by one. This is the first region
and this is the second region
So, when i tried to get the binary mask of the multiple regions by using
segmentedImageMask=binaryImage-binaryImage2;
I could get only the last region that i selected but not multiple regions.
Can you assist me in getting all the selected regions in the segmented binary mask of the multiple regions.
thanks...
댓글 수: 0
답변 (1개)
Image Analyst
2014년 7월 21일
I already answered in the duplicate question: http://www.mathworks.com/matlabcentral/answers/142820#answer_145879
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Convert Image Type에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!