Image Processing Reference

In-Depth Information

⎧

⎨

G

−

B

}
·

60°
,

if
V

=

R
and
G

≥

B
;

V

−

min

{

R,G,B

2
·

B

−

R

}
+

60°
,

if
G

=

V
;

V

−

min

{

R,G,B

H

=

4
·

H

∈[

0°
,
360°

[

⎩

R

−

G

}
+

60°
,

if
B

=

V
;

V

−

min

{

R,G,B

5
·

R

−

B

}
+

60°
,

if
V

=

R
and
G<B

V

−

min

{

R,G,B

(3.15)

V

−

min

{

R,G,B

}

S

=

S

∈[

0
,
1

]

(3.16)

V

V

=

max

{

R,G,B

}

V

∈[

0
,
255

]

(3.17)

where min

are the smallest and biggest of the R, G,

and B values, respectively, see Appendix B. As for HSI saturation is defined to be

zero when
(R,G,B)

{

R,G,B

}

and max

{

R,G,B

}

=

(
0
,
0
,
0
)
and hue is undefined for gray-values, i.e., when

R

=

G

=

B
. The conversion from HSV to RGB is given as

H

60°

K
=

(3.18)

H

60°
−

T

=

K

(3.19)

X

=

V

·

(
1

−

S)

(3.20)

Y

=

V

·

(
1

−

S

·

T)

(3.21)

·
1

T)

Z

=

V

−

S

·

(
1

−

(3.22)

⎧

⎨

(V,Z,X),

if
K
=

0;

(Y,V,X),

if
K
=

1;

(X,V,Z),

if
K
=

2;

(R,G,B)
=

(3.23)

⎩

(X,Y,V),

if
K
=

3;

(Z,X,V),

if
K

=

4;

(V,X,Y),

if
K

=

5

where

means the floor of
x
, see Appendix B. In Table
3.3
the HSV values of

some RGB colors are shown.

x

3.3.3 The YUV and YC
b
C
r
Color Representations

A number of other color representations exist, but those mentioned above are those

most often applied in image processing. One exception, however, is the color rep-

resentations used for transmission, storage, and compression of image and video.

These representations all have a similar structure, which is presented in this section.

In the early days of TV only monochrome screens were available and hence only

intensity information was transmitted from the TV stations. RGB cameras captured

RGB signals, but converted them into luminance values, denoted
Y
, before transmit-