Effacer les filtres
Effacer les filtres

What is the significance of averaging two or multiple images in matlab?

2 vues (au cours des 30 derniers jours)
shivam sahil
shivam sahil le 6 Déc 2017
Commenté : shivam sahil le 7 Déc 2017
While going through Image processing I came across this code to find the average of two images:
I = imread('rice.png');
I2 = imread('cameraman.tif');
K = imlincomb(.5,I,.5,I2);
Can someone please explain what is the significance of averaging image in this way, whether it is with respect to pixels or RGB contrast profile or what?

Réponses (1)

Image Analyst
Image Analyst le 6 Déc 2017
It is simply a weighted average of the pixel values, basically
K = uint8(.5 * double(I) + 0.5 * double(I2));
I and I2 have to be the same size, both laterally (rows and columns) and in the number of color channels (1 or 3).
K is usually the same class as I, uint8 in your example case.
Not sure what you mean by "RGB contrast profile".
  1 commentaire
shivam sahil
shivam sahil le 7 Déc 2017
Thanks! I got what I was asking, the answer you provided cleared my queries. Thanks again :)

Connectez-vous pour commenter.

Catégories

En savoir plus sur Image Processing Toolbox dans Help Center et File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by