[Pixman] [PATCH 2/2] Replace compute_src_extent_flags() with analyze_extents()

Soeren Sandmann sandmann at daimi.au.dk
Wed Aug 11 12:54:29 PDT 2010


Andrea Canciani <ranma42 at gmail.com> writes:

> This commit breaks large-source-roi in the cairo test suite.
> The testcase creates a surface with width 32767. Is this within the
> acceptable range for pixman?

Well, the check that is being triggered is this:

    /* During repeat mode calculations we might convert the
     * width/height of an image to fixed 16.16, so we need
     * them to be smaller than 16 bits.
     */
    if (image->bits.width >= 0x7fff || image->bits.height >= 0x7fff)
        return FALSE;

so I guess the answer is that it isn't within the acceptable range at
the moment.

The problem of course is that when we use signed 16.16 fix point
values, they will overflow and become negative when we sample the
edges of such an image.

Ideally, pixman would support up to 24 bits of range for width/height,
as long as we can't do that reliably anyway, it probably doesn't make
sense to rely on it in certain special cases.


Soren


More information about the Pixman mailing list