[cairo] Best strategy for complex screen drawing

Jeff Smith whydoubt at yahoo.com
Sat Nov 26 06:49:54 PST 2005


--- Alexander Larsson <alexl at redhat.com> wrote:
> On Fri, 2005-11-25 at 18:07 +0100, Timothée Lecomte wrote:
> 
> >     cairo_set_line_width(cr, 1);
> >     cairo_stroke(cr);
> 
> Why are you stroking each polygon? That is a pretty complicated
> operation and doesn't seem necessary for producing the kind of image you
> show in your screenshot.
> 
> Maybe this is an issue with "seams" between the polygons? If so, you
> need to render all the polygons comprising the larger 3d surface using
> CAIRO_OPERATOR_ADD to a temporary cairo surface and then composite that
> to the real cairo surface (using CAIRO_OPERATOR_OVER, or whatever mode
> you currently use).

There is an in-house application where I work that I am trying to covert to using cairo. 
The stroke solution had been used to deal with the seam isue.  I had done some speed
testing, with and without the stroking.  A BIG THANKS in advance if this works, as it
should reduce the time to render a frame by 60% (IIRC).

 -- Jeff Smith


	
		
__________________________________ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com


More information about the cairo mailing list