The RGB color model is an additional color model in which red, green and blue lights are added together in various ways to reproduce a wide array of colors. The model name comes from the initials of the three additional primary colors, red, green, and blue.
The main purpose of the RGB color model is for the sensing, representation and display of images in electronic systems, such as television and computers, although it has also been used in conventional photography. Prior to the electronic era, the RGB color model already has a strong theory behind it, based on the human perception of color.
RGB is a device-dependent color model: different devices detect or reproduce a given RGB value differently, because color elements (such as phosphor or dye) and their response to individual R, G, and B levels vary from manufacturer to manufacturer, or even on the same device from time to time. Thus, the RGB value does not define the same colors across devices without color management.
Common RGB input devices are color TVs and video cameras, image scanners, and digital cameras. Typical RGB output devices are TV sets of various technologies (CRT, LCD, plasma, OLED, quantum dots, etc.), computer and mobile displays, video projectors, multicolor LED displays and large screens such as JumboTron. Color printers, on the other hand are not RGB devices, but subtractive color devices (usually CMYK color models).
This article discusses the general concept for all the different color spaces that use the RGB color model, which is used in one implementation or the other in a color image producer technology.
Video RGB color model
Additive color
To form colors with RGB, three light beams (one red, one green, and one blue) must be superimposed (eg with emissions from a black screen or with reflections from a white screen). Each of the three beams is called the component of that color, and each of them can have an arbitrary intensity, from completely dead to the fullest, in the mix.
The RGB color model is additive in the sense that all three light beams are added together, and their light spectrum adds, wavelength to wavelength, to create the last color spectrum. This is essentially the opposite of the subtractive color model that applies to paints, inks, dyes, and other substances whose color depends on reflecting light below what we see. Because of its properties, these three colors produce a white color, this is in stark contrast to the physical colors, such as the dye that creates black when mixed.
The zero intensity for each component gives the darkest color (no light, is considered black ), and the full intensity gives each color white; the quality of this white color depends on the nature of the main light source, but if they are properly balanced, the result is white neutral that matches the system's white dot. When the intensity for all components is the same, the result is gray, darker or brighter depending on the intensity. When the intensity is different, the result is a color that is dyed, more or less saturated depending on the difference from the strongest and weakest of the main color intensity used.
When one component has the strongest intensity, the color is a hue near this primary color (reddish, greenish or bluish), and when the two components have the same strongest intensity, the color is a secondary color (shadow). from cyan, magenta or yellow). The secondary color is formed by the addition of two primary colors of the same intensity: cyan is blue green, blue red magenta, and green red yellow. Each secondary color is a complement of a primary color; when the complementary primary and secondary colors are added together, the result is white: cyan red, magenta complement the green, and yellow complement the blue.
The RGB color model itself does not define what is meant by red , green and blue colorimetrically, so the mixing results are not specified as absolute, but relative against the primary colors. When precise chromaticities of the red, green, and blue introduction are defined, the color model then becomes the absolute color space, such as sRGB or Adobe RGB; see RGB color space for more details.
Maps RGB color model
Physical principles for red, green, and blue selections
The selection of primary colors is related to the physiology of the human eye; a good introduction is a stimulus that maximizes the difference between the human retinal cone cell response with different wavelength lights, and thus makes large color triangles.
Three types of normal light-sensitive photoreceptor cells in the human eye (conical cells) provide the most response to yellow (long wavelength or L), green (medium or M), and purple (short or S) light (peak wavelengths approaching 570 à ° nm). , 540m and 440m, respectively). Differences in signals received from all three types allow the brain to distinguish between different colors, while the most sensitive (overall) becomes yellowish green and the difference between the colors in the green-to-orange region.
For example, suppose that light in the orange wavelength range (about 577 nm to 597 nm) enters the eye and attacks the retina. This wavelength light will activate both long and long wavelength cones of the retina, but not the same - the wavelength cells will respond more. Differences in response can be detected by the brain, and this difference is the basis of our perception of orange. Thus, the orange appearance of an object results from the light of the object entering our eyes and simultaneously stimulating the cones but at different degrees.
The use of three primary colors is not sufficient to reproduce all colors; only the colors in the color triangle determined by the chromaticities of the primary can be reproduced by the non-negative mixing additive of the light colors.
History of RGB color model theory and usage
The RGB color model is based on the Young-Helmholtz theory of trichromatic color vision, developed by Thomas Young and Hermann Helmholtz in the early to mid-nineteenth century, and on the color triangle of James Clerk Maxwell which describes the theory (circa 1860).
Photography
The first experiment with RGB in early color photography was made in 1861 by Maxwell himself, and involves the process of combining three separate, color-filtered shots. To reproduce color photos, three matching projection above the screen in a dark room is required.
RGB additive models and variants such as orange-green-purple are also used in Autochrome Lumi̮'̬re color plates and other screen display technologies such as Joly color screen and Paget process in the early twentieth century. Color photography by taking three separate plates was used by other pioneers, such as Sergey Prokudin-Gorsky of Russia in the period 1909 to 1915. Such a method lasted until about 1960 by using the expensive and highly complex Autrobype carbroype tri-color process.
When used, the mold reproduction of a three-plate photograph is performed by a dye or pigment using a complementary CMY model, using only the negative plates of filtered: reversed red giving cyan plates, and so on.
Television
Before the development of practical electronic TV, there was a patent on a mechanically scanned color system dating back to 1889 in Russia. Color TV pioneer John Logie Baird demonstrated the world's first RGB color transmission in 1928, as well as the world's first color broadcast in 1938, in London. In the experiment, scans and displays are performed mechanically with colored wheels that spin.
The Columbia Broadcasting System (CBS) started the RGB-type sequential color system in 1940. The image is electrically scanned, but the system still uses moving parts: RGB transparent color wheels rotate over 1,200 rpm in sync with vertical scanning. Camera and cathode ray tubes (CRTs) are both monochromatic. Color is provided by color wheel in camera and receiver. More recently, color wheels have been used in field TV sequential projection receivers based on DLP Texas Instruments monochrome imagers.
Modern RGB shadow mask technology for the patented CRT display by Werner Flechsig in Germany in 1938.
Personal computer
Early personal computers in the late 1970s and early 1980s, such as those from Apple, Atari and Commodore, did not use RGB as their primary method for managing color, but composite video. IBM introduced the 16-color scheme (four bits - one bit each for red, green, blue, and intensity) with the Color Graphics Adapter (CGA) for its first IBM PC (1981), then upgraded with Enhanced Graphics Adapter (EGA) in 1984. The first manufacturer of Truecolor graphics card for PC (TARGA) was Truevision in 1987, but it was not until the arrival of the Video Graphics Array (VGA) in 1987 that became popular, mainly because of the analog signals in the connection between the adapter and monitors that allow a very wide RGB color range. Actually, it should wait a few more years because the original VGA card is palette-driven like EGA, although with more freedom than VGA, but because the VGA connector is analog, the next VGA variant (made by various manufacturers under the informal name Super VGA) add truecolor. In 1992, many magazines advertise Super VGA truecolor hardware.
RGB devices
RGB and display
One common application of the RGB color model is the color display on cathode ray tubes (CRTs), liquid crystal display (LCD), plasma screens, or organic light-emitting diode (OLED) screens such as televisions, computer monitors, or large-scale screens. Each pixel on the screen is made by driving three small and very close RGB light sources but still separated. At a general point of view, a separate source is indistinguishable, which deceives the eye to see the solid color it provides. All pixels together are arranged in a rectangular display surface according to the color image.
During digital image processing each pixel can be represented in computer memory or interface hardware (for example, graphics card ) as a binary value for red, green, and blue components. When properly managed, these values ââare converted into intensity or voltage through gamma correction to correct the inherent nonlinearity of some devices, so that the intended intensity is reproduced on the screen.
Quattron released by Sharp uses RGB colors and adds yellow as a sub-pixel, which allows an increase in the number of colors available.
Video electronics
RGB is also a term that refers to the type of component video signal used in the electronic video industry. It consists of three signals - red, green, and blue - performed on three separate cables/pins. The RGB signal format is often based on a modified version of the RS-170 and RS-343 standards for monochrome video. This type of video signal is widely used in Europe as it is the best quality signal that can be carried on a standard SCART connector. This signal is known as RGBS (cable ending with 4 BNC/RCA also exists), but directly compatible with RGBHV used for computer monitors (usually done on 15-pin cables ending with 15-pin D-sub or 5 BNC connectors ), which carries separate horizontal and vertical sync signals.
Outside Europe, RGB is not very popular as a video signal format; S-Video takes the place in most non-European areas. However, almost all computer monitors worldwide use RGB.
Video framebuffer
Framebuffer is a digital device for computers that store data in what is called video memory (consists of an array of RAM Video or similar chips). This data goes to three digital-to-analog (DAC) converters (for analog monitors), one per main color, or directly to a digital monitor. Driven by software, the CPU (or other dedicated chip) writes the corresponding byte into the video memory to determine the image. The modern system encodes the pixel color values ââby devoting eight bits to each of the R, G, and B components. RGB information can be performed directly by the pixel bits themselves or provided by a separate color look-up table (CLUT) if the indexed color graphic mode is used.
CLUT is a special RAM that stores R, G, and B values ââthat specify a particular color. Each color has its own address (index) - think of it as a descriptive reference number that provides a certain color when the image needs it. The CLUT content is very similar to the color palette. Image data using indexed colors specifies an address in CLUT to provide the values ââR, G, and B required for each given pixel, one pixel at a time. Of course, before displaying, CLUT must be loaded with R, G, and B values ââthat specify the required color palette for each image to be assigned. Some video apps store such palettes in a PAL file (Microsoft AOE games, for example using more than half a dozen) and can combine CLUT on the screen.
- RGB24 and RGB32
This indirect scheme limits the number of colors available in the CLUT image - typically 256-diced (8 bits in three color channels with values ââfrom 0 to 255) - although each color in the CLOW RGB24 table has only 8 bits representing 256 codes for each each combinatorial mathematical theory R, ââG, and B say this means that any given color can be one of 16,777,216 possible colors. However, the advantage is that indexed image files can be significantly smaller than just 8 bits per pixel per primary.
Modern storage, however, is much cheaper, greatly reducing the need to minimize image file size. Using the right combination of intensity red, green, and blue, many colors can be displayed. The general display adapter currently uses up to 24-bit information for each pixel: 8-bits per component multiplied by three components (see Digital representation section below (24 bits = 256 3 , each value Main 8 bits with values ââ0-255). With this system, 16,777,216 (256 3 or 2 24 ) discrete combinations of R, G, and B values ââare allowed, providing millions of different colors (though not necessarily indistinguishable), enhanced saturation and lightness shading have been implemented in various ways, some formats such as.png and.tga files, among others, use the fourth gray channel as a masking layer, often called < b> RGB32 .
For images with a simple brightness range from the darkest to the lightest, eight bits per main color provides good quality images, but extreme images require more bits per main color as well as advanced display technology. For more information, see High Dynamic Range (HDR) imaging.
Nonlinearity
In a classical cathode ray tube (CRT) device, the brightness of a particular point above the fluorescent screen because the impact of an accelerated electron is not proportional to the voltage applied to the electron gun control grid, but to the wide function of that voltage. This number of deviations is known as the gamma value ( ), the argument for the power law function, which describes this behavior carefully. The linear response is given by the value of gamma 1.0, but the actual nonlinear CRT has a gamma value of about 2.0 to 2.5.
Similarly, the intensity of output on TV and computer display devices is not proportional to R, G, and B applying electrical signals (or the value of data files that propel them through Digital-to-Analog Converters). On a standard 2.2-gamma CRT display, the RGB value of input intensity (0.5, 0.5 0.5 0.5) only generates about 22% of full brightness (1.0, 1.0, 1.0) , instead of 50%. To get the correct response, gamma correction is used in encoding image data, and possibly further correction as part of the device's color calibration process. Gamma affects black and white TV as well as color. In standard color TV, broadcast signals are corrected gamma.
RGB and camera
In color television and video cameras manufactured before the 1990s, incoming lights are separated by prisms and filters into three primary RGB colors that feed each color into separate video camera tubes (or pickup tubes ). These tubes are a type of cathode ray tube, not to be confused with the CRT display.
With the arrival of a commercially available charge-coupled device (CCD) technology in the 1980s, the first pickup tube was replaced with this type of sensor. Then, high-scale electronics integration is applied (especially by Sony), simplifying and even removing medium optics, thereby reducing the size of home video cameras and ultimately leading to the development of full camcorders. Webcams and mobile phones today with cameras are the most miniature commercial form of the technology.
Digital photography cameras that use CMOS or CCD image sensors often operate with several variations of the RGB model. In the Bayer filter setting, the green is given twice as many detectors as red and blue (1: 2: 1 ratio) to achieve a higher resolution of lighting than the resolution of chrominance. The sensor has a red, green, and blue detector grid set so that the first line is RGRGRGRG, the next is GBGBGBGB, and the sequence is repeated in the next line. For each channel, the missing pixels are obtained by interpolation in the demosaicing process to build the complete image. In addition, another process used to map the camera RGB measurements into a standard RGB color space as sRGB.
RGB and scanner
In computing, the image scanner is a device that optically scans images (text, handwriting, or objects) and converts them into digital images transferred to a computer. Among other formats, flat, drum and film scanners exist, and most of them support RGB colors. They can be considered as the successors of initial telephotography input devices, capable of sending sequential scan lines as analog amplitude modulation signals via standard telephony lines to the appropriate receiver; Such systems were used since the 1920s until the mid-1990s. The color telepotograph is sent as three separate RGB filter images in sequence.
Currently available scanners typically use a charge-coupled device (CCD) or contact image sensor (CIS) as image sensors, while older drum scanners use photomultiplier tubes as image sensors. Early color film scanners use halogen lamps and three-color filter wheels, so three exposures are required to scan one color image. Due to heating problems, the worst is the potential for the destruction of scanned films, this technology is subsequently replaced by non-heating light sources such as color LEDs.
Numerical representation
The colors in the RGB color model are explained by showing how much each red, green, and blue are included. Colors are expressed as RGB triplets ( r , g , b ), each component may vary from zero to the specified maximum value. If all components are zero then the result is black; if everything is maximal, the result is the brightest white.
This range can be quantified in several different ways:
- From 0 to 1, with fractional values ââin between. This representation is used in theoretical analysis, and in systems that use floating point representation.
- Each color component value can also be written as a percentage, from 0% to 100%.
- In computers, component values ââare often stored as integers in the range 0 to 255, the range offered by an 8-bit byte. This is often represented as a decimal or hexadecimal number.
- High-end digital image tools are often able to handle larger integer ranges for each main color, such as 0.1023 (10 bits), 0.65535 (16 bits) or even larger, by extending 24-bits ( three 8-bit values) to 32-bit, 48-bit, or 64-bit units (more or less independent of the size of a particular computer word).
For example, the brightest saturated red is written in different RGB notations such as:
In many environments, the component values ââwithin the range are not managed as linear (ie, numbers are non-linearly related to the intensity they represent), as in digital cameras and TV broadcasts and received due to gamma correction, for example. Linear and nonlinear transformations are often handled through digital image processing. Representation with only 8 bits per component is considered sufficient if gamma encoding is used.
Here is the mathematical relationship between RGB space to HSI space (hue, saturation, and intensity: HSI color space):
The RGB color model is one of the most common ways to encode colors in computing, and several different binary digital representations are in use. The main characteristic of all is the quantization of possible values ââper component (technically Sample (signal) ) by using only integers in some ranges, typically from 0 to several forces two minus one (2 n Ã,-1) to include them into small groups. Encodings 1, 2, 4, 5, 8 and 16 bits per color are usually found; the total number of bits used for RGB colors is usually called the color depth.
Geometric Representation
- See also RGB color space
Since color is usually determined by three components, not only in the RGB model but also in other color models such as CIELAB and Y'UV, inter alia, the three-dimensional volume is represented by treating the component values ââas ordinary cartesian coordinates in the euclidean space. For the RGB model, this is represented by a cube using non-negative values ââin the range 0-1, assigning black to origin at the point (0,0,0), and with increasing intensity values âârunning along three axes rising to white at a point (1, 1, 1), the opposite black diagonal.
The RGB triplet ( r , g , b ) represents the three-dimensional coordinates of the color dot provided in the cube or face or along the edges. This approach allows the calculation of the similarity of two color RGB colors given by simply calculating the distance between them: the shorter the distance, the higher the similarity. Calculations outside the gamut can also be done in this way.
Color in web page design
The RGB color model for HTML is officially adopted as an Internet standard in HTML 3.2, although it has been used for some time before that. Initially, the limited color depth of most video hardware causes the color palette to be limited to 216 RGB colors, defined by the Netscape Color Cube. With 24-bit screen dominance, the full use of 16.7 million color RGB HTML color codes is no longer a problem for most viewers.
The web-safe color palette consists of 216 (6 3 ) combinations of red, green, and blue in which each color can take one of six values ââ(in hexadecimal): # 00, # 33, # 66 , # 99, #CC or #FF (based on the range 0 to 255 for each value discussed above). This hexadecimal value = 0, 51, 102, 153, 204, 255 in decimal, which = 0%, 20%, 40%, 60%, 80%, 100% in terms of intensity. It seems to be good to separate 216 colors into a 6 dimensional cube. However, without gamma correction, the intensity felt at the standard 2.5 gamma CRT/LCD is simply: 0%, 2%, 10%, 28%, 57%, 100%. Check out the actual web safe color palette for visual confirmation that most of the resulting colors are very dark or see the Xona.com Color List for comparison side by side with the right color on the side that is equivalent to a less precise gamma correction.
The syntax in CSS is:
rgb (#, #, #)
where # equals the proportions of red, green, and blue respectively. This syntax can be used after a selector such as "background color:" or (for text) "color:".
Color management
Proper color reproduction, especially in professional environments, requires the color management of all devices involved in the production process, many of which use RGB. Color management produces multiple transparent conversions between device-dependent and device-dependent color spaces (RGB and others, such as CMYK for color printing) during typical production cycles, to ensure color consistency throughout the process. Along with creative processing, such interventions on digital images can undermine color accuracy and image detail, especially where overall is reduced. Digital devices and professional software allow 48 bpp (bits per pixel) images to be manipulated (16 bits per channel), to minimize such damage.
ICC-compliant apps, such as Adobe Photoshop, use the Lab color space or CIE 1931 color space as the Profile Connection Room when translating between color spaces.
RGB model and luminance-chrominance format
All luminance-chrominance formats are used in various TV and video standards such as YIQ for NTSC, YUV for PAL, YD B D R for SECAM, and YP B P R for the video component uses a color difference signal, where RGB color images can be encoded for broadcast/recording and then translated again to RGB to display it. This intermediate format is required for compatibility with pre-existing black and white TV formats. Also, color difference signals require lower data bandwidth compared to full RGB signals.
Similarly, today's high-efficiency color scheme color compression data schemes such as JPEG and MPEG store RGB colors internally in YC B C R format, chrome-based digital lighting formats based on YP B P R . The use of YC B C R also allows the computer to do a lossy subsampling with a chroma channel (usually to a 4: 2: 2 or 4: 1: 1 ratio), which reduces the file size resulting from.
See also
- Color theory
- The color line
- List of color palettes
- RG color space
- RGBA color space
- sRGB
- scRGB
- Adobe RGB color space
- ProPhoto RGB color space
References
External links
- HEX to RGB conversion
- RGB to HEX conversion
- The demonstrative color conversion applet
- RGB color code
- The Difference Between CMYK and RGB in Digital Printing
Source of the article : Wikipedia