|MadSci Network: Computer Science|
I am looking for a way to convert 24bit colors into greyscale colors for a program I am writing. From experimentation and observations from an image editing program, I think it is somehow related to the luminance values of the 24bit color. For example the color (in RGB) 0,82,251 has a luminance of 118. Converted to greyscale it is 75,75,75 with a luminance of 71. A grey scale color's luminance is proportional to it's RGB.(71 is 94.6% of 75) I can't seem to find a connection between the luminance and the RGB in colors that have different red, green, and blue values though. Does it have something to do with the hue and saturation?
Re: How do RGB values relate to luminance?
Try the links in the MadSci Library for more information on Computer Science.