Color models. What are they and why do you need to know about them? About color spaces

The RGB model describes the colors emitted. It is based on three primary (basic) colors: red (Red), green (Green) and blue (Blue). The RGB model can be called “native” for the display. The remaining colors are obtained by combining the basic ones. This type of color is called additive.

From the figure it can be seen that the combination of green and red produces yellow, the combination of green and blue produces cyan, and the combination of all three colors produces white. From this we can conclude that colors in RGB are added subtractively.

Primary colors are taken from human biology. That is, these colors are based on the physiological reaction of the human eye to light. The human eye has photoreceptor cells that respond to the most green (M), yellow-green (L) and blue-violet (S) light (maximum wavelengths of 534 nm, 564 nm and 420 nm, respectively). The human brain can easily distinguish a wide range of different colors based on differences in the signals received from the three waves.

The most widely used RGB color model is in LCD or plasma displays, such as a TV or computer monitor. Each pixel on a display can be represented in a hardware interface (such as graphics cards) as red, green, and blue values. RGB values ​​vary in intensity, which are used for clarity. Cameras and scanners also work in the same way, they capture color with sensors that record different RGB intensities at each pixel.

In 16 bits per pixel mode, also known as Highcolor, there are either 5 bits per color (often referred to as 555 mode) or with an extra bit for green (known as 565 mode). The color green is added due to the fact that the human eye has the ability to detect more shades of green than any other color.

RGB values, represented in 24 bits per pixel (bpp) mode, also known as Truecolor, typically have three integer values ​​between 0 and 255. Each of these three numbers represents the intensity of red, green, and blue, respectively.

RGB has three channels: red, blue and green, i.e. RGB is a three-channel color model. Each channel can take values ​​from 0 to 255 in decimal or, more realistically, from 0 to FF in hexadecimal. This is explained by the fact that the byte with which the channel is encoded, and indeed any byte, consists of eight bits, and a bit can take 2 values ​​0 or 1, for a total of 28=256. In RGB, for example, red can have 256 gradations: from pure red (FF) to black (00). Thus, it is easy to calculate that the RGB model contains only 2563 or 16777216 colors.

RGB has three channels, and each is encoded with 8 bits. The maximum value, FF (or 255), gives a pure color. White color is obtained by combining all colors, or rather, their extreme gradations. White color code = FF(red) + FF(green) + FF(blue). Accordingly, black code = 000000. Yellow code = FFFF00, magenta = FF00FF, cyan = 00FFFF.

There are also 32 and 48 bit color display modes.

RGB is not used for printing on paper; instead, there is a CMYK color space.

CMYK is a color model used in color printing. A color model is a mathematical model for describing colors using integers. The CMYK model is based on cyan, magenta, yellow and black.

Why are different color models needed and why the same color can look different

Providing design services both in the field of web and in the field of printing, we often come across a question from the Client: why do the same corporate colors in the design layout of the website and in the design layout of printed products look different? The answer to this question lies in the differences between color models: digital and printed.

The color of a computer screen varies from black (no color) to white (the maximum brightness of all components of color: red, green and blue). On paper, on the contrary, the absence of color corresponds to white, and the mixing of the maximum number of colors corresponds to dark brown, which is perceived as black.

Therefore, when preparing for printing, the image must be converted from additive ("folding") flower models RGB into subtractive (“subtractive”) CMYK model. The CMYK model uses the opposite colors of the original colors - the opposite of red is cyan, the opposite of green is magenta, and the opposite of blue is yellow.

Digital RGB color model

What is RGB?

The abbreviation RGB means the names of three colors used to display a color image on the screen: Red (red), Green (green), Blue (blue).

How is RGB color formed?

The color on the monitor screen is formed by combining rays of three primary colors - red, green and blue. If the intensity of each of them reaches 100%, then the color white is obtained. The absence of all three colors produces black.

Thus, any color that we see on the screen can be described by three numbers indicating the brightness of the red, green and blue color components in the digital range from 0 to 255. Graphics programs allow you to combine the required RGB color from 256 shades of red, 256 shades of green and 256 shades of blue. The total is 256 x 256 x 256 = 16.7 million colors.

Where are RGB images used?

RGB images are used to display on a monitor screen. When creating colors for viewing in browsers, the same RGB color model is used as a basis.

Printing color model CMYK

What is CMYK?

The CMYK system is created and used for typographic printing. The abbreviation CMYK stands for the names of the primary inks used for four-color printing: cyan (Cyan), magenta (Magenta) and yellow (Yellow). The letter K stands for black ink (BlacK), which allows you to achieve a rich black color when printing. The last letter of the word is used, not the first, to avoid confusion between Black and Blue.

How is CMYK color formed?

Each of the numbers that define a color in CMYK represents the percentage of paint of that color that makes up the color combination. For example, to obtain a dark orange color, you would mix 30% cyan paint, 45% magenta paint, 80% yellow paint and 5% black paint. This can be expressed as follows: (30/45/80/5).

Where are CMYK images used?

The scope of application of the CMYK color model is full-color printing. It is this model that most printing devices work with. Due to color model mismatches, there is often a situation where the color you want to print cannot be reproduced using the CMYK model (for example, gold or silver).

In this case, Pantone inks are used (ready-made mixed inks of many colors and shades), they are also called spot inks (since these inks are not mixed during printing, but are opaque).

All files intended for printing must be converted to CMYK. This process is called color separation. RGB covers a larger color range than CMYK, and this must be taken into account when creating images that you later plan to print on a printer or printing house.

