This function takes a label image and converts it to a CC struct, the same output as bwconncomp. It is the inverse of labelmatrix and is useful for:
-Those without a version containing bwconncomp.
-Those who have already have a large label matrix and want it converted to a CC struct.
Sean de (2020). label2CC (https://www.mathworks.com/matlabcentral/fileexchange/30702-label2cc), MATLAB Central File Exchange. Retrieved .