0% found this document useful (0 votes)
31 views47 pages

Color Models

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
31 views47 pages

Color Models

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 47

Computer Graphics

Color Models
Color Model
Color Model: It is an abstract mathematical model describing
the way color can be represented as tuple of numbers, typically
it is three or four.

Color Space : When color model is associated with a precise


description of how the components are to be interpreted the
resulting set of colors is called color space.
Main Color Spaces
• CIE XYZ, xyY
• RGB, CMYK
• HSV (Munsell, HSL, IHS)
• Lab, UVW, YUV, YCrCb, Luv,
CIE Standard
• CIE: International Commission on
Illumination (Comission Internationale de
l’Eclairage).
• Human perception based standard (1931),
established with color matching
experiment
• Standard observer: a composite of a group
of 15 to 20 people
CIE Experiment
3D LMS Colour Space

The normalized spectral sensitivity of human cone cells of short (S,


420–440 nm)-, middle (M, 530–540 nm)- and long (L, 560–580 nm)-
wavelength types, using three pure light source: R = 700 nm, G = 546
nm, B = 436 nm.

Cλ = r(λ) + g(λ) + b(λ)


CIE Color Space
• 3 hypothetical light
sources, X, Y, and Z,
which yield positive
matching curves
• Y: roughly corresponds
to luminous efficiency
characteristic of human
eye
• the XZ plane will contain
all possible
chromaticities at that
luminance.
Chromaticity
Chromaticity is an objective specification of the quality
of a color regardless of its luminance.

It is determined by its hue and colorfulness

Hue determines the weakness or intensity of a color .

Colorfulness is the difference between a color against


gray
Chromaticity Diagram
• When we plot the normalized amount x and y
for colors visible in the spectrum we obtain the
tongue shaped curve.

• This curve is called the chromaticity diagram.

• Points along the curve are the pure color in the


spectrum, labeled according to the wavelength
in nanometer from red end to violet end.
Chromaticity Contd…
• The chromaticity of a color was specified by
the two derived parameters x and y, two of
the three normalized values which are
functions of all three values X, Y, and Z.

• Since we have normalized against the


luminance ,Parameter x and y are called the
chromaticity value because they only depends
on the hue & purity.
CIE xyY Space
• Irregular 3D volume shape is
difficult to understand
• Chromaticity diagram (the
same color of the varying
intensity, Y, should all end up
at the same point)
Terminology
1) Gamut : Usually ,any color model use combination of two to three colors
to produce wide range of colors, called the color gamut for that model.

2) Primary color: The basic color used to produce color gamut in a particular
model are called primary color.

3) Secondary Color: The different color obtained by mixing the primary


color are called the secondary color.

4) Complementary color : When two color sources are combined to produce


white color . e.g
Red & Cyan, green & magenta, blue & yellow are the complementary colors.
Color Model
• A color model is a method for explaining the
properties or behavior of color within some
particular context.
• No single color model can explain all aspects
of color,so we make use of different models to
describe the different perceived
characteristics of color.
COLOR MODELS FOR RASTER GRAPHICS
• The purpose of a color model is to allow convenient
specification of colors within some color gamut.
• Three hardware-oriented color models are RGB
(CRT monitors), YIQ (broadcast TV color system),
and CMY (color-printing devices)
• To be related directly to intuitive color notions of
hue, saturation, and brightness, another class of
models (HSV, HSL, HVC, etc) are developed with
ease of use as a goal

Copyright @ 2001 by Jim X. Chen:


[email protected]
RGB COLOR MODELS
• In the RGB model, each color appears as a combination of
red, green, and blue.

• This model is called additive, and the gamut of this model


are red, green and blue.

• These three primary colors can be added to produce the


secondary colors.

• Magenta (red + blue), Cyan (green + blue), and Yellow (red


+ green). The combination of red, green, and blue at full
intensities makes white.
RGB (monitors)
• The de facto standard
RGB COLOR MODEL
Cyan (011)

Yellow (110)

White (111)

Black (000)

Magenta (101)
CMY COLOR MODEL
In this model Cyan , magenta and yellow colors
are used as (Gamut) primary color.

The Cartesian co-ordinate system are same as


that of RGB except that white instead of black at
the origin.
RGB & CMY
CMY COLOR MODEL
CMY(K): printing
• Cyan, Magenta, Yellow (Black) – CMY(K)
• A subtractive color model

dye color absorbs reflects


cyan red blue and green
magenta green blue and red
yellow blue red and
green
black all none
RGB and CMY
• Converting between RGB and CMY
RGB & CMY
Additive vs. Subtractive Color
Models
• Since additive color models display color as a result
of light being transmitted (added) the total absence of
light would be perceived as black. Subtractive color
models display color as a result of light being
absorbed (subtracted) by the printing inks. As more
ink is added, less and less light is reflected. Where
there is a total absence of ink the resulting light being
reflected (from a white surface) would be perceived
as white.

25
Additive vs. Subtractive Color
Models

26
HIS model
• Hue: it indicates pure color of light.
• Saturation: it indicates how much white light
is mixed with color.
• Intensity: it tells about the shade.
HSV model
• HSV stands for Hue-Saturation-Value

• Described by a hexcone derived from the RGB cube


HSV model,cont’d
• Hue (0-360°); ”the
color”, (128)

