erosion & dilation



hello, i am doing on erosion and dilation technique. yeserday i posted
one of my problem what i want, but its not there in group. so i am
posting again. plz reply as soon with some modifications . my problem
is i am calculating area of image surface after erosion and dilation
process. i am getting area of 0 to +400. i want how to recognize its
negative area (if possible).and one more thing is i am giving certain
number of erosion and dilation cycles, but i am getting here same area
for given any number. plz make it corrections what i am posting
coding.plzzzzzzzzzzzzz. Regards kumar

B=imread('C:\Documents and Settings\Civil\Desktop\T19\25\3.jpg');
% B1=rgb2gray(B);
for k=1:27.82 here i want to give different numbers, and i
would like to get different values.
se=strel('square',3);
bw=imerode(B,se);
% imshow(bw)
bw1=imdilate(bw,se);
% imshow(bw1)
[m n]=size(bw1);
y=0;
for i=1:m
for j=1:n
if (bw1(i,j)==1)
y=y+1;
end
end
end
end
disp(y)

.



Relevant Pages

  • Re: binrary dilation and convolution
    ... > I am working on image processing on a special instrument and used a lot ... binary dilation is very slow. ... > very efficient on convolution. ... You can view dialation or erosion as a blur followed by a lookup table ...
    (sci.image.processing)
  • My project is on erosion & dilation process in image preocessing
    ... erosion & dilation technique in image processing. ... till now i have written this programme. ... plz send me programme for this queery. ...
    (sci.image.processing)