Friday, March 29, 2013

Color Models and Color Spaces

 what is  Demosaicing?
A demosaicing (also de-mosaicing or demosaicking) algorithm is a digital image process used to reconstruct a full color image from the incomplete color samples output from an image sensor overlaid with a color filter array (CFA). It is also known as CFA interpolation or color reconstruction.

 what is color filter arrary?
 bayer color and bayer filter

Color Space and Color Profiles

This page presents an in-depth discussion of the methods used to reproduce color in digital photography.
What's a color model?
What's a color space?
What's a color profile?

http://dpbestflow.org/color/color-space-and-color-profiles#model
http://www.lightillusion.com/forums/index.php?action=vthread&forum=8&topic=50
http://www.cs.rit.edu/~ncs/color/a_spaces.html
http://en.wikipedia.org/wiki/Color_space
http://www.mathworks.in/help/images/converting-color-data-between-color-spaces.html

http://www.siliconimaging.com/RGB%20Bayer.htm

http://www.edn.com/design/integrated-circuit-design/4312122/Converter-translates-Bayer-raw-data-to-RGB-format
http://stackoverflow.com/questions/7598854/how-do-i-convert-bayer-to-rgb-using-opencv-and-vice-versa
 http://stackoverflow.com/questions/10403841/convert-12-bit-bayer-image-to-8-bit-rgb-using-opencv
 http://en.wikipedia.org/wiki/Bayer_filter
http://en.wikipedia.org/wiki/Bayes_filter
 http://en.wikipedia.org/wiki/Demosaicing
 http://www.helicontech.co.il/?id=bayer-rgb

gamut : complete range or scope of something.
subtle: so delicate, sharp.


REf :

https://developer.apple.com/library/mac/#documentation/Cocoa/Conceptual/DrawColor/Concepts/AboutColorSpaces.html

http://en.wikipedia.org/wiki/Color_filter_array

About Color Spaces

A color space describes an abstract, multidimensional environment in which any particular color can be defined. The following sections summarize the basic concepts and terminology of color spaces and discusses how Cocoa implements them.
Some of the information presented here is adapted from Color Management Overview. For a thorough description of color and color spaces, see that document.


Color Models and Color Spaces

The human eye apprehends color as light in a fairly narrow band of the electromagnetic spectrum. The biology of the eye makes it particularly receptive to red, blue, and green light. Humans can visualize a broad range of colors through mixtures of these three primary colors.
A color model is a geometric or mathematical framework that attempts to describe the colors we see. It uses numerical values pinned to dimensions of the model to represent the visible spectrum of color. A color model gives us a method for describing, classifying, comparing, and ordering colors.
A color space is a practical adaptation of a color model that specifies a gamut of colors that can be produced using that model. The color model determines the relationship between values, and the color space defines the absolute meaning of those values as colors. These values, called components, are in most instances floating-point values between 0.0 and 1.0.

Gray, RGB, and CYMK Color Spaces

The simplest color space is the gray space (sometimes also called the white space). The gray space has a single dimension or component, ranging from pure white to pure black; it is used for grayscale printing.
RGB is a three-dimensional color model whose name (as with most color spaces and color models) represents its components—in this case red, green, and blue. RGB-based color spaces are additive, meaning that the three primary colors red, green, and blue are added together in various proportions of intensity to create the colors of the visible spectrum. RGB color spaces are used for devices such as color displays and scanners.
On the other hand, color spaces based on the CYM color model are subtractive. The letters in the model name stand for the components cyan, yellow, and magenta. The major color space based on CYM is CYMK; the “K” in its name stands for the key color, which is black. The subtractive color theory, which underlies CYM, holds that various levels of cyan, magenta, and yellow absorb or “subtract” a portion of the spectrum of the white light illuminating an object. The color of an object is the result of the lights that are not absorbed by the object. The black in the CYMK color space is used to compensate for the interaction of the three primary colors on white paper. The CYMK color space is most commonly used for color printers and similar output devices.
As Figure 1 illustrates, the RGB and CYM color models are complementary, with one being additive and the other subtractive (the red corner in this model representation is hidden from view).
Figure 1  The RGB and CYM color models
The RGB and CYM color models
Two important and related transformations of the RGB color model are the HSV and HLS color spaces. Instead of making red, green, and blue the operative components of the space, these spaces describe colors in terms more natural to an artist:
  • HSV—hue, saturation, value (also known as HSB, where “B” represents brightness)
  • HLS—hue, lightness, saturation
The HSV/B and HLS spaces use models that assign values to these components in conical geometries, as illustrated in Figure 2.
Figure 2  The HSV and HLB color models
The HSV and HLB color models
The hue component in both spaces is a measurement in degrees of color in a spectrum formed into a circle. The values are incremented in a counterclockwise direction: a hue value of zero specifies red, a hue value of 120 indicates green, and so on. In both the HSB and HLS spaces, the saturation component measures color intensity (making the major difference, for example, between tan and brown). The lightness and value (or brightness) components of the different spaces are almost identical. They measure the absence of light—or black—that is part of particular color.
The color panel used in Mac apps has a color-wheel pane that simulates the HSB model (Figure 3).
Figure 3  The color-wheel pane of the color panel
The color-wheel pane of the color panel

Device-Independent Color Spaces

Color spaces based on RGB and CYM color models can be device-dependent or device-independent. Colors from device-dependent color spaces are dependent on the physical characteristics of devices such as monitors (RGB and grayscale) and printers (CYMK) as well as the properties of materials such as ink and paper. Even the age of a device can affect the color it produces. Device-dependent color spaces are limited by the gamut, or range, of colors that a particular device is capable of. Consequently, colors in a device-dependent color space can appear different when rendered by different devices of the same general type.
One can also note subtle color differences among color spaces in the same color-model “family.” For example, the RGB color model has many RGB color spaces, such as ColorMatch, Adobe RGB, sRGB, and ProPhoto RGB. You can assign the same RGB component values to profiles that describe these different RGB color spaces. The color from each color space looks different when rendered, but the numeric values and model are the same.
Some color spaces can express color in a way that is independent of any device. The colors of these device-independent color space are more accurate representations of the colors perceived by the human eye. They derive from the response of the retina to the three primary stimuli of visible light. Many device-independent color spaces result from work carried out by the Commission Internationale d’Eclairage (CIE) and for that reason are also called CIE-based color spaces. Three of the more important CIE-based spaces are XYZ, Yxy, and L*a*b*. Figure 4 depicts the L*a*b* color space.
Figure 4  The L*a*b* color space
The L*a*b* color space
One important use for device-independent color spaces is to convert a color in one device-dependent color space to a reasonably approximate color in a different device-dependent color space. For example, if a program wanted to ensure that a photo displayed on a color monitor (using a RGB color space) was accurately rendered on a printer (using a CYMK color space), it might use a device-independent color space as an interchange space.

No comments:

Post a Comment