When viewing a CMYK image on a monitor screen, the same colors may appear slightly differently than when viewing an RGB image. The CMYK model cannot display the very bright colors of the RGB model; the RGB model, in turn, is not able to convey the dark, dense shades of the CMYK model, since the nature of the color is different.

The color display on your monitor screen changes frequently and depends on lighting conditions, monitor temperature, and the color of surrounding objects. In addition, many colors seen in real life cannot be output when printed, not all colors displayed on screen can be printed, and some print colors are not visible on a monitor screen.

Thus, when preparing a company logo for publication on the website, we use the RGB model. When preparing the same logo for printing in a printing house (for example, on business cards or letterhead), we use a CMYK model, and the colors of this model on the screen may be visually slightly different from those we see in RGB. There is no need to be afraid of this: after all, on paper, the colors of the logo will closely match the colors that we see on the screen.

Send your good work in the knowledge base is simple. Use the form below

Students, graduate students, young scientists who use the knowledge base in their studies and work will be very grateful to you.

Posted on http://www.allbest.ru/

Color models and their types

The science of color is a rather complex and wide-ranging science, so from time to time various color models are created in it, used in one area or another. One of these models is the color wheel.

Many people know that there are 3 primary colors that cannot be obtained and which form all the others. The primary colors are yellow, red and blue. Mixing yellow with red produces orange, blue with yellow produces green, and red and blue produces purple. In this way, you can create a circle that will contain all the colors. It is shown in Fig. and is called Oswald's great circle.

Along with the Oswald circle, there is also a Goethe circle, in which the primary colors are located at the corners of an equilateral triangle, and the additional colors are located at the corners of an inverted triangle.

Contrasting colors are located opposite each other.

Different mathematical models are used to describe emitted and reflected color - color mODelhi ( color space), i.e. is a way of describing color using quantitative characteristics. Color models can be hardware dependent(they are the majority so far, RGB and CMYK are among them) and hardware independent(Lab model). Most "modern" rendering packages (such as Photoshop) allow you to convert an image from one color model to another.

In a color model (space), each color can be assigned a strictly defined point. In this case, a color model is simply a simplified geometric representation based on a system of coordinate axes and an accepted scale.

Main color models:

CMY (Cyan Magenta Yellow);

CMYK (Cyan Magenta Yellow Key, with Key meaning black);

HSV (Hue, Saturation, Value);

HLS (Hue, Lightness, Saturation);

and others.

In digital technologies, at least four main models are used: RGB, CMYK, HSB in various versions and Lab. Numerous spot color libraries are also used in printing.

The colors of one model are complementary to the colors of another model. Complementary color is the color that complements the given one to white. Additional for red is cyan (green+blue), additional for green is magenta (red+blue), additional for blue is yellow (red+green), etc.

Based on the principle of operation, the listed color models can be divided into three classes:

additive (RGB), based on the addition of colors;

subtractive (CMY, CMYK), which are based on the operation of color subtraction (subtractive synthesis);

perceptual (HSB, HLS, LAB, YCC), based on perception.

Additive color is obtained based on Grassmann's laws by combining rays of light of different colors. This phenomenon is based on the fact that most colors in the visible spectrum can be obtained by mixing the three primary color components in varying proportions. These components, which in color theory are sometimes called primary The colors are Red, Green and Blue. When primary colors are mixed in pairs, secondary colors: blue (Cyan), purple (Magenta) and yellow (Yellow). It should be noted that primary and secondary colors refer to basic flowers.

Basic colors are colors that can be used to obtain almost the entire spectrum of visible colors.

To obtain new colors using additive synthesis, you can also use various combinations of two primary colors, varying the composition of which leads to a change in the resulting color.

Thus, color models (color space) provide a means for conceptually and quantitatively describing color. A color mode is a way of implementing a specific color model within a specific graphics program.

Grassmann's law (laws of color mixing)

Most color models use a three-dimensional coordinate system to describe color. It forms a color space in which color can be represented as a point with three coordinates. To operate with color in three-dimensional space, T. Grassmann derived three laws (1853):

1. Color is three-dimensional - three components are needed to describe it. Any four colors are linearly related, although there are an unlimited number of linearly independent sets of three colors.

In other words, for any given color it is possible to write down a color equation that expresses the linear dependence of colors.

The first law can be interpreted in a broader sense, namely, in the sense of the three-dimensionality of color. It is not necessary to use a mixture of other colors to describe a color; you can use other quantities - but there must be three of them.

2. If in a mixture of three color components one changes continuously, while the other two remain constant, the color of the mixture also changes continuously.

3. The color of the mixture depends only on the colors of the components being mixed and does not depend on their spectral compositions.

The meaning of the third law becomes clearer if we consider that the same color (including the color of the mixed components) can be obtained in different ways. For example, a component to be mixed can be obtained, in turn, by mixing other components.

RGB color model

This is one of the most common and frequently used models. It is used in devices that emit light, such as monitors, spotlights, filters and other similar devices.

This color model is based on three primary colors: Red - red, Green - green and Blue - blue. Each of the above components can vary from 0 to 255, forming different colors and thus providing access to all 16 million (the total number of colors represented by this model is 256 * 256 * 256 = 16,777,216.).

This model is additive. The word additive (addition) emphasizes that color is obtained by adding points of three basic colors, each with its own brightness. The brightness of each base color can take values ​​from 0 to 255 (256 values), so the model can encode 256 3 or about 16.7 million colors. These triplets of base points (luminous points) are located very close to each other, so that each triple merges for us into a large point of a certain color. The brighter the color dot (red, green, blue), the more of that color will be added to the resulting (triple) dot.

