[cairo] Bug with paint_with_alpha and perfissues when compositing with SOURCE

Antoine Azar cairo at antoineazar.com
Tue May 27 12:15:43 PDT 2008


> Extending pixman to handle SOURCE the cairo way is certainly 
> possible, but the pain of adding stuff in pixman that:
> 
>  A) Does not match RENDER (as used by the xlib/xcb backends)
>  B) Does not match what can easily be done with 3D hardware (glitz
>     backend, future Direct3D backend)

Shaders can allow us to implement any operation, so for sure that will be
possible to implement in a Direct3D backend. In which case we'll have to let
that backend handle SOURCE and CLEAR natively, with or without mask if we
want to take advantage of that.

> Is considerable... right now, the cairo-surface-fallback.c 
> code is used for all raster backends in basically the same way.
> 
> You'd have to have some pretty convincing examples where:
> 
>  A) You need to use masks with SOURCE
>  B) The current code is too slow and can't be made faster in obvious
>     ways without extending pixman.

Too slow is relative, but when I benchmarked I just found it really
surprising to find such big performance gaps for those tests. If no one
needs a speed boost in that area though, we just need to clarify the
definition in the doc and that's it.

Antoine



More information about the cairo mailing list