mask = 1-double(im2bw(gray, graythresh(gray))); strel = [0 1 1 1 0; 1 1 1 1 1; 1 1 1 1 1; 1 1 1 1 1; 0 1 1 1 0];%structuring element
shadowavg_red = sum(sum(image(:,:,1).*shadow_core)) / sum(sum(shadow_core));
MATLAB: Integers can only be combined with integers of the same class, or scalar doubles.
mask
Best Answer