Color palettes in rgb cmyk color systems. Color models CMYK and RGB in computer graphics. Color palettes in RGB, CMYK and HSB color systems

Look around, what do you see? You see objects, table, chair, sun or sea. Have you ever wondered how all this diversity is perceived? Light is electromagnetic radiation, it is a wave that propagates in space, just like sound and other waves that we do not feel.

In the process of perception and processing, two sides are involved, the object we are looking at and the human eye itself, as well as the brain, which processes the information received through the eyes.

Let's see how we see color. In the retina of the human eye, there are cone and rod receptors. There are about 130 million rods and 7 million cones in the eye. The distribution of receptors on the retina is uneven: cones predominate in the macular region, and there are very few rods; to the periphery of the retina, on the contrary, the number of cones decreases rapidly and only rods remain. The cones are responsible for the perception of color, the rods, in turn, are responsible for the twilight vision. For example, at night you do not see colors, you see everything in gray, because rods work, and during the day both cones and rods work.

How do the visual receptors work? Pigment Rhodopsin decomposes under the action of light in rods, in cones this role is played by the pigment Iodopsin.

Color models

A color model is a system for representing a wide range of colors andbased on the limited number of available inks in the printing industry or color channels in monitors).

According to the principle of operation, all color models are divided into four classes: additive, subtractive, perceptual and colorimetric, although the latter are often referred to as perceptual models. Let's consider them in more detail.

Additive color model (RGB)

Let's analyze the nature of color, starting from the physiology of vision. There are three types of "cones" that are most sensitive to the three primary colors of the visible spectrum:

Red-orange (600 - 700 nm);

Green (500 - 600 nm);

Blue (400 - 500 nm).

Thus, for the perception of any color, our brain mixes these three colors, taking into account one more parameter - the intensity

The considered class of color models is represented by the only model that has become widespread in practice. This model is based on the fact that most colors in the visible spectrum can be obtained by mixing three colors called primary. These colors are red (Red), green (Green) and blue (Blue) , and the model, respectively, was named RGB. When all three components are at their maximum value, a bright white color is obtained. The same zero values ​​form absolutely black color (more precisely, the absence of light), and the same non-zero values ​​correspond to the gray scale. Combinations of components, where their values ​​are not equal, form the corresponding color tone. In this case, the pairwise mixing of the primary colors forms secondary colors: cyan, magenta, and yellow. Primary and secondary colors refer to basic colors.

Mathematically, the RGB color model is most conveniently represented as a cube. In this case, each color can be uniquely associated with a point inside the cube, corresponding to the values ​​of the coordinates X (Red), Y (Green) and Z (Blue). Then the direction of the vector, outgoing from the origin, uniquely determines the chromaticity, and its modulus expresses the brightness. Despite the simplicity and clarity of the RGB color model, it has two significant drawbacks: hardware dependence (for example, the use of various phosphors and its elementary aging in monitors) and a limited color gamut (the impossibility of obtaining all colors of the visible spectrum).

Subtractive color models (CMY and CMYK)

How is the color of an object formed? The answer is simple, daylight, falling on an object, is partially absorbed and partially reflected, this is the reflected spectrum that our eye sees. The visible waves are in the range from 760 to 380 nanometers. The figure below shows the correspondence between color and its wavelength.

From this point of view, white is a color that reflects all light incident on it, and black that absorbs all light.

A subtractive color model is used to describe the color reflected from an object. Subtractive colors, as opposed to additive colors, are obtained by absorbing(subtraction - subtract) of one of the primary colors from white, which corresponds to the physics of the processes of absorption and reflection of light from the surface of an object:

White - red = blue;

White - Green = Magenta;

White - blue = yellow.

Thus, to describe these processes, the model is used CMY, which uses three main subtractive colors, namely Cyan, Magenta, and Yellow.

