[Pixman] Better quality downsampling in cairo/pixman
alex.shulgin at gmail.com
Tue Jun 29 00:04:22 PDT 2010
I don't really like to beat the dead horse, but here it goes... :)
(Apparently my first try didn't pass moderation, so I'm retrying now
with more compact attachment.)
The other day I was using Alt+TAB to switch between windows in my
brand new Ubuntu desktop and was unpleasantly surprised how window
thumbnails quality was in striking contrast with the overall eye-candy
of the desktop (other effects seem to use OpenGL).
Not sure if cairo is the case here, but the simple test I made shows
that the best filter it have in the toolbox is bilinear
(cairo-best.png). Gimp beats cairo with it's left hand, when it comes
to downsampling (see gimp-cubic.png). And even gimp-linear.png seems
to be much better than cairo's best attempt!
I'm willing to take my time improving cairo's downsampling
capabilities, if experienced people out there are willing to help me
by answering my naive questions and pointing in the right direction.
So my current questions are:
1) How hard would it be to add new cairo (or does it belong to
pixman?) filter, say bicubic interpolation?
2) How comes Gimp's linear is much like cubic? Does it seem to do
something more than just bilinear interpolation?
3) I know from past experience that even bicubic can be faulty when it
comes to downsampling by a factor of over 1/4. I have solved this
issue by using Lanczos (SinC) filter once. Should we consider using
this filter too?
That's all for now.
All the best!
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 116627 bytes
Desc: not available
More information about the Pixman