When working with the Adobe PhotoShop graphic editor, we can choose a color, relying not only on what we see, but, if necessary, specify a digital value, thereby sometimes, especially when color correction, controlling the work process.

Table. The meanings of some colors in the RGB model

This color model is considered additive, that is, when increasing iRthe bones of individual components will increase and the brightness of the resultYugood color: If you mix all three colors with maximum intensity, the result will be white; on the contrary, in the absence of all colors the result is black.

The model is hardware-dependent, since the values ​​of the basic colors (as well as the white point) are determined by the quality of the phosphor used in the monitor. As a result, the same image looks different on different monitors.

Rice. RGB model

The RGB coordinate system is a cube with a reference point (0,0,0), corresponding to the color black (see figure). The maximum RGB value is (1,1,1) corresponding to white.

Rice. RGB model color cube

The undoubted advantages of this mode are that it allows you to work with all 16 million colors, but the disadvantage is that when the image is printed, some of these colors are lost, mainly the brightest and most saturated ones, and there is also a problem with blue colors.

The RGB model is an additive color model that is used in devices that work with light fluxes: scanners, monitors.

HSB color model

Here the capital letters do not correspond to any colors, but symbolize tone (color), saturation And brightness(Hue Saturation Brightness). Proposed in 1978. All colors are arranged in a circle, and each has its own degree, that is, there are a total of 360 options - H determines the frequency of light and takes a value from 0 to 360 degrees (red - 0, yellow - 60, green - 120 degrees, and so on), i.e. any color in it is determined by its color (tone), saturation (that is, the addition of white paint to it) and brightness.

Saturation determines how pronounced the selected color will be. 0 - gray, 100 - the brightest and cleanest possible option.

The brightness parameter corresponds to the generally accepted one, that is, 0 is black.

This color model is much poorer than the previously discussed RGB, since it allows you to work with only 3 million colors.

This model is hardware-dependent and does not correspond to the perception of the human eye, since the eye perceives spectral colors as colors with different brightness (blue appears darker than red), and in the HSB model they are all assigned a brightness of 100%.

Saturation(Saturation) is a color parameter that determines its purity. The absence of (gray) impurities (purity of the curve) corresponds to this parameter. Reducing color saturation means whitening it. As the saturation decreases, the color becomes pastel, faded, and blurry. On the model, all equally saturated colors are located on concentric circles, that is, we can talk about the same saturation, for example, of green and purple colors, and the closer to the center of the circle, the more and more bleached the colors are. In the very center, any color is whitened as much as possible, in other words, it becomes white.

Working with saturation can be characterized as adding a certain percentage of white paint to the spectral color. The more white content in a color, the lower the saturation value, the more faded it becomes.

Brightness Brightness is a color parameter that determines the brightness or darkness of a color. The amplitude (height) of the light wave corresponds to this parameter. Reducing the brightness of a color means turning it black. Working with brightness can be characterized as adding a certain percentage of black paint to the spectral color. The more black content in a color, the lower the brightness, the darker the color becomes.

The HSB model is a custom color model that allows you to select color in the traditional way.

Model CMY (Cyan Magenta Yellow)

In this model, primary colors are formed by subtracting the primary additive colors of the RGB model from white.

Rice. Getting a CMY model from RGB

Colors that use white light by subtracting certain parts of the spectrum from it are called subtractive. The primary colors of this model are cyan (white minus red), magenta (called magenta in some books) (white minus green) and yellow (white minus blue). These colors are a printing triad and can be easily reproduced by printing machines. When mixing two subtractive colors, the result is darkened (in the RGB model it was the other way around). When all components are set to zero, white color (white paper) is formed. This model represents the reflected color and is called the model subtractive primary colors. This model is basic for printing and is also hardware-dependent.

Rice. CMY model

The CMY coordinate system is the same cube as for RGB, but with the origin at the point with RGB coordinates (1,1,1), corresponding to the color white. The color cube of the CMY model is shown in Fig. 0.4.2.

Rice. 0.4.2: CMY color cube

CMYK color model

This is another one of the most commonly used color models that have found wide application. It, unlike additive RGB, is a subtractive model.

Model CMYK(Cyan Magenta Yellow Key, with Key meaning black) - is a further improvement on the CMY model and is already four-channel. Because real printing inks contain impurities, their colors do not exactly match the theoretically calculated cyan, yellow, and magenta. It is especially difficult to obtain black from these paints. Therefore, in the CMYK model, black is added to the triad. For some reason, in the name of the color model, black is encrypted as K (from the word Key). The CMYK model is "empirical", as opposed to the theoretical CMY and RGB models. The model is hardware dependent.

The primary colors in the subtractive model are different from the colors in the additive model. Cyan - blue, Magenta - purple, Yellow - yellow. Since mixing all of the above colors will not produce perfect black, another additional color is introduced - black, which allows you to achieve greater depth and is used when printing other black objects (such as ordinary text).

The colors in the color model under consideration were not chosen by chance, but because cyan absorbs only red, magenta absorbs green, and yellow absorbs blue.

Unlike the additive model, where the absence of color components forms a black color, in the subtractive model the opposite is true: if there are no individual components, then the color is white, if they are all present, then a dirty brown is formed, which is made darker by adding the black paint that is used for darkening and other resulting colors. When mixing individual color components you can get the following results:

Cyan + Magenta= Blue with a hint of purple, which can be enhanced by changing the proportions of the colors mixed.

Magenta + Yellow= Red. Depending on the ratio of its constituents, it can be transformed into orange or pink.

Yellow + Blue= Green, which can be transformed using the same primary colors into either light green or emerald.