• Saturation (0-1); ”the


amount of white” (130)

• Value (0-1); ”the


amount of black” (23)
HSV cond..
1) Hue is represented as an angle about the vertical axis, ranging
from (0-360). 0 degree at red , Yellow at 60 degree, Vertices of
the hex cone are separated by 60 degree.

1) Saturation is represented as the ratio of purity of a selected


hues. The maximum purity is at S=1.
e.g at S=0.5 the hue is said to be half pure.

3) Values V varies from 0 at the apex and 1 at the top of the hexcon.
The apex represents the black. At the top of the hex cone
colors have the maximum intensity. When we have v=1 & s=1
we have the pure hue.
HSV model,cont’d
The human eyes are capable to distinguish 128
different hues, 130 different saturation and 23
shades can be detected . It means that we can
distinguish 128*130*23 = 382720

In Computer Graphics, 128 hues , 8 saturation levels


and 15 values settings are suffecient
ie 128*8*15 = 15360 colors.
HLS Model
• Three color parameter in this model are
H: HUE
L:Lightness
S: Saturation

1) HUE:
• It has the same meaning as in the HSV model.It specifies

an angle about vertical axis that locates a chosen hue.


• In this model H= 00 corresponds to blue.The remaining
colors are specified around the perimeter of the cone.
• Magenta is at 600, Red is at 1200 , Cyan is at H=1800
HLS Contd…
2) Lightness:
• The vertical axis in this model is called the lightness L.
At L =0 we have Black and at L=1,it is white.
• Gray scale is along the L axis and the “Pure
hues” lies on L=0.5.

3) Saturation:
• Saturation parameter S again specifies relative
purity of the color .This parameter varies from 0-1, and
pure hues are those for which S= 1 and L=0.5.
• As S decreases the hue are said to be less pure.
• At S=0 we have Gray scale
HLS COLOR Model
YIQ Color Model
• Y : Luminance (Brightness)
• I : Inphase
• Q: Qudrature.

This Model is used by NTSC to form the


composite video signal used for television.
YIQ Contd….
• Parameter Y is used to represent the Luminance or
brightness while chromaticity information (hue & purity) is
incorporated into I and Q.

• Since Y contains the luminance information so black &


white television monitors uses only the Y signal.

• Parameters I contains orange-Cyan hue information that


provide the tone shading and having a bandwidth of 1.5
MHZ.

• Parameters Q carries green-magenta hue information in a


bandwidth of 0.6 MHZ.
The YIQ color model (US color TV broadcasting)
• A recording of RGB for transmission efficiency and for
downward compatibility with black and white television.
• Here Y=luminance, the same as the CIE Y primary. Only
the Y component of a color TV signal is shown on black-
and-white TVs.
• I stands for in-phase, while Q stands for quadrature,
referring to the components used in quadrature amplitude
modulation. Some forms of NTSC now use the YUV color
space, which is also used by other systems such as PAL.
• More bits of bandwidth are used to represent Y than to
represent I and Q, because our eye is more sensitive to
changes in luminance
The YIQ color space at Y=0.5

From RGB to YIQ

From YIQ to RGB


Color Table
• Color table has 8 bit of control over each of the red , green &
blue . Therefore they have the 256 intensity levels

• So with the 256 intensity levels of each color we can produce


16,777,216 different colors.

• So to specify color of any pixel 24 bits(ie 8 bit per color) are


required.

• To store 24 bit information of each color (ie 16,777,216) is


not cost effective.
Color Table
• Therefore in normal practice only few color is specified in the
table called color table.

• A color table allows us to map between a color index in the


frame buffer and a color specification.

• If a color table has 256 color entries then the table can show
any of the 256 of 16,777,216 possible colors.
Color table
• Each entry in the table is 24 bit specifying one color.The
colors specified in the color table are available for selection
color.

• We can change the available color in the color table by


changing the color information, however at a time only 256
color can be displayed.

• The colors in the color table are referred by the color index.
Color Mixing
Two or more color can be added together to produce a new color . There are
two types of color mixing

1) Additive color mixing:


An additive color model involves light emitted directly from a source or
illuminant of some sort. The additive reproduction process usually uses red,
green and blue light to produce the other colors.

Combining one of these additive primary colors with another in equal


amounts produces the additive secondary colors cyan, magenta, and yellow.

Combining all three primary colors in equal intensities produces white.


Additive Color Mixing
Color Mixing
2) Subtractive color mixing:
Subtractive color mixing involves the selectively absorption of
the wavelength. Cyan , Magenta and yellow are subtractive
primaries.

If a white light will pass through a yellow filter the yellow filter
absorb blue and transmit red & green , therefore yellow can be
considered as B Filter.

Similarly magenta subtract or absorb green from the white light


and cyan subtract or absorb Red from the white light.
Subtractive color mixing
• A subtractive color model explains the mixing of paints, dyes,
inks, and natural colorants to create a full range of colors,
each caused by subtracting (that is, absorbing) some
wavelengths of light and reflecting the others.

• The color that a surface displays depends on which colors of


the electromagnetic spectrum are reflected by it and
therefore made visible.
Subtractive color mixing
Applications of Colors
• Use in marketing
• Specific color meaning
• Attractive attension
• Indivisual differences

You might also like