5 ms·
Very informative, thank you! Something I've been mulling over for awhile now is... what does it mean to represent a color with numbers? That is, every pixel o
by palish 16y ago
Very informative, thank you!
Something I've been mulling over for awhile now is... what does it mean to represent a color with numbers?
That is, every pixel on our monitor is RGB 0 through 255. But what about in physics? Well, "color" is a photon whose wavelength falls between 400nm (short wavelength; intense energy; "ultra"-violet; and violet = blueish; therefore 400nm = "the blue side" of the EM spectrum; this is how I remember that) and 700nm (red).
So on one hand, we have three numbers, R, G, and B; on the other hand, we have a single number, wavelength.
Obviously, the answer is that R, G, and B have some significance to the human eye. But wait a minute; every human eye is different. Some people are color blind, for example. So these RGB values can't really claim to have a physical basis.
Now, what is the meaning of a combination of colors? Let's say, RGB(50,50,0) + RGB(0,50,50). Is the result RGB(50,100,50), like you'd expect?
I think not.
RGB is not a linear space. In the same way you can't add two points on the Richter scale, you can't add two RGB values and get a meaningful result, I think.
So then we have something called "sRGB", which claims to be a linear space. But really, sRGB is merely RGB space "warped" to conform to the gamma curves of standard monitors. It still has no physical meaning, as far as I can see.
I believe perhaps the correct answer is...
When a light source emits light (for example an incandescent light bulb), it's really emitting many different wavelengths along the EM spectrum. The final color is the result of our eyes combining those wavelengths.
So, to add two colors A and B, we must first convert them both from RGB back into the EM spectrum (think of it like a histogram, where the X axis is wavelength from 400nm to 700nm, and the Y axis is the intensity of each wavelength); then add the two spectrums; then finally convert the resulting spectrum back to RGB.
Will this produce the same results as (A + B)? I don't think so, but I haven't tried it.
Food for thought...
- ignifero 16y agoEM radiation can have any wavelength. Color is the visible spectrum in which our retinal cones and rods respond when EM is shone upon them (actually, they cease responding, but that's another matter). We have 3 kinds of cone cell receptors sensitive to different parts of the visible spectrum. Color is the perception generated further down in our brain from the combination of these incoming signals. Screens were designed to be visible, that's why it makes sense to have 3 colors of LEDs. Light wave frequencies do not add up, i.e. you can't add 2 green beams to create an ultraviolet.
- palish 16y agoMy point was that you can't add two RGB values and expect to get a meaningful physical result --- you can't multiply them either, as far as I know. This has vast implications for computer graphics. Video games, for example. "Light wave frequencies do not add up, i.e. you can't add 2 green beams to create an ultraviolet." The light wave frequencies do add up --- if you add 2 "green" beams, then you get a more intensely bright green beam. The hue changes only slightly.
- ignifero 16y agoRGB values can be added to create other colors, just like painters mix colors (just divide the sum by 2 to avoid saturation), because the R, G and B colors were arbitrarily selected from the beginning to match what the artists were familiar with. In the case of combining beams, what changes is the intensity of the beam, the frequency spectrum does not change at all (there is two photon excitation, but that's a completely different phenomenon).
- palish 16y agoYou are missing my point. From a physical standpoint, it makes no sense to add two RGB colors. It makes sense to add two lengths. (1 inch) + (1 inch) = (2 inches). It does not make sense to add two RGB colors. The result is not a meaningful physical quantity. In the same spirit, (7.8 earthquake) + (8.3 earthquake) != (16.1 earthequake). This is a big problem for those of us who are trying to reproduce how nature looks on the screen of a computer. (In my case, realtime graphics.) For the case of the combining beams of light, the only time that the hue wouldn't change is if you have two lightbulbs that emit precisely the same EM waves --- the same frequencies and the same intensities for all emitted waves. This is practically impossible. Therefore, the hue of the combination is never exactly the same. Just because you can't perceive the difference, doesn't mean there isn't a difference.
- simpleTruth 16y agoWhat your missing is the concept that RGB colors are based not around the physical property's of light but the eyes ability to detect light using Rods and cones. In the real world there is a difference between 390 nm light and 390.00001nm light all the way up to749.9999 nm. However all of that is abstracted away and the eye only really cares about the relative intensity of RGB when there is enough light or just B and W in really low light conditions. So, to fool a machine you might need to exactly match all the individual wavelengths relative intensity but with a human you get to ignore most of that and just look at 3 numbers per pixel. PS: A small number of people can detect 4 colors but the net effect of this is almost meaningless for various reasons.