It is worth remembering that if you are preparing an image for printing, you should still work with CMYK, because otherwise what you see on the monitor and what you get on paper will differ so much that the entire work may go down the drain.

The CMYK model is a subtractive color model that describes real dyes used in the printing industry.

Lab color model

The Lab color model was developed by the International Commission on Illumination (CIE) in order to overcome the significant shortcomings of the above models; in particular, it is designed to become a hardware-independent model and determine colors without regard to the features of the device (scanner, monitor, printer, printing press, etc.). ).

This model is mainly preferred by professionals, since it combines the advantages of both CMYK and RGB, namely, it provides access to all colors, working at a fairly high speed.

To the question why such a model is used mainly by professionals, one can only answer that it has a somewhat unusual and unusual structure, and understanding the principle of its operation is sometimes somewhat more difficult than those described earlier.

The construction of colors here, as in RGB, is based on the fusion of three channels. This, however, is where all the similarities end.

It got its name from its basic components L, a And b. Component L carries information about the brightness of the image, and the components A And b- about its colors (i.e. a And b- chromatic components). Component A changes from green to red, and b- from blue to yellow. Brightness in this model is separated from color, which is convenient for adjusting contrast, sharpness, etc. However, being abstract and highly mathematical, this model remains inconvenient for practical work.

Since all color models are mathematical, they are easily converted from one to another using simple formulas. Such converters are built into all “decent” graphics programs.

Perceptual color models

For designers, artists and photographers, the main tool for indicating and reproducing color is the eye. This natural “tool” has a color gamut that far exceeds the capabilities of any technical device, be it a scanner, printer or photographic film output device.

As was shown earlier, the RGB and CMYK color systems used to describe technical devices are device-dependent. This means that the color reproduced or created using them is determined not only by the components of the model, but also depends on the characteristics of the output device.

To eliminate hardware dependence, a number of so-called perceptual (otherwise intuitive) color models were developed. They are based on a separate definition of brightness and color. This approach provides a number of advantages:

allows you to handle color on an intuitive level;

It greatly simplifies the problem of color matching because once the brightness value is set, you can start adjusting the color.

The prototype of all color models that use the concept of separating brightness and chromaticity is the HSV model. Other similar systems include HSI, HSB, HSL and YUV. What they have in common is that color is not specified as a mixture of the three primary colors - red, blue and green, but is determined by specifying two components: chromaticity (hue and saturation) and brightness.

Black and white and grayscale mode

Black and white mode. This is a regular black and white mode that is completely devoid of color, it only has white, black and grayscale. It’s impossible to say anything particularly new about this color model, since it consists of one channel that completely matches the image and looks like an ordinary black and white photograph.

Artists and software developers sometimes call this mode monochrome graphics, raster graphics, or monochrome graphics. bit resolution.

To display a black and white image, only two types of cells are used: black and white. Therefore, only 1 bit of computer memory is required to remember each pixel. Areas of the source image that have intermediate shades are assigned black or white pixels, since no other shades are provided for this model.

This mode can be used to work with black-and-white images obtained by scanning black-and-white drawings and engravings, and also sometimes when outputting color images to black-and-white printing.

Halftone mode. This method of image realization is based on the specifics of image perception by the human eye, for which the image area filled with large dots is associated with darker tones and, conversely, the area filled with smaller dots is perceived as lighter. Halftone mode is supported by most printers.

Halftone images are single-bit continuous tone images that are implemented using a conglomerate points different sizes and shapes.

Spot colors

Some types of printing products use only two or three colors, which are printed with mixed inks called spot colors. In particular, such products include forms, business cards, invitations, price lists and other display products. Each spot color is reproduced using a separate printing plate (solid).

To print such products, the designer must submit to the printing house separate strips of the original layouts with dies for each mixed color and registration crosses and attach color samples (“paintings”) for each strip.

In order to unify the use of such colors, color libraries are created.

In particular, the well-known company Pantone, which is the owner and developer of the library of the same name, began with the fact that the chemist Lawrence Herbert created a set of different colors made up of eight colors and printed an album of these colors, each of which had its own number. Since then, this idea has been widely developed; color libraries are used in a variety of fields, primarily in computer graphics and printing. Many other companies have emerged producing other standardized color libraries (e.g. TRUMATCH SWATCHING SYSTEM, FOCOLTONE COLOR SYSTEM, TOYO 88 ColorFinder1050 System and ANPA-COLOR system, etc.).

The Process Color System Guide covers more than 3,000 print colors, with percentage recipes for the 16 base colors in the CMYK color model.

Color coding. Palette

color model coding additive

In order for a computer to be able to work with color images, it is necessary to represent colors in the form of numbers - color encoding. The encoding method depends on the color model and numeric data format in the computer.

For the RGB model, each of the components can be represented by numbers limited to a certain range - for example, fractional numbers from 0 to 1 or integers from 0 to some maximum value. Currently, the True Color format is quite common, in which each component is represented as a byte, which gives 256 gradations for each component: R = 0...255, G = 0...255, B = 0...255 . The number of colors is 256x256 x 256 = 16.7 million (2 24).

This method of color coding can be called component . On a computer, True Color image codes are represented as triplets of bytes, or packed into a long integer (four bytes) - 32 bits.

When working with images in computer graphics systems, you often have to make a compromise between image quality (you need as many colors as possible) and the resources required to store and reproduce the image, calculated, for example, in memory capacity (you need to reduce the number of bits per pixel).

Additionally, a given image itself may only use a limited number of colors. For example, for drawing, two colors may be enough; for the human face, shades of pink, yellow, purple, red, green are important; and for the sky - shades of blue and gray. In these cases, using full color color coding is redundant.

