Transfer Binary ROI to a raw 12bit image
9 views (last 30 days)
Show older comments
Hi. I have a 12bit grayscale image (of white dots on a black background) that I binarise. Is it possible to create circular ROI's around the binary image features and trasnfer these back onto the raw 12 bit image. This is what I have so far>
bw = im2bw(I, graythresh(I));
axis off;
imshow(bw)
%-------------------------------------------------------
bw4_perim = bwperim(bw);
CC=bwconncomp(bw4_perim); %This is a struct, so access only the number
num = CC.NumObjects;
set(handles.editCount,'String', num2str(num));
axes(handles.axes3)
imshow(I,[])
hold on
spy(bw4_perim)
0 Comments
Answers (1)
Walter Roberson
on 21 Nov 2011
Once you have the binary circle created in the appropriate positions, multiply the roi mask by (2^12 - 1) to get the 12-bit grayscale image.
0 Comments
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!