Median filter on gray image
Afficher commentaires plus anciens
I need to write a code for this median filter on gray image for 3 x 3, 5 x 5, 9 x 9 pixels size in matlab...Please help me with this.
Réponses (1)
Image Analyst
le 16 Mar 2014
From the help:
B = medfilt2(A, [m n]) performs median filtering of the matrix A in two dimensions. Each output pixel contains the median value in the m-by-n neighborhood around the corresponding pixel in the input image. medfilt2 pads the image with 0s on the edges, so the median values for the points within [m n]/2 of the edges might appear distorted.
Of course, needless to say, a and b take on the values 3, 5, and 9. Let me know if you can't figure it out.
2 commentaires
QuestionsAccount
le 15 Fév 2020
please explian it further like what's the values for A.. B m or n. to apply 5×5 median filter on gray image
Image Analyst
le 15 Fév 2020
A is the image variable, a 2-D matrix. B is the filtered version of A. m is the number of rows in the small scanning filter window, and n is the number of columns in the filter window that slides across the input image A.
Catégories
En savoir plus sur Image Filtering dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!