Hi, I was looking at how you were implementing the Cairo surface for
SDL. The idea is to get the pixel data address from SDL and pass it to
a Cairo software-rendering surface. This is then drawn on the SDL
surface by flipping.
Do you think it would be possible to use a Cairo native (accelerated)
surface instead? You can keep the software-rendering surface, and use
it for the final blit to the screen, but you'd do all the plotting on
the accelerated surface. If acceleration works well enough, performance
shouldn't be affected adversely (acceleration balances the additional
transfer):
before -> lock SDL surface
draw with software renderer on the locked SDL surface
unlock SDL surface
flip the SDL surface to screen
after -> draw with accelerated renderer on a separate surface
lock SDL surface
use cairo_paint to blit to the locked SDL surface
unlock SDL surface
flip the SDL surface to screen
Also, in this case is double buffering necessary? Is it a hindrance? I
don't know enough of this to understand the nuances... I guess I can
check the performance impact with your blitting example, but I just
wanted to check in advance if this idea is crazy...
Anyway, what's there works and it's going to stay like this for a while;
just that adding a TODO would be nice.
Paolo
_______________________________________________
help-smalltalk mailing list
[hidden email]
http://lists.gnu.org/mailman/listinfo/help-smalltalk