Azzera filtri
Azzera filtri

I'm a beginner in matlab. I have a rgb image and I would like to get the intensity value of every pixels in the image.

1 visualizzazione (ultimi 30 giorni)
For grey scale image if r,c,a are row,column,image then [r c a(r,c)] means we are storing coordinates along with intensity value in a row.how should this be modified for rgb images since they have third dimension in addition ?? and if i use rgb2gray then number of pixels are getting reduced, does this mean we are loosing some information???

Risposta accettata

Image Analyst
Image Analyst il 2 Feb 2013
With a true color image, there is a third dimension. That third dimension is either the red value at that row,column location, the green value, or the blue value, depending on if the third dimension index is 1, 2, or 3 respectively.
If you use rgb2gray on an rgb image, then the output of that is a gray scale image and the gray scale image has less information in it than the original color image.

Più risposte (0)

Categorie

Scopri di più su Image Processing Toolbox in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by