Lessons 12 · 1 lessons · N. I. Taylaqov (general editor), A. B. Akhmedov, M. D. Pardayeva, A. A. Abdug‘aniyev, U. M. Mirsanov. Informatics and Information Technologies, Grade 11, 1st edition. “Extremum-press”, Tashkent, 2018
12
Working with colours in PhotoShop
Textbook: pp. 46–48
GoalChooses a colour with the colour picker, the Color and Swatches panels and the eyedropper, tells the colour modes (RGB, CMYK, Grayscale, Indexed, Lab) apart and calculates their effect on file size.
New words
Lab: a device-independent system: L – lightness, a – green to red, b – blue to yellow · LabGrayscale: 256 shades of grey, one byte per pixel · Grayscale (yarim tusli)Indexed colour: the picture uses a palette of at most 256 colours · Indexed (indekslangan ranglar)Swatches: a panel of ready-made colours that can be picked with one click · Swatches (Namunalar)
Explanation
The RGB, CMYK and HSB systems cannot show every colour found in nature, and they depend on the device: two different monitors show the same RGB value slightly differently, and in print some saturated screen colours come out duller. The system independent of devices and covering the widest range of colours is Lab: L is lightness (0–100), a is the change from green to red, and b is the change from blue to yellow. PhotoShop uses Lab as an intermediate when converting between systems, and colour profiles (for example sRGB) help colours look the same on different devices. There are several ways to choose a colour: click the foreground or background colour square on the toolbar and move the slider and colour field in the picker or type a value (RGB, HSB, CMYK, hexadecimal code); use the sliders of the Color panel; take a ready colour from the Swatches panel; or take one from any point of the picture with the Eyedropper (key I). The colour mode is changed in Image → Mode: in Grayscale mode each pixel takes 1 byte and is one of 256 shades of grey; in Indexed mode the picture uses a palette of up to 256 colours (handy for the web and GIF). Converting a colour picture to grey loses information: converting back to RGB does not bring the colours back, so keep the original.
Worked examples
To get a school-club colour exactly for a web page: click the foreground colour square, type 1E90FF in the # field (RGB 30, 144, 255), and paint with the brush. To take another colour from the picture, choose the Eyedropper with the I key and click the wanted point.
Size: a 1000×800 pixel picture is 1000·800·3 = 2 400 000 bytes in RGB (24-bit), 1000·800 = 800 000 bytes in Grayscale (8-bit), and in 256-colour Indexed mode 800 000 bytes plus a palette of 256·3 = 768 bytes, 800 768 bytes in all. For a black-and-white copy use Image → Mode → Grayscale; PhotoShop then asks to discard the colour information.
Class activity
“Colour detective”: the teacher gives hexadecimal codes of several colours (#FF0000, #00FF00, #808080...). Students work out which colour each is and check it in the Swatches panel and the colour picker.
Practice
1
What do the three parameters of the Lab system mean?
L – lightness; a – green to red; b – blue to yellow.
2
How many bytes does a 1000×800 pixel, 8-bit Grayscale picture take?
800000
3
How many bytes is the palette of a 256-colour Indexed picture (3 bytes per colour)?
768
4
Why does converting a Grayscale picture back to RGB not restore the colours?
In Grayscale only each pixel's brightness is kept; the colour information is gone.