As a result, when two subtractive paints are mixed, the resulting color darkens (more paint is put - more light is absorbed). Mixing equal values ​​of the three components produces shades of gray. White color is obtained in the absence of all colors (absence of paint), while their presence in full in theory gives black color. However, in a real technological process, obtaining black by mixing three primary (secondary) colors on paper is not effective. And there are two reasons for this. First, it is nearly impossible to create perfectly clean magenta, cyan, and yellow paints. As a result, when these colors are mixed, it is not pure black, but a dirty brown. Secondly, the wasteful consumption of paints to create black, and this despite the fact that any color paints are more expensive than ordinary black ones.

As a result, in practice, another subtractive color model, called CMYK and using an additional, fourth, black paint. Note that the model name uses the letter K (the last letter in the word BlaK (black) ) to avoid confusion. the word Blue (blue) also begins with the letter B in English. Although sometimes the letter K is interpreted as the first letter in the word Key (key, key), since this ink is central to the color printing process and is the last ink to be applied to the paper.

The CMYK color model has the same limitations as the RGB model - hardware dependency and limited color range. Moreover, it is even more device-dependent and the color range is even narrower than that of the RGB model, since Colored dyes have inferior characteristics compared to phosphors in monitors. For example, it cannot reproduce bright saturated colors, as well as a number of specific colors such as metallic and gold.

Screen colors that cannot be reproduced in print are said to be outside the gamut of the CMYK model. To prevent such situations, a set of special measures is usually used, including identifying and eliminating (replacing close ones) inappropriate colors at the stage of creating and editing images or expanding the color gamut of the model by adding new or spot colors (spot colors are called colors or paints created using special technologies and based on the use of unique dyes or inks for each color). For example, green and orange inks are added to CMYK inks (six-color printing), which significantly expands the range of reproducible colors. Another way, perhaps the most effective, is through the use of color management systems - CMS (color management system).

Perceptual color models (HSB and others)