When limiting the number of colors, use a palette , representing a set of colors that are important for a given image. A palette can be thought of as a table of colors. The palette establishes the relationship between the color code and its components in the selected color model.

Computer video systems usually provide the ability for the programmer to set his own palette.

Each color of an image using a palette is encoded with an index, which will determine the row number in the palette table. Therefore, this method of color coding is called index .

Posted on Allbest.ru

...

Similar documents

    Study of modern computer color manipulation programs. Study of color matching systems and color modes. Descriptions of the features of additive, subtractive and perceptual color models. Working with color in three-dimensional space.

    presentation, added 02/12/2014

    Consideration of the laws of mixing primary colors. Wave properties of light. The concept of hue, brightness and saturation. Characteristics of the essence of additive and subtractive models of color synthesis. Familiarization with formats for storing raster images in BMP files.

    presentation, added 07/26/2013

    A means of describing the color shades that can be reproduced on a computer screen and on a printer. System of additive and subtractive colors in computer graphics. Achromatic (black and white) image, tones, halftones and shades of gray.

    presentation, added 01/06/2014

    Study of the nature of color as a qualitative subjective characteristic of radiation in the optical range. Light and visual perception of color by humans. Purpose, description of models and structure of color profiles and spaces in computer graphics.

    course work, added 10/03/2011

    Converting "natural" information into discrete form. Analysis of image sampling and quantization processes. Vector and raster procedures used in computer graphics. Laws of mathematical description of color and types of color models.

    presentation, added 01/29/2016

    The history of the origin of the RGB color model. HiFi Color technology and the use of tablet colors. The appearance, mechanisms of color formation, possibilities for expanding the color gamut of the CMYK color model. Standard RGB color spaces.

    course work, added 09/20/2012

    Basic laws of color mixing. Wave properties of light. Basic characteristics of color (attributes). Additive RGB color model. CMY and HSV color models. Color coding in models. BMP format for storing raster images, file structure.

    presentation, added 08/28/2013

    The history of the origin of the RGB color model, its advantages and limitations. Standard RGB color spaces. The emergence of the CMY color model. Possibilities for expanding the CMYK color gamut. HiFi Color technology. Using spot colors.

    course work, added 11/07/2014

    Characteristics of digital images used in publishing. Distinctive features of raster and vector images, the concept of color gamut, study of models for describing reflected colors. Formats and types of graphic files.

    test, added 09/16/2010

    Development of a hardware and software complex for identifying control objects based on the real interpolation method. Analysis of the performance of the hardware and software complex, an example of identifying a control object.

Good day, dear readers, acquaintances, visitors, passing individuals and other strange creatures! Today we will talk about a slightly specific, but undoubtedly important thing for any user, namely this thing: the representation of color in a computer.

Whatever one may say, sooner or later everyone will be faced with the practical need to understand what a color model is, and simply this knowledge is useful from the point of view of broadening one’s horizons and awareness of what and how it works in a computer and what it consists of, both software and and from a physical point of view.

What is a color model

In general color model- this is some abstract thing in which color is represented as a collection of numbers. And each such model has its own characteristics and disadvantages. Essentially, it’s like with a language, for example, if a color is the word “house,” then in different languages ​​it will be written and sounded differently, but the meaning of the word will be the same everywhere. It's the same with color.

We will look at the most basic models. Their 5 . As a rule, several different models are used simultaneously, because some are best used visually, while others are best used numerically.

RGB

This is the most common color representation model. In it, any color is considered as shades of three primary (or basic) colors: red, green (Green) and blue (Blue). There are two types of this model: eight-bit representation where the color is specified by numbers from 0 before 255 (for example color will correspond to blue, and - yellow), and sixteen-bit, which is most often used in graphic editors and html, where the color is specified by numbers from 0 before ff(green - # 00ff00, blue - # 0000ff, yellow - # ffff00).

The difference in ideas is that in eight-bit form, a separate scale is used for each base color, and in sixteen-bit color is immediately introduced. In other words, eight-bit presentation - three scales with each primary color, sixteen-bit- one scale with three colors.

The peculiarity of this model is that here a new color is obtained by adding shades of primary colors, i.e. "mixing".

Do you want to know and be able to do more yourself?

We offer you training in the following areas: computers, programs, administration, servers, networks, website building, SEO and more. Find out the details now!

In the picture above you can see how the colors mix with each other to form new colors (yellow - [ 255,255,0 ], purple - [ 255,0,255 ], blue - [ 0,255,255 ] and white [ 255,255,255 ]).

Moreover, this model is most often used in numerical form, and not in visual form (when the color is set by entering its value in the corresponding field, and not selected with the mouse). Other models are used to visually adjust color. Because visually the model RGB is a three-dimensional cube, which, as you can see in the picture above, is not very convenient to use :)

So this is the most common model among web designers (we send our warm regards css) and programmers.

The disadvantage of this model is that it depends on the hardware, in other words, the same picture will look different on different monitors (because monitors use a so-called phosphor - a substance that converts the energy it absorbs into light radiation, and therefore Depending on the quality of this substance, the basic colors will be determined).

CMYK

This is also a very common model, but many may not have heard anything about it at all :)

And all due to the fact that it is used exclusively for printing. It stands for Cyan, Magenta, Yellow, Black(or Key Color), i.e. Cyan, Magenta, Yellow And Black(or key color).

The use of this model in printing is due to the fact that mixing three shades for each new color is too expensive and dirty, because when one color is first applied to paper, then another on top of it, and then a third color on top of them, firstly, the paper gets very wet (if inkjet printing), and secondly, it is not at all a fact that you will get exactly the shade that you wanted. Yes, that's how physics works :)

