Vous êtes sur la page 1sur 50

Danang University of Science and Technology (DUT)

Image Processing
Lecture 7
Color Image Processing
Color Fundamentals

2
Color Fundamentals

3
Color Fundamentals
Cones are responsible for color vision
6 to 7 million cones (4.5 million from other sources) in
the human eye (retina) can be divided into three
principal sensing categories, corresponding roughly to
red, green, and blue.
65%: red, 33%: green, 2%: blue (blue cones are the
most sensitive). The numbers of red and green cones
can vary greatly among persons with regular vision.
Cone cells function best in bright light
Rod cells work in dim light
4
Color Fundamentals

5
Color Fundamentals

6
Absorb Blue

Magenta
absorbs
Green & Absorb Red
Yellow
absorbs Blue,
hence leave
Red 7
Color Fundamentals
The characteristics generally used to distinguish one
color from another are brightness, hue, and saturation
brightness: the achromatic notion of intensity.
hue: dominant wavelength in a mixture of light waves,
represents dominant color as perceived by an
observer.
saturation: relative purity or the amount of white light
mixed with its hue.

8
Color Fundamentals
Tristimulus
Red, green, and blue are denoted X, Y, and Z,
respectively. A color is defined by its trichromatic
coefficients, defined as:

=
++

=
++

=
++
9
CIE Chromaticity Diagram
It shows color
composition
as a function
of x (red) and
y (green)

10
RGB Color Model

11
RGB Color Model

The total number


of colors in a 24-bit
RGB image is (28)3
= 16,777,216

12
13
HIS Color Model

brightness: the achromatic notion of intensity.


hue: dominant wavelength in a mixture of light
waves, represents dominant color as perceived by an
observer.
saturation: relative purity or the amount of white light
mixed with its hue.

14
HIS Color Model

15
HIS Color Model

16
HIS Color Model

17
Converting Colors from RGB to
HSI
Given an image in RGB color format, the H component
of each RGB pixel is obtained using the equation

=
>
where

+ ( )
=
( ) +( )( ) /

18
Converting Colors from RGB to
HSI

Given an image in RGB color format, the saturation


component is given by

= (, , )
++

19
Converting Colors from RGB to
HSI

Given an image in RGB color format, the intensity


component is given by

= ( + + )

20
Converting Colors from HSI to
RGB

RG sector (0 < 120 )


= ( )
()
= +
( )
= ( + )

21
Converting Colors from HSI to
RGB

GB sector (120 < 240 )


=
= ( )
()
= +
( )
= ( + )

22
Converting Colors from HSI to
RGB

BR sector (240 < 360 )


=
= ( )
()
= +
( )
= ( + )

23
24
25
26
Pseudocolor Image Processing

The process of assigning colors to gray values based on


a specified criterion.
Intensity Slicing
, = if (, )

27
28
29
30
31
Pseudocolor Image Processing
Intensity to Color Transformation

32
The images are obtained
from an airport X-ray
scanning system.
The left contains ordinary
articles and the right
contains the same articles
as well as a block of
simulated plastic explosives.

33
34
Basics of Full-Color Image
Processing
Let c represent an arbitrary vector in RGB color space:

= =

At coordinates (x,y)

(, ) (, )
(, ) = (, ) = (, )
(, ) (, )

35
Basics of Full-Color Image
Processing

36
37
, = (, ) Intensity adjustment

si kri , si kri (1 k ), s3 kr3


i 1, 2,3. i 1, 2,3. 38
39
40
Color Image Smoothing
Let Sxy denote the set of coordinates defining a
neighborhood centered at (x,y) in an RGB color image.
The average of the RGB component vectors in this
neighborhood is:

(, )

(,)


, = , = (, )
(,)
(,)

(, )

(,)
41
42
43
44
Color Image Sharpening

The Laplacian of vector c is:

(, )
(, ) = (, )
(, )

45
46
Image
Segmentation
Based on
Color:

Segmentation
in HIS Color
Space

47
Segmentation in RGB Vector
Space
Let the average color of interest is denoted by the
RGB vector a. Let z denote an arbitrary point in
RGB space.
, = = ( ) /
/
= ( ) +( ) +( )

distance

48
49
Color edge detection

50

Vous aimerez peut-être aussi