Re: GTK+, Cairo, XLib integration for fast 2D graphics drawing
Christos Sotiriou <[email protected]>
| Newsgroups | gmane.comp.lib.cairo |
|---|---|
| Message-ID | <CANp+zOEsxkvFoBar3Yzeu_wWxgTwfN--J1j88deYi58dbXcfzw@mail.gmail.com> |
On 19 March 2012 20:27, Chris Wilson <[email protected]> wrote: > > Thanks. So it appears the bulk of your rendering is in the form of lots > of tiny stroked rectangles, correct? > > Yes, this is it; most of the objects I draw on the map are small stroked rectangles. > stroke: count 255357 [no-op 0], elapsed 1112598240 [97.4%] > extents: total 5843148, avg 22.882 [unbounded 0] > op: 255357 OVER > source: 255357 solid > path: 255351 rectliinear, 6 straight > antialias: 255357 default > caps: 255357 butt > joins: 255357 miter > clip: 255306 none, 51 region > > The truly puzzling part for me is that they seem viable candidates to > hit the fast-paths, yet end up in the general polygon code. > > << /content //COLOR_ALPHA /width 500 /height 500 >> surface context > n 22.726562 22.726562 454.546875 454.546875 rectangle > 0 0.65 1 rgb set-source > 0.295602 0.913843 scale > 3.655372 set-line-width > stroke+ > pop > > Oh, I see. A non-uniform, non-integer scale factor. That would explain > it. Let's see if I can cook up something faster for you. > I can round the scaling factor for the cairo_scale() function call; would that make a big performance difference? Thanks for looking into this, Christos. -- -------------------------------------------------------------------------- Christos P. Sotiriou email: [email protected] Cell: +30 697 8984 222 -- cairo mailing list [email protected] http://lists.cairographics.org/mailman/listinfo/cairo