The most attentive may have noticed that there are three colors in the picture, and black is obtained by mixing these three. So, why was he taken out separately? Again, the reason is that, firstly, mixing three colors is expensive in terms of using toner (special powder for a printer cartridge, which is used instead of ink in laser printers), and secondly, the paper gets very wet, which increases drying time, thirdly, the colors may not actually mix properly, but may be more faded, for example. The picture below shows this model in reality

Thus, the result will not be black, but dirty gray or dirty brown.

That’s why (and not only) they introduced black color, so as not to stain the paper, not to spend money on toners, and in general to make life easier :)

The following animation very clearly illustrates the whole point (opens by clicking, weight approx. 14 Mb):

The color in this model is specified by numbers from 0 before 100 , where these numbers are often called "parts" or "portions" of the selected color. For example, khaki color is obtained by mixing 30 pieces of blue paint, 45 - purple, 80 - yellow and 5 - black, i.e. khaki color will be .

The difficulties of this model lie in the fact that in harsh realities (or in real harsh conditions) color depends not so much on numerical data as on the characteristics of the paper, the ink in the toner, the method of applying this ink, etc. So the numerical values ​​will clearly indicate the color on the monitor, but they will not show the actual picture on paper.

HSV (HSB) and HSL

I combined these two color models because... they are similar in principle.

3D implementation HSL(left) and HSV(on the right) of the models is presented in the form of a cylinder below, but in practice it is not used in software (software), because .. because it is three-dimensional :)

HSV (or HSB) means Hue, Saturation, Value(may also be called Brightness), Where:

  • Hue- color tone, i.e. color shade.
  • Saturation- saturation. The higher this parameter is, the “purer” the color will be, and the lower it is, the closer it will be to gray.
  • Value(Brightness) - value (brightness) of color. The higher the value, the brighter the color will be (but not whiter). And the lower, the darker (0% - black)

HSL - Hue, Saturation, Lightness

  • Hue- You already know
  • Saturation- similar
  • Lightness- this is the lightness of the color (not to be confused with brightness). The higher the parameter, the lighter the color (100% - white), and the lower, the darker (0% - black).

A more common model is HSV, it is often used together with the model RGB, Where HSV is shown visually, and numerical values ​​are specified in RGB. :

Here RGB- the model is circled in red and the shade values ​​are given by numbers from 0 before 255 , or you can immediately specify the color in hexadecimal form. And circled in blue HSV model (visual part in left rectangle, numeric - in right). You can also often specify opacity (called alpha channel).

This model is most often used in simple (or non-professional) image processing, because Using it, it’s convenient to adjust the basic parameters of photos without resorting to a bunch of different filters or individual settings.
For example, in everyone’s favorite (or cursed) Photoshop, both models are present, only one of them is in the color selection editor, and the other is in the settings window Hue/Saturation

Showing in red here RGB- model, blue - H.S.B., green - CMYK and blue Lab(more on her a little later), as can be seen in the picture :)
A HSL- The model is in a window like this:

Flaw HSB- model is that it also depends on the hardware. It simply does not correspond to the perception of the human eye, because... This model perceives colors with different brightness (for example, blue is perceived by us as darker than red), but in this model all colors have the same brightness. U HSL similar problems :)

They wanted to avoid such shortcomings, so one well-known company CIE(International Illumination Commission - Commission Internationale de l'Eclairage) came up with a new model designed to be independent of hardware. And they named her Lab(no, this is not an abbreviation for Laboratory).

Lab or L,a,b

This model is one of the standard ones, although it is little known to the average user.

It is deciphered as follows:

  • L - Luminance- illumination (this is a combination of brightness and intensity)
  • a- one of the components of color, changes from green to red
  • b- the second of the color components, changes from blue to yellow

The figure shows the component ranges a And b For illumination 25% (left) and 75% (right)

The brightness in this model is separated from the colors, so it is convenient to use it to adjust contrast, sharpness and other light indicators without touching the colors :)

However, this model is not at all obvious to use and is quite difficult to use in practice. Therefore, it is used mainly in image processing and for converting them from one color model to another without loss (yes, this is the only model that does this without loss), but for ordinary mortal suffering users, as a rule, it is enough HSL And HSV plus filters.

Well, as an example of how the model works HSV, HSL And Lab here is a picture from Wikipedia (clickable)

Lesson objectives:

  • Educational: Provide fundamental knowledge of the physical models of object color perception RGB and CMY(K). Explain the interaction of color coordinates of these models.
  • Developmental : develop the ability to present research results in a given format
  • Educational: develop the skills to independently complete a task, develop aesthetic taste, show a creative attitude to work

Lesson objectives:

  • Repeat: the purpose and main functions of a graphic editor, principles of image formation in raster and vector graphics
  • Learn to identify primary colors using color models
  • Check your understanding of the material. Analyze identified errors.

As a result of studying the topic, students should:

know:

  • physical models of object color perception RGB and CMY(K)
  • ratio of RGB and CMY models

be able to:

  • identify colors according to a given color scheme

Equipment: PC, PowerPoint program, multimedia projector, interactive whiteboard, handouts, presentation “Color Models”.

During the classes

Lesson Plan

  1. Organizational moment (2 min)
  2. Frontal survey (3 min)
  3. Explanation of new material (19 min)
  4. View presentation (8 min)
  5. Checking your understanding of the material (10 min)
  6. Summing up the lesson (1 min).
  7. Homework (2 min)

LESSON 45 min

1. Organizational moment ( 2 minutes).

  • Checking those present
  • Magazine design
  • Introducing students to the topic of the lesson

