Most color images are stored in RGB format. In other words, they are 3D matrices where the first, second, and third matrix represents the intensity of red, green, and blue respectively.
In your case, the simplest solution may be to isolate the blue-channel and perform segmenting on that image:
imageRaw = imread("source");
imageBlue = imageRaw(:,:,3);
imageBlueThresh = graythresh(imageBlue);
imageBlueBw = im2bw(imageBlue,imageBlueThresh);
What would you like to do with the segmented regions though? Remove everything else from the image? Outline them? Quantify something within those regions?
Best Answer