Quote:
Originally posted by airco
moet je mij eens uitleggen wat Irfanview dan zo speciaal doet dat de kwaliteit van de foto superieur wordt tov andere programma's .....
Imho is verkleinen gewoon een kwestie van het aantal pixels te reduceren ...... En saven in een bepaald formaat waar de libraries om dit te doen voorgeschreven zijn ....
Wat niet wegneemt dat Irfanview een perfect tool is ..... maar kwalitatief is er volgens mij geen verschil of je het met acd-see, photoshop, fireworks of Irfanview doet .....
Indien dit wel zo is ... explain.
|
Irfanview gebruikt een speciale manier van het resampelen van de pixels, ze noemen dit Lanczos Algoritme.
Hieronder word het een beetje uitgelegd:
Lanczos resizing, at least as used by Panorama Tools, is better
described as resampling using a "Lanczos-windowed sinc" filter.
The process of resampling an image to a different size can be thought of
as taking an array of discrete samples of a continuous scene (i.e. the
input image), convolving it with a "reconstruction filter" to recreate
a continuous image that's a good approximation to the original scene,
then sampling this reconstruction at a bunch of new points in new
locations. If the new points are closer together than the old ones, you
get an image with more pixels. The reconstruction filter used is just a
function with special properties.
There's a whole class of reconstruction filters created by starting out
with the assumption that the sinc function:
sinc(x) = sin(pi * x) / (pi * x)
is the perfect image reconstruction filter. It provides the best
retention of the frequencies you want, and the best attenuation of the
frequencies that you don't want (because they would cause aliasing).
Unfortunately, it's impossible to use directly because it is infinite
in extent.
So, practical filters are created by taking the sinc function and
multiplying it by a "window" function that gradually tapers the sinc
function to zero, giving an overall filter with finite size. Some
windows commonly used for this purpose are Hann, Hamming, Blackman, and
Kaiser. Most digital signal processing books will talk about these.
The Lanczos window is just a sinc function that's been stretched to be
wider, and then truncated to zero outside its main lobe. Here's an
example of a Lanczos window that is 8 units on either side of the
origin:
Lanczos8(x) = sinc(x/8) if abs(x) <= 8
= 0 if abs(x) > 8
The complete Lanczos-windowed sinc interpolation function is then
L8interp(x) = sinc(x) * sinc(x/8) if abs(x) <= 8
= 0 if abs(x) > 8
This is quite an expensive interpolating function. In one dimension,
every output points depend on the nearest 16 input points. In the 2D
(image) case, every output point depends on 256 input points.
Typically, people would likely use a Lanczos 3 or 4 window instead of 8.
(I've written code that does this, but since it's designed to be fast
instead of readable, it probably wouldn't be very illuminating to read
it.)