2. Frontal survey (3 min).

Students must answer the following questions:

a) appointment of a graphic editor

Graphics editor - a program (or software package) that allows you to create and edit images using a computer.

b) principles of image formation in raster and vector graphics

In raster graphics, an image is represented by a two-dimensional array of dots (raster elements), the color and brightness of each of which is set independently. Pixel is the basic element of all raster images. Vector graphics describe an image using mathematical formulas.

c) Explanation of new material ( 19 min )

Teacher: It is believed that our human eye is capable of distinguishing about 16 million shades of color. A natural question arises: how to explain to a computer that one object is red and the other is pink? What is the difference between them, so clearly visible to us by eye? To formally describe color, several color models and corresponding encoding methods have been invented.

Let's write down the definition in our notebook:

The method of dividing a color shade into its component components is called a color model.

Today we will look at the RGB and CMY(K) models.

Copy this in your notebook.

RGB color model(abbreviation of English words R ed, G reen, B lue - red, green, blue) - additive color model.

Is used for emitted light , i.e. when preparing screen documents.

The choice of primary colors is determined by the physiology of color perception by the retina of the human eye.

Any color can be represented as a combination of 3 primary colors R ed (red), G reen (green), B lue (blue). These colors are called color components.

Additive the model is called because the colors are obtained by adding (English addition) to black.

Write down the primary colors in your notebook. (Students copy the material from the board)

Teacher: The word additive (addition) emphasizes that color is obtained by adding points of three basic colors, each with its own brightness. The brightness of each base color can take values ​​from 0 to 255 (256 values), so the model can encode 2563 or about 16.7 million colors. These triplets of base points (luminous points) are located very close to each other, so that each triple merges for us into a large point of a certain color. The brighter the color dot (red, green, blue), the more of that color will be added to the resulting (triple) dot.

Look at the board and the material given.

The RGB model is displayed on the interactive board (a similar diagram is in the handout for each student). The teacher continues to explain and shows on the diagram.

The image in this color model consists of three channels.

  • Pure red can be defined as (255,0,0) - R ed
  • Pure green (0.255.0) - G reen
  • Pure bright blue color (0,0,255) – B lue

