Color Patterns PDF
Color Patterns PDF
2
COLOR FUNDAMENTALS
3
COLOR SPECTRUM
4
CHROMATIC LIGHT
6
ABSORPTION OF LIGHT BY THE CONES
7
PRIMARY AND SECONDARY COLORS OF LIGHT
8
COLOR TV
9
CIE CHROMATICITY DIAGRAM
A straight line
segment joining
any 2 points
defines all the
different color
variations that can
be obtained by
Any point within
mixing these 2
the diagram
colors additively.
represents some
mixture of
spectrum colors.
Points on the
boundary are
pure colors in
the visible Any color in the
spectrum. triangle can be
produced by
various
combinations of
the corner colors.
10
COLOR MODELS
11
RGB MODEL
Images represented
with the RGB color
model have 3
component images:
Red component
Green component
Blue component Each color is represented by a
point in or on the unit cube.
If 8 bits are used for
each pixel, we have
a 24-bit RGB image.
12
RGB 24-BIT COLOR CUBE
13
COLOR PLANES
A color image is
acquired using the
process in reverse
order.
R = 127
G = 0-255
B = 0-255
14
SAFE RGB COLORS
15
RBG SAFE-COLOR CUBE
16
CMY & CMYK COLOR MODELS
Most devices (color printers, copiers, etc.) that deposit color pigments on
paper require CMY data input or perform an internal RGB to CMY
conversion.
RGB to CMY conversion (all color values are in the range [0,1]):
C 1 R light reflected from a surface coated with pure cyan does not contain red
M = 1 - G light reflected from a surface coated with pure magenta does not contain green
Y 1 B light reflected from a surface coated with pure yellow does not contain blue
17
HSI COLOR MODEL
18
CONCEPTUAL RELATIONSHIP BETWEEN RGB AND
HSI COLOR MODELS
The intensity
component of
this color As the planes moves up
point can be and down, the boundaries
determined defined by the
by passing a intersection of each plane
with the faces of the cube
plane (0,0,0) have either a triangular or
perpendicular hexagonal shape.
to the axis
and
containing
the point. Conclusion: H, S, and I values required to form the HSI
space can be obtained from the RGB cube.
19
HUE AND SATURATION IN THE HSI MODEL
View obtained by
looking at the
RBG cube down
its gray-scale It is not unusual to see
axis. HSI planes defined in
terms of a hexagon, a
triangle, or even a circle.
20
TRIANGULAR AND CIRCULAR COLOR PLANES
IN THE HSI MODEL
mid-point of the
vertical intensity axis
21
CONVERTING COLORS FROM RGB TO HSI
if B G
1
( R G ) ( R B )
H with cos 1 2
1/ 2
360 if B > G
( R G ) ( R B)(G B )
2
Can be normalized
to the range [0,1] by
diving all the values
by 360.
3
S 1 [min( R, G, B)]
( R G B)
1
I ( R G B)
3
22
CONVERTING COLORS FROM HSI TO RGB
S cos H
B I (1 S ) R I 1 G 3I ( R B )
cos(60 H )
0
S cos H
R I (1 S ) G I 1 B 3I ( R G )
cos(60 H )
0
S cos H
G I (1 S ) B I 1 R 3I (G B )
cos(60 H )
0
23
PSEUDO-COLOR IMAGE PROCESSING
24
INTENSITY SLICING
A different color is
assigned to each side of
the plane.
Algorithm:
[0,L-1]: gray-scale
L0: black
lL-1: white
P planes: l1,l2,…,lP
f(x,y) = ck if f(x,y) Vk
25
INTENSITY SLICING INTO 8 COLORS
26
INTENSITY SLICING INTO 2 COLORS
27
INTENSITY SLICING INTO 2 COLORS
Average monthly
rainfall over a
period of 3 years
Much
easier to
interpret
28
3 INDEPENDENT COLOR TRANSFORMATIONS
29
PSEUDO-COLOR ENHANCEMENT: AN EXAMPLE
30
COMBINATION OF SEVERAL MONOCHROME IMAGES
INTO A SINGLE COLOR COMPOSITE
31
3 MONOCHROME IMAGES ARE COMBINED
visible red
visible green
First 3 images
are combined Red component was
into an RGB replaced with the
image infrared image
32
COMBINING IMAGES FROM A SPACECRAFT
One way to
combine the
sensed image This image was
data is by how obtained by combining
they show several of the sensor
differences in images from the Galileo
surface chemical spacecraft.
composition.
Bright red
depicts material
newly ejected
from an active
volcano.
Surrounding
yellow materials
are older sulfur
deposits.
33
BASICS OF FULL-COLOR IMAGE PROCESSING
34
COLOR TRANSFORMATIONS - FORMULATION
35
COLOR-SPACE COMPONENTS OF A FULL-COLOR
IMAGE
CMYK
RGB
HSI
36
MODIFIED INTENSITY OF THE FULL-COLOR IMAGE
37
COLOR COMPLEMENTS
Complements are
analogous to gray-scale
negatives: they are useful
in enhancing detail
embedded in dark region of
a color image.
38
COLOR SLICING
The width of the cube and the radius of the sphere were determined
interactively.
39
AN EXAMPLE OF COLOR SLICING
40
HISTOGRAM PROCESSING
It is generally unwise to
histogram equalize the
components of a color
image independently.
This results in erroneous
color.
1
c ( x, y )
K
c ( x, y )
( x , y )S xy
1
K
R ( x, y )
( x , y )S xy
Smoothing by
neighborhood
1 averaging can be
c ( x, y ) K
G ( x, y ) carried out using
( x , y )S xy either individual color
planes or the RGB
1 color vectors.
K
B ( x, y )
( x , y )S xy
42
AN RGB IMAGE AND ITS COLOR PLANES
43
HSI PLANES
44
SMOOTHED IMAGES
45
COLOR IMAGE SHARPENING
2 R( x, y)
The Laplacian of a full-
color image can be
2 [c( x, y)] 2G( x, y) obtained by computing
the Laplacian of each
component plane
separately.
2 B( x, y)
The Laplacian
46
SHARPENED IMAGES
47
COLOR SEGMENTATION IN HSI COLOR SPACE
HSI space:
48
COLOR SEGMENTATION IN RGB COLOR SPACE
Classify each pixel in the given image with according to the specified range.
49
AN EXAMPLE OF COLOR SEGMENTATION
IN RGB COLOR SPACE
50
COLOR EDGE DETECTION
So, computing the gradient on individual planes, and then using the
results to form a color image will lead to erroneous results.
1 2 g xy
Direction of max rate of change: tan 1
2 ( g xx g yy )
1
1
Value the rate of change: F ( ) ( g xx g yy ) ( g xx g yy ) cos 2 2 g xy sin 2
2
2
51
AN EXAMPLE OF COLOR EDGE DETECTION
USING 2 APPROACHES
The edge
detail is
more
complete!
Both
approaches
yielded
reasonable
results. Is the
extra detail
worth the added
computational
burden of the
vector
approach?
52
COMPONENT GRADIENT IMAGES
53
NOISE IN COLOR IMAGES
Gaussian noise
Rayleigh noise
Erlang noise
Exponential noise
Uniform noise
Impulse (salt and pepper) noise
54
GAUSSIAN NOISE IN A COLOR IMAGE
55
NOISY RGB IMAGE CONVERTED TO HSI
The intensity
plane is
slightly
smoother than
any of the 3
RGB noisy
planes.
1
I ( R G B)
3
Compare
Image
averaging
reduces
random noise!
56
ONE NOISY RGB CHANNEL
AFFECTS ALL HSI PLANES
57
COLOR IMAGE COMPRESSION
Compression reduces
the amount of data
required to represent a
digital image.
Compressed with
JPEG 2000.
The compressed
image contains
only 1 data bit for
every 230 bits of
data in the original
image.
58