[cairo] Cairo + GdkPixbuf

Soeren Sandmann sandmann at daimi.au.dk
Wed Jun 30 08:23:25 PDT 2010


Hi,

> Yes, RGBA is the obvious choice of people new to image formats, because
> it's how people think of pixels. Which is why it shows up in every
> project that needs graphics but has inexperienced developers (like Gtk1,
> HTML5 canvas or the PNG specification).
> That alone is a good enough reason for adding support for these formats
> to Cairo. I started on this work, but there are still some disagreements
> on how to best support the formats' requirements (see below), so it
> might take a while until my patches (or reworked versions) land in the
> code repositories. But it's definitely my intention to get support for
> these formats into Cairo. (Note to self: Talk to Søren about how to do
> this stuff in Pixman again).

Didn't we more or less agree on IRC that most of what I wrote her:

    http://lists.cairographics.org/archives/pixman/2010-May/000199.html

was just plain wrong? In particular, the idea that chroma
reconstruction is the same as filtering was misguided.

Instead, my current opinion is that they are two separate things and
that the pipeline should (eventually) look like this:

    extend
    widen
  
    chroma reconstruct  <= upsample filter
    
    convert to ar'g'b'  <= \
    linearize           <= | color space convert
    premultiply         <= /

    interpolate         <= interpolation filter
    transform
    resample            <= resampling filter, plus sampling rate
    combine

    convert to dest format

    store

where 'chroma reconstruct' and 'premultiply' would be added with the
YUV and RGBA formats, and 'linearize' and 'resample' would be added
some day to do gamma correct compositing and higher-quality image
scaling.


Soren


More information about the cairo mailing list