using a Prewitt filter to detect edges in a image
Show older comments
Hi i am trying to do something basic just to acquint myself with image processing. I'm a newbie at this. I am just trying to use a Prewit filter to find the edges; This is the code that I have used:
ic = imread('ic.tif');
b = mean(ic,3);
px = [-1 0 1; -1 0 1; -1 0 1];
ic = filter2(px,ic);
figure, imshow(icx/255)
i get the statement:
Undefined function 'conv2' for input arguments of type 'double' and attributes 'full 3d real'.
before converting the image to a double it was saying that the filter function is 2d and the image is 3d. I am nt sure what to do . Please help.
1 Comment
Image Analyst
on 21 Dec 2012
What does this say:
whos ic
and what is icx - you never defined it.
Answers (0)
Categories
Find more on Object Analysis in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!