[cairo] Problem with unaligned clip regions

Uli Schlachter psychon at znc.in
Thu Mar 17 12:14:22 PDT 2011


Am 17.03.2011 02:39, Tristan Schmelcher wrote:
> Hello,
> 
> I am building a cairo app and I have come across what seems to be a
> bug in the handling of unaligned clip regions. When painting from one
> image surface to another image surface with a complex clip region
> involving unaligned boxes, cairo/pixman paints a large black rectangle
> to the target in an area that is not supposed to be modified. The
> issue repros for me 100% of the time with cairo 1.10.2 and pixman
> 0.20.2 (and also pixman 0.21.4). It does NOT occur with 1.8.10 /
> 0.16.4. I've attached a minimal test program that repros the problem.
> 
> I'm going to work around the problem in my app by avoiding unaligned
> clip regions so I don't really need it to be fixed, but I figured
> people would probably still want to know about it. :)

Git bisect blames this (quite generic) commit:

$ git bisect good
b9407af6a4bc792c1bcb52c90aa8a618627bb618 is the first bad commit
commit b9407af6a4bc792c1bcb52c90aa8a618627bb618
Author: Chris Wilson <chris at chris-wilson.co.uk>
Date:   Fri Jan 22 17:57:41 2010 +0000

    image: Implement high level interface.

    Write a dedicated compositor for pixman so that we avoid the
    middle-layer syndrome of surface-fallback. The major upshot of this
    rewrite is that the image surface is now several times quicker for glyph
    compositing, which dramatically improves performance for text rendering
    by firefox and friends. It also uses a couple of the new scan
    convertors, such as the rectangular scan converter for rectilinear
    paths.

    Speedups
    ========
    image-rgba          firefox-talos-gfx-0    342050.17 (342155.88 0.02%) ->
69412.44 (69702.90 0.21%):  4.93x speedup
    ███▉
    image-rgba                        vim-0    97518.13 (97696.23 1.21%) ->
30712.63 (31238.65 0.85%):  3.18x speedup
    ██▏
    image-rgba                  evolution-0    69927.77 (110261.08 19.84%) ->
24430.05 (25368.85 1.89%):  2.86x speedup
    █▉
    image-rgba                    poppler-0    41452.61 (41547.03 2.51%) ->
21195.52 (21656.85 1.08%):  1.96x speedup
    █
    image-rgba       firefox-planet-gnome-0    217512.61 (217636.80 0.06%) ->
123341.02 (123641.94 0.12%):  1.76x speedup
    ▊
    image-rgba             swfdec-youtube-0    41302.71 (41373.60 0.11%) ->
31343.93 (31488.87 0.23%):  1.32x speedup
    ▍
    image-rgba         swfdec-giant-steps-0    20699.54 (20739.52 0.10%) ->
17360.19 (17375.51 0.04%):  1.19x speedup
    ▎
    image-rgba                       gvim-0    167837.47 (168027.68 0.51%) ->
151105.94 (151635.85 0.18%):  1.11x speedup
    ▏
    image-rgba          firefox-talos-svg-0    375273.43 (388250.94 1.60%) ->
356846.09 (370370.08 1.86%):  1.05x speedup

:040000 040000 90d6bcf2c8ef299cb61e134233ed63ca442423b6
12fd3709cd7e3df611e6b7fc0f5fa76ee335a3b8 M	src
:040000 040000 940c09e25135e41601d508259c1b11e4db51bd1a
dc8999c439acfb406c532f387e500747a9701603 M	test


-- 
Q: Because it reverses the logical flow of conversation.
A: Why is putting a reply at the top of the message frowned upon?


More information about the cairo mailing list