0% found this document useful (0 votes)
20 views

Lecture 3

Uploaded by

wahidsabbir00
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views

Lecture 3

Uploaded by

wahidsabbir00
Copyright
© © All Rights Reserved
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 7

Color Models

Lesson Agenda:
● What is a Color Model?Names of Color Model.
● RGB Color Model Properties.
● CMY Color Model Properties.
● YUV Color Model
● YIQ Color Model
● HSI Color Model

What is Color Model?Names of Color Model.


1. A color model is a method of describing a color.
2. There are many color models. Some of them are RGB(red, green, blue),
CMY(cyan, magenta, yellow),CMYK( Cyan, Magenta, Yellow and Black.), YIQ,
HSV(hue, saturation, value) , and HLS(hue, lightness, saturation), etc.
RGB Color Model Properties.
1. The name of the model comes from the initials of the three additive primary colors
red, green and blue.
2. RGB stands for Red, Green, and Blue.
3. This color space is widely used in computer graphics.
4. RGB are the main colors from which many colors can be made.
5. The color is expressed as an RGB triplet (r, g, b), each component of which can
vary from zero to a defined maximum value.
6. If all the components are at zero the result is black; if all are at maximum, the
result is the brightest representable white.
Black: RGB(0,0,0)
White: RGB(255,255,255)
Red: RGB(255,0,0)
Green: RGB(0,255,0)
Blue: RGB(0,0,255)
Yellow: RGB(255,255,0)
Magenta: RGB(255,0,255)
Cyan: RGB(0,255,255)

7. How many colors are in RGB model?


256 x 256 x 256 = 16777216 possible colors!
8.
For each primary color, it is possible to take 256 different shades of that color. So by
adding 256 shades of 3 primary colors, we can produce over 16 million different colors
9.The concept RGB color model is used in Display monitor.
10.Primary colors are red, green, and blue

� Combining red + green + blue yields white

11.RGB24 is a 24 bit color format. Every pixel is represented by 3 bytes, while every
byte of this triple corresponds to one color value. The letters 'RGB' mean Red, Green and
Blue, so one byte represents the red value, one byte represents the green value and the
last byte represents the blue value.

12.32-bit color, in a RGB color space, is a color depth that can theoretically allow for up
to 4,294,967,296 unique colors.In the 32-bit RGB color representation, an extra 8-bit
channel for transparency is included to 24-bit RGB representation. The transparency
channel is commonly known as the alpha channel, so the format is named RGBA.

13.RGBA is not a distinct color model.Many assume that 32-bit RGB color produces
4,294,967,296 distinct colors.In reality, 32-bit RGB color actually refers to 24-bit RGB
color.

CMY Color Model Properties


● Secondary colors are cyan, magenta, and yellow
● Combining cyan + magenta + yellow yields black.

● The following formulas summarize the conversion between the two color models:

When CMY - RGB, R,G,B Values Divided by 255.


Question: RGB Values (29,98,128) Convert into RGB

● According to the color wheel shown above, equal amounts of cyan,


magenta, and yellow should produce black.
● The addition of black in this model results in it being referred to as the
CMYK color model.

YUV Color Model


● The YUV color model is the basic color model used in analog color TV
broadcasting.
● Y= luminance, UV=Chromaticity
● From RGB to YUV

Y = 0.299R + 0.587G + 0.114B

U = -0.147R - 0.289G + 0.436B

V = 0.615R - 0.515G - 0.100B

YIQ(HSB) Color Model

HSI Color Model

� Hue is defined as an angle

� 0 degrees is RED

� 120 degrees is GREEN


� 240 degrees is BLUE

� Saturation is defined as the percentage of distance from the center of the HSI
triangle to the pyramid surface.

� Values range from 0 to 1 (0 is achromatic and 1 is fully saturated)

� Intensity is denoted as the distance “up” the axis from black.

� Values range from 0 to 1

If B is greater than G, then H = 3600 – H.


Question: Convert RGB Values to HSI in Range[0-1].
R=24,G=98, B=118
R=24/255, G=98/255, B=118255
=0.09, =0.38, =0.46
I=1/3 (.09+.38+.46)
=.31
S= 1- (3/ (.09+.38+.46))Min(R,G,B)
=0.71
H= 360 -θ
=180

You might also like