[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: [APML] Thoughts on Vignetting Removal
Cees,
I went though the question of whether to subtract or divide a while ago,
and came to the conclusion that subtraction works better than
division. Here is why:
The pixel values stored in an image file are converted to voltages and
sent to the monitor (CRT). However, the intensity displayed by the
CRT is not proportional to this voltage (typically, the transfer function
is a power law with an exponent of approx. 2.5, plus some offset which
depends on your individual monitor settings. See
http://www.inforamp.net/~poynton/notes/colour_and_gamma/GammaFAQ.html
for details). By coincidence, this transfer function is the approximate
inverse of the human vision's response. (Actually, the response is
logarithmic, but over a limited range of intensity values, the agreement
is quite good).
Consequently, the numbers stored in a, say, TIFF file, are approximately
the logarithms of the light intensity. Since log(a/b) = log(a)-log(b), you
need to subtract these numbers when you want to achieve the same result as
a division in linear intensity space.
As a proof, take a look at a grayscale step image, such as the one shown
on Chuck's home page
(http://www.aa6g.org/Astronomy/Articles/grayscale.html). If your monitor
is adjusted properly, the perceived difference in brightness between
adjacent steps is approximately the same. Because of the logarithmic
response of the human eye, this requires that the ratio, not the
difference, in light intensity is constant from one step to the
next. Yet, if you examine the pixels values with the color picker you find
that they are 0-15-31-....-239-255, with a constant difference. Hence,
these numbers must be logarithms.
Now, does anyone know what 'screen' is doing mathematically? I guess one
day I'll have to check the GIMP sources...
Best regards,
Axel
--
Axel Mellinger <http://canopus.physik.uni-potsdam.de/~axm/astrophot.html>
-- APML Archives at <http://astro.umsystem.edu/apml/> ---
Unsubscribe at <majordomo@seds.org>