In the diagram you see that when mixing primary colors (the primary colors are red, green and blue), we get

  • when blue (B) and red (R) are mixed, we get purple or lilac (M magenta)
  • when mixing green (G) and red (R) - yellow (Y yellow)
  • when mixing green (G) and blue (B) - cyan (C cyan)
  • when mixing all three color components we get white color (W)
  • If the brightness of all three basic colors is minimal (equal to zero), it turns out black dot (Black - (0,0,0))
  • If the brightness of all three colors is maximum (255), adding them together gives white dot (White - (255,255,255)
  • If the brightness of each base color is the same, we get gray dot (the higher the brightness value, the brighter).

A dot of some beautiful, rich color is obtained when mixing one (or two) colors is much less than two (one) others. For example, the color lilac is obtained if we take the maximum of red and blue colors and we won't take the green one , and yellow color is achieved by mixing red and green.

Graphic information input devices (scanner, digital camera) and output devices (monitor) work in this model.

Color model RGB has a wider color gamut in many tones (can represent richer colors) than the typical CMYK color gamut, so sometimes images that look great in RGB will fade significantly and fade out in the CMYK model we'll look at now.

Color model CMY ( K)

Colored, non-luminous objects absorb part of the white light spectrum that illuminates them and reflect the remaining radiation. Depending on the region of the spectrum in which absorption occurs, objects reflect (are colored in) different colors.

The name of the model and basic colors are already written on the board.

CMY ( K )
C yan M agenta Y ellow Black K
Cyan Magenta Yellow Black

Copy this in your notebook.

Colors that use white light by subtracting certain parts of the spectrum from it are called subtractive ("subtractive") . To describe them it is used subtractive model CMY (C is Cyan, M is Magenta, Y is Yellow). In this model, primary colors are formed by subtracting the primary additive colors of the RGB model from white.

If we subtract the three RGB primary colors from white, we get the three complementary CMY colors.

In this case, there will be three main subtractive colors:

  • blue (white minus red)
  • magenta (white minus green)
  • yellow (white minus blue)

Color model CMY ( K ) used when working with reflected color (when printing) .

When two subtractive (subtractive) components are mixed, the resulting color is darkened (more light is absorbed, more paint is applied). Thus:

  • when mixing the maximum values ​​of all three components, the color should be black
  • in the complete absence of paint (zero values ​​of the components), the result will be white (white paper)
  • shifting equal values ​​of the three components will produce shades of gray.

This model is the main printing model. Purple, cyan, yellow colors make up the so-called printing triad , and when printed with these inks, most of the visible color spectrum can be reproduced on paper.

However, real paints have impurities, their color may not be ideal, and a mixture of three primary colors that should produce black results instead in a vague dirty brown (look at the material issued). In addition, to obtain intense blacks, you need to put a large amount of each color of paint on the paper. This will cause the paper to become waterlogged and print quality will decrease. In addition, using a large amount of paint is uneconomical.

To improve the quality of the print, add basic printing inks (and model) added black paint. It was she who added the last letter to the name of the CMYK model, although not quite usually. The black component is abbreviated to the letter K, since this paint is the main, key ( K ey) in the process of color printing (or blac K).

As with the RGB model, the amount of each component can be expressed as a percentage or in gradations from 0 to 255.

Printing with four colors corresponding to CMYK is also called printing process colors.

Color in CMYK depends not only on the spectral characteristics of the dyes and the method of their application, but also on their quantity, paper characteristics and other factors. In fact, CMYK numbers are just a set of hardware data for the phototypesetting machine and do not uniquely define color.

Color circle

When processing images, it is necessary to clearly understand the interaction of color coordinates of the additive RGB system and the subtractive CMYK system. Without knowledge of these patterns, it is difficult to assess the quality of color, prescribe corrective operations, and it is simply wise to use the simplest tools designed to work with color.

If these two models are represented in the form unified model , then it will work out truncated a variant of the color wheel in which the colors are located in the order known from school (only without the derivative orange color): red (R), yellow (Y), green (G), cyan (C), blue (B) - purple (lilac , purple) M - Magenta

EVERY HUNTER WANTS TO KNOW WHERE THE PHEASANT SITS
or
HOW ONE DAY JEAN THE BELLER KNOPPED A LANTERN WITH HIS HEAD
or
EVERY DESIGNER WANTS TO KNOW WHERE TO DOWNLOAD PHOTOSHOP

Let's consider the simplest and most popular model, called the color wheel. It contains the coordinates of the main color systems RGB and CMYK at the same distance from each other.

Pairs of flowers located at the ends of the same diameter (at an angle of 180 degrees) are called
On the color wheel, the primary colors of the RGB and CMY models are in the following relationship: each color is located opposite its complementary color; at the same time it is at an equal distance between the colors with which it is obtained.

Complimentary colors are:

  • green and purple,
  • blue and yellow,
  • blue and red.

Complementary colors are in some ways mutually exclusive. Adding any paint on the color wheel compensates for the additional paint, as if diluting it in the resulting color.

For example, to change the color ratio towards green tones, you should reduce the content of magenta, which is complementary to green.

This statement can be expressed in the form of the following brief formulas:

The teacher writes on the board:

Now write down the remaining 5 formulas in your notebook:

100%Magenta = 0Green

100%Yellow = 0Blue

0%Magenta = 255Green

0%Yellow = 255Blue.

Listen and write down the following sentence in your notebook:

Cyan is the opposite color of red because cyan dyes absorb red and reflect blue and green. Blue is the absence of red.

The teacher asks 5 students to change the wording of the sentence for the remaining 5 colors.

Here is a summary of the basic and derivative rules of color synthesis using the circular model (see handout):

  • Each subtractive (additive) color is located between two additive (subtractive) ones.
  • Adding any two RGB (CMY) colors produces the CMY (RGB) color that lies between them. For example, mixing green and blue produces cyan, and mixing yellow and magenta produces red.

Write down in your notebook all possible relationships of this type (6 formulas)

Red + Green = Yellow

Blue + Green = Cyan

Red + Blue = Magenta

Cyan+ Magenta = Blue

Cyan + Yellow = Green

Magenta + Yellow = Red.

  • Superimposing red and green at maximum intensity produces pure yellow. Decreasing the intensity of red shifts the resultant towards green hues, and reducing the contribution of green makes the color orange.
  • Mixing blue and red in maximum proportions gives the color violet. Decreasing blue shifts the color toward pink, while decreasing red shifts the color toward purple.
  • Green and blue colors form cyan. There are about 65 thousand different shades of blue that can be synthesized by mixing these color coordinates in different proportions.
  • Layering cyan and magenta inks at maximum density produces a deep blue color.
  • Purple and yellow dyes produce red. The higher the density of the components, the higher its brightness. Reducing the intensity of magenta gives the color an orange tint, reducing the proportion of the yellow component gives a pink color; Yellow and blue produce a bright green color. A decrease in the share of yellow gives rise to emerald, and a decrease in the contribution of blue gives rise to light green.
  • Lightening or darkening a color of extreme saturation entails a decrease in its saturation.

Let's write in our notebook:

The color attachment can be increased and decreased by adjusting its inputs complimentary colors or adjacent colors.

4. View the presentation ( 8 min)

Now we will watch the presentation to consolidate the material we have covered and find out what awaits us in the next lessons.

5. Checking the mastery of the material ( 10 min)

Please answer questions on a new topic:

1. List the basic colors of the RGB and CMY(K) models.

  • RGB color model - Red, Green, Blue - red, green, blue
  • Color model CMY- C is Cyan (Blue), M is Magenta (Purple), Y is Yellow (Yellow)

2. What color model is used for the emitted color?

3. Why is it called additive?

The additive model is called because colors are obtained by adding (English addition) to black

4. What does the letter K mean in the CMYK color model?

The black component, since this paint is the main, key ( K ey) in the color printing process (or blac K).

5. What is the color wheel model used for?

To understand the interaction of color coordinates between the additive RGB system and the subtractive CMYK system.

6. What colors are called complementary?

Pairs of colors located at ends of the same diameter on the color wheel (at an angle of 180 degrees) are called complimentary or additional.

  • List complimentary colors.
  • green and purple
  • blue and yellow
  • blue and red.

6. Summing up the lesson ( 1 min).

Our lesson is coming to an end. Today you learned about the RGB and CMY(K) color models, the base colors of these models, the interaction of color coordinates of the additive RGB system and the subtractive CMYK system. We will continue our acquaintance with color models in the next lesson.

7. Homework ( 2 minutes)

Write down your homework:

  1. Using the Color Wheel model, repeat the basic formulas for obtaining color
  2. Profile school “Text information processing technology. Technology for processing graphic and multimedia information” A.V. Mogilev, L.V. Listratova St. Petersburg: BHV-Petersburg, 2010 p. 8.2.
  3. Computer graphics lessons. CorelDRAW. Training course L. Levkovets St. Petersburg: Peter, 2006 level 2