To eliminate the hardware dependency present in additive and subtractive color models, a number of perceptual (intuitive) color models have been developed, which are based on the separate perception of chromaticity and
the brightness of light, as perceived by the human eye. The prototype for most color models using this idea is the HSV model, which later evolved into HSB, HSL and other models. What they have in common is that the color in them is not specified as a mixture of three primary colors, but by specifying two components (for example, in the model HSB it's Hue, and Saturation). The third parameter in all these models sets the brightness of the image in various ways and is denoted as B (Brightness - in HSB model), L (Lightness - in HSL) or V (Value - in HSV).

The HSB model or its closest analogue - HSL - is presented in most modern graphic editors. And it is the HSB model, also presented in Photoshop, that most closely matches the way the human eye perceives colors (from the models already considered), and we will consider it in more detail.

Hue (Hue) refers to light with a dominant wavelength and is usually described using the actual color name, for example, blue or yellow. In the graphic interpretation of this model, each color occupies a certain place on the circle and is described by an angle in the range of 0-60. At position 0 is red, 120 is green, 240 is blue (these are the primary colors). Secondary colors are in between. Complementary colors are found on diametrically opposite sides of the color wheel. When they are mixed, black (when printing with inks) or white (when emitting on the monitor) is formed. These are the most contrasting colors and they irritate the eye.

The colors, equidistant from each other, form triads, giving a harmonious combination of colors and a palette rich in shades. However, the concept of hue does not provide a complete description of color. In addition to the dominant wavelength, other wavelengths are involved in the formation of color. The relationship between the main, dominant wavelength and all other wavelengths that form "gray blotches" is called saturation. Its value ranges from 0% (gray) at the center of the circle to 100% (fully saturated) at the circle.

The third parameter - brightness - does not in any way affect the chromaticity, but it depends on how strongly the color will be perceived by the eye, i.e. brightness characterizes the intensity with which light energy acts on the receptors in the eye. At zero brightness, we will not see anything, and any color will be perceived as black, and at maximum brightness, it gives the impression of dazzling white. The brightness value is also measured as a percentage from 0e (black) to 100 (white). This component is non-linear, which corresponds to the nature of the eye.

The HSB model is abstract because its components cannot be measured in practice. Most often, the components of the model are obtained by mathematical recalculation of the measured values ​​of the RGB model. As a result, it also inherits a limited color space from the RGB model. In addition, brightness and hue are not completely independent parameters, since a significant change in brightness affects the change in color tone, which leads to undesirable effects in the form of color tints (shifts). However, the HSB model has two important advantages: greater hardware independence (compared to the previous two models) and a simpler and more intuitive color management mechanism.

Before we go directly to the description of color models of computer graphics, let's discuss a little the basic concepts of COLOR. And in the video you can see where to find and how to change the color model in Photoshop.

  • How do we perceive color?

Before we move on to the CMYK and RGB color palettes, let's understand how we perceive color. We can see objects only because they emit or reflect electromagnetic radiation, that is, LIGHT.

Depending on the wavelength of LIGHT, we see this or that COLOR.

Wavelength is measured in nanometers.

  • What wavelengths do the 7 colors of the rainbow correspond to?

LIGHT can be divided into 2 categories:

  1. Emitted light it is light coming from a source such as the sun, a light bulb, or a monitor screen.
  2. Reflected light it is light bouncing off the surface of an object. When we look at any object that is not a source of light, it is the reflected color that we see.


The monitor emits light, so this method of producing color is called the additive color system. Paper reflects light, so the color obtained in this way can be described using a system of subtractive colors.

  • RGB color model

It is a subtractive color model that uses three primary colors:

Red (Red)

Green

Blue

Its name comes from the first letters of the English color names. By mixing these colors, we can get almost any shade.

RGB is used by monitors, phones, and even cameras, so for computer graphics intended for use on the above devices, you need to use the RGB color mode.

  • How RGB Primary Colors Mix


Blue + Red = Magenta

Green + Red = Yellow

Green + Blue = Cyan

By mixing all three color components, we get white.

  • Primary colors of the RGB palette

Primary colors in RGB are: Red, Blue, Green


  • Additional RGB colors

Complementary colors are obtained by mixing two adjacent primary colors.

These are: Magenta, Cyan, Yellow


  • Opposite RGB colors

When mixing opposite colors, the color is white. the opposite color is composed of the two missing colors (for example, Red + Cyan (blue + green)).

Mixing 2 opposite colors is essentially the same as mixing 3 basic colors. In both cases, the result will be white. This is important to know for anyone who is seriously involved in color correction.


  • CMYK color model

Cyan

Magenta

Yellow

Black (Keycolor)

A subtractive color shaping scheme used primarily in the printing industry. This system, unlike RGB, is used for printing, so if you bring a layout to the printing industry, you are usually asked to provide it using the CMYK color mode.

  • How CMYK Colors Are Mixed

Cyan + magenta = blue, magenta + yellow = magenta, yellow + cyan = green.

Cyan, magenta, and yellow produce an off-brown color. Black makes any color darker; the absence of dye makes it white.


Cyan - Cyan, Magenta - Magenta, Yellow - Yellow;


Lesson summary

Teacher: Ivanova Svetlana Yurievna

Item: informatics and ICT

Class: 9

Theme: Color shaping in color rendering systems RGB, CMYK and HSB(Color palettes in color rendering systems RGB , CMYK and HSB )

Lesson type: learning new material

Goals:

subject: to give an idea of ​​the color palettes in color rendering systems;

metasubject:

a) regulatory: gaining experience in working with graphic images; reception and preservation of the educational task; self-control;

b) cognitive: analysis of the orientation of action in the new educational material in cooperation with the teacher; final control over the result; transformation of a practical task into a cognitive one; building logical reasoning;

c) communicative: adequate perception of the assessment of the teacher, comrades; raising questions necessary for organizing your own activities and cooperation with a partner;

