[cairo] Flash performance comparison?

Jeff Muizelaar jeff at infidigm.net
Sat Apr 14 00:21:08 PDT 2007

On Tue, Apr 10, 2007 at 10:18:21PM -0700, Vladimir Vukicevic wrote:
> The recent discussion about Flash blending modes got me thinking; anyone 
> out there with Flash knowledge interested in doing a Flash vs. Cairo 
> performance comparison?  Adapting some of the cairo-perf benchmarks 
> would probably be the easiest way to go about it.  Flash is one of the 
> few cross-platform 2d graphics libraries that are in (very) wide usage, 
> and I think cairo should be able to compete against it successfully 
> (this would be especially interesting for me for Mozilla, where cairo 
> competes against Flash directly via SVG and <canvas>).
> Any interested takers?  I'd be willing to offer any help on the 
> ActionScript side that I can (and the cairo side, as necessary).

I'm interested but I don't have very much Flash knowledege or a lot of

The easiest way that I can see to do a comparison is probably using
libswfdec. However, the hard part is actually measuring the performance
of Flash. If anyone has any ideas for how to do it I'd be interested to
hear them. This is the best I could come up with:

It looks like flash basically does all of its rendering using
ShmPutImage so counting these would give some idea of the
frames-per-second. Unfortunately, cairo doesn't support using
ShmPutImage directly so a tool that uses the image surface and
ShmPutImage would need to be written.

The ShmPutImage counting could be done using something like xtrace or an
LD_PRELOAD shared library.


More information about the cairo mailing list