
Help with image manipulation (blur)
13 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
John Abe
le 28 Fév 2017
Modifié(e) : Image Analyst
le 28 Fév 2017
I have the code
img=imread('x.jpg');
img = im2double(img);
avg3 = ones(3)/9;
k1 = imfilter(img, avg3,'conv');
imshow(k1)
I am trying to blur the image using a kernel and convolution but it keeps coming out the same. Any one know how to fix this?
0 commentaires
Réponse acceptée
Image Analyst
le 28 Fév 2017
Modifié(e) : Image Analyst
le 28 Fév 2017
It doesn't come out the same. You either aren't looking at it magnified enough. Or, for tiny displayed images, you'll need to increase the blur window to notice a difference. This code works:
rgbImage = imread('peppers.png');
rgbImage = im2double(rgbImage);
windowSize = 15;
avg3 = ones(windowSize) / windowSize^2;
subplot(2,1,1);
imshow(rgbImage)
blurredImage = imfilter(rgbImage, avg3, 'conv');
subplot(2,1,2);
imshow(blurredImage)

0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Matched Filter and Ambiguity Function dans Help Center et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!