d) intersubject: communication and generalization of subject knowledge of physics and informatics for the vision of an object in the unity of its diverse properties;

personal: the formation of a sustainable educational and cognitive interest in new general ways of solving problems.

Forms of organizing educational activities: conversation, individual work, practical work in pairs, self-control.

Technologies used: problem-dialogue, differentiated approach, ICT technology.

Inventory and equipment: projector, screen, teacher's laptop and student's notebooks with graphic editor installedPhotoShopand test shellMyTest, handouts, homework cards.

During the classes:

    Organizing time.

Greetings: Hello guys! I'm glad to see you! According to the philosopher E. Ilyenkov, “All human life is nothing else. As a constant desire to achieve success in solving new issues and problems. " And today the motto of our lesson is "The real treasure for a person is the ability to work." (Esop). Get to work!

    Knowledge update.

Before learning a new topic, I suggest doing a repetition test (handing out the test cards). In the last lesson, we got acquainted with bitmaps. Let's remember what is the name of the minimum area of ​​the image for which you can set the color in an independent way? (pixel). What is color depth? (The amount of information that is used to encode the color of a point in an image). We know that on the monitor screen the color of a point has a binary code. What does it mean? (consists of 0 and 1). What is the relationship between "color depth" and "color palette"? (N=2 i - Hartley's formula) (1 slide )

    Statement of the educational problem.

We are used to seeing bright images on TV screens and monitors. But it so happens that after printing on a color printer, a colorful picture stops looking. For example, I faced such a situation (I show a bright photo and a faded one). What question do you have? (why did this happen? Is it possible to fix such a photo? How to prevent this situation?)

And today in the lesson we will find out

Why does the picture look bright on the monitor, but after printing it can become faded, and for thiswe will get acquainted with color palettes in two color systems;

What needs to be done to prevent such a situation andon practice learn how to set different graphics modes.

Let's formulate the topic of the lesson. (2 slide).

    Learning new material.

Recall Newton's experiment (watching video ).

What experience have we seen so far? (Newton's experiment on light dispersion). What is it? (A narrow beam of sunlight was directed towards a triangular glass prism.) A spectrum appeared on the screen behind the prism - a rainbow strip of seven colors:red, orange, yellow, green, blue, blue andpurple( 3 slide ).

There is a well-known phrase that helps to easily remember the sequence of colors in the spectrum of visible light:"Every hunter wants to know where the pheasant is sitting."

A person perceives light with the help of color receptors, the so-called cones, located on the retina of the eye.(4 slide) .

From the monitor screen, we perceive color as the sum of the radiation of three basic colors:red , green andblue ... Such a color rendering system is called RGB, after the first letters of the English color names (Red - red, Green - green, Blue - blue ). (Let's leave two lines for the theme, we will formulate it with you later, and write down the name of the first color model)(5 slide) .

Colors in the RGB palette are formed by adding base colors, each of which can have a different intensity. The color of the Color palette can be determined using the formula

Color = R + G + B, where 0<= R <= Rmax, 0 <=G <= Gmax, 0 <= В <= Bmax .

At minimum intensities of all basic colors,black color, at maximum intensity -White Colour. At the maximum intensity of one color and the minimum of two others -Red , green andblue colors.

Overlaygreen andblue colors formsblue color (Cyan), overlayred andgreen flowers -yellow color (Yellow), overlayred andblue flowers -purple color (Magenta). Table (6 slide).

With a color depth of 24 bits, 8 bits are allocated for encoding each of the base colors. In this case, for each of the colors, N = 2 are possible 8 = 256 intensity levels. Intensity levels are set in decimal (from the minimum - 0 to maximum - 255) or binary (from 00000000 to 11111111) codes.(7 slide) .

When printing images on printers, the color palette in the CMY system is used. The main colors in it areCyan - blue , Magenta - purple andYellow - yellow. (8 slide) .

Colors in the CMY palette are formed by overlaying paints. The color of the Color palette can be determined using a formula in which the intensity of each paint is given as a percentage:

Color = С + М + Y, where 0%<= С <= 100%, 0% <= М <= 100%, 0% <= Y <= 100%.

A person perceives an image printed on paper in reflected light. If no paint is applied to the paper, then the incident white light is completely reflected, and we see a white sheet of paper.Printed on paperblue paint absorbsRed light and reflectsgreen andblue light and we seeblue Colour. Printed on paperpurple paint absorbsgreen light and reflectsRed andblue light and we seepurple Colour. Printed on paperyellow paint absorbsblue light and reflectsRed andgreen light and we seeyellow Colour.(9 slide) .

(Table). Let's consider how the color palette is formed in the systemCMYK. (write down)(10 slide) .

Mixing three colors -blue , yellow andpurple - should lead to complete absorption of light, and we should seeblack Colour. However, in practice, instead of black, it turns outdirty brown Colour. Therefore, another one is added to the color model, trulyblack Colour. Since the letter B is already used to denote blue, the last letter in the English name of black is adopted to denote black.Black , i.e.TO ... The expanded palette is namedCMYK. (11 slide) .

So, what color rendering system is used in computer monitors, televisions and other technical devices emitting light? (RGB). And we see the images from the monitor screen in the emitted light.(12 slide) .

What color rendering system is used in the printing industry? (CMYK). And we see printed images in reflected light.

    Practical work.

Let's go back to our spoiled photo. What do you think should be done before printing an image? (Translate it fromRGB v CMYK). And now we will practice with you in practice to convert an image fromRGB v CMYK.

Break into pairs, please. Each couple grabs a laptop and takes a seat at the table. Any of you worked in a graphics editorPhotoShop? Let's run the program.Before us is a working field. On the left is the toolbar. Above - the dropdown me, the properties panel. On the right - windows of additional panels. If we open the file, an image window will appear. Convert the image from RGB to CMYK.Actually, the translation fromRGB vCMYK takes exactly 1 second.

After such a translation, you may find that your graphics have lost their former brightness. The picture turned gray and faded.Why does the graphics generally become faded? We already know that the difference between these two color models is very simple.

    RGB - color model for most monitors, modern TVs, and screens in general.

CMYK is a color model that imitates printing inks with which a printing house is able to print an image.

What happens when converting fromRGB vCMYK ? First of all, each pixel in the graphics is assigned a different numerical value. VRGB these were conditionalR255G255B0 , and after conversion the pixel acquired the valuesС4M0Y93K0 .

    It is at this moment that the picture may lose its brightness. The reasons why this happens is that the girth of the modelRGB much larger than color gamutCMYK .

Photoshop is urgently looking for duller colors.

The result of this translation is not at all the maximum brightness, which throughCMYK can be provided. And you can easily verify this by simply applying the Brightness / Contrast color correction.

The reason for the loss of brightness is that Photoshop mixes too many foreign colors into the pure shades. Most often, Photoshop creates rough mixtures of paints and instead of a pronounced paint, you get what happens when you took all the gouache colors in childhood and mixed them on paper.

After converting fromRGB vCMYK the image must be color-corrected.

    Independent work.

And now I propose to work on your own using a test shellMyTest... There are three tasks before you. The first two are easy tasks. The third is more difficult. Choose any two.

(The test shell allows you to send students' answers to the teacher, who immediately sees the result. Guys can view questions that are answered incorrectly ).

    Homework.

At home, I propose to prepare a small message about the third color modelHSB... Those who have coped with all the tasks need to complete one of the proposed practical works and write a small conclusion about the work done. Anyone having difficulty. I propose to fill out the table and once again practice in determining the color.

    Reflection.

    Guys, what colors are basic for human perception? (red, green, blue)

    What color models are there?

    In what types of activities is it advisable to use them?

At the very bottom of your cards, rate your work in the lesson.

Thank you for the lesson! It was a pleasure to work with you!