Gamut Mapping
Homework 2
Simon Premoze
Introduction
In order to display a rendered image on a particular device (printer, monitor,
etc) we have to be able to map colors in our image to a range of displayable
colors (gamut) for that particular device. Unfortunately, devices don't
share the same gamut. Furthermore, not even all monitors or group of devices
share the same gamut. When colors in our original image lie outside the
device gamut, we have to map these colors into displayable. The process
is called gamut mapping. It is a difficult procedure, because it involves
distortion of the original signal. To make things even worse, there is
no "right" way to distort the signal.
Gamut Mapping Methods
There are two general categories of gamut mapping methods: local and global.
Local technique looks at each pixel individually and modifies only those
pixels that don't fall into the gamut. On the other hand, the global technique
examines all pixels including those that already lie in the gammut.
I have tried the following gamut mapping methods:
-
Method1
Find Min( R, G, B ) and Max( R, G, B ) then scale by Max - Min
-
Method2
Clamp negative values to 0. Scale positive values by Max( R, G,
B )
-
Method4
Clamp R, G, B to [0, 255]
-
Method5
Find Min( R, G, B). Add Min to all components. Clamp negative
values to 0. Scale positive values by Max(R, G, B)
|
Normal Scaling |
Independent Channel Scaling |
| Scale Min |
|
|
| Clamping |
|
|
| Clipping to gamut cube |
|
|
| Clamping to [0,255] |
|
|
| Adding MIN, clamping negative values and scaling |
|
|
| 20% Desaturation |
|
|
Transformation from XYZ to RGB space
I have tried many different transformation matrices:
Brian's suggestion:
| [ |
R |
] |
|
[ |
3.4834 |
-1.5218 |
-0.5592 |
] |
[ |
X |
] |
| [ |
G |
] |
= |
[ |
-1.0715 |
1.9659 |
0.0367 |
] |
[ |
Y |
] |
| [ |
B |
] |
|
[ |
0.0635 |
-0.2002 |
0.8107 |
] |
[ |
Z |
] |
Glassner's book Principles of Digital Image Synthesis:
| [ |
R |
] |
|
[ |
1.967 |
-0.955 |
-0.064 |
] |
[ |
X |
] |
| [ |
G |
] |
= |
[ |
-0.548 |
1.938 |
-0.130 |
] |
[ |
Y |
] |
| [ |
B |
] |
|
[ |
-0.297 |
-0.027 |
0.982 |
] |
[ |
Z |
] |
From Radiance rendering package by Greg Ward:
| [ |
R |
] |
|
[ |
2.565619 |
-1.166989 |
-0.398511 |
] |
[ |
X |
] |
| [ |
G |
] |
= |
[ |
-1.022095 |
1.978261 |
0.043821 |
] |
[ |
Y |
] |
| [ |
B |
] |
|
[ |
0.07469 |
-0.251851 |
1.17680 |
] |
[ |
Z |
] |
NTSC transformation for a generic or standard monitor ( from Hall )
is given by:
| [ |
R |
] |
|
[ |
1.730 |
-0.482 |
-0.261 |
] |
[ |
X |
] |
| [ |
G |
] |
= |
[ |
-0.814 |
1.652 |
-0.023 |
] |
[ |
Y |
] |
| [ |
B |
] |
|
[ |
0.083 |
-0.169 |
1.284 |
] |
[ |
Z |
] |
Another one:
| [ |
R |
] |
|
[ |
2.739 |
-1.145 |
-0.424 |
] |
[ |
X |
] |
| [ |
G |
] |
= |
[ |
-1.119 |
2.029 |
-0.033 |
] |
[ |
Y |
] |
| [ |
B |
] |
|
[ |
0.138 |
-0.333 |
1.105 |
] |
[ |
Z |
] |
The transformation between XYZ and RGB spaces depends on monitor (actually
phosphors of the monitor) on which image is displayed. Roy Hall provides
details how to measure it in his book "Illumination and Color in Computer
Generated Imagery".
Gamut Mapping Strategies
According to Stone et al. the gamut mapping technique should satisfy 5
criteria:
-
The gray axis of the image should be preserved
-
Maximum luminance contrast is desirable
-
Few colors should lie outside the destination gamut
-
Hue and saturation shifts should be minimized
-
It is better to increase than to decrease the color saturation
Conclusions
Proper gamut mapping is very difficult problem. One can fix or improve
one aspect of the mapping, but he'll introduce new problems or artefacts
at the same time. Both local and global techniques have severe problems.
Local methods introduce limit error problems. This problem occurs if there
is a sudden change of appearance from one pixel to another. On the other
hand, global methods don't have limit error problems, but they introduce
semantic inconsistencies. Further research and experimentation is xsneeded
to offset these problems.
Simon Premoze
premoze@cs.utah.edu