Image Processing Reference
In-Depth Information
Fig. 3.8 A color image and how it can be mapped to different gray-scale images depending on the
weights
where I is the intensity and W R , W G , and W B are weight factors for R, G, and
B, respectively. To ensure the value of Eq. 3.3 is within one byte, i.e. in the range
[
0 , 255
]
, the weight factors must sum to one. That is W R +
W G +
W B =
1. As default
1
the three colors are equally important, hence W R =
3 , but depending
on the application one or two colors might be more important and the weight factors
should be set accordingly. For example when processing images of vegetation the
green color typically contains the most information or when processing images of
metal objects the most information is typically located in the blue pixels. Yet another
example could be when looking for human skin (face and hands) which has a reddish
color. In general, the weights should be set according to your application and a good
way of assessing this is by looking at the histograms of each color. 1 An example of a
color image transformed into a gray-scale image can be seen in Fig. 3.8 . Generally,
it is not possible to convert a gray-scale image back into the original color image,
since the color information is lost during the color to gray-scale transformation.
When the goal of a conversion from color to gray-scale is not to prepare the
image for processing but rather for visualization purposes, then an understanding of
the human visual perception can help decide the weight factors. The optimal weights
vary from individual to individual, but the weights listed below are a good compro-
mise, agreed upon by major international standardization organizations within TV
and image/video coding. When the weights are optimized for the human visual sys-
tem, the resulting gray-scale value is denoted luminance and usually represented
as Y .
W G =
W B =
W R =
0 . 299 ,
G =
0 . 587 ,
=
0 . 114
(3.4)
B
1 An image histogram is defined in the next chapter.
Search WWH ::




Custom Search