YES, Faster blitting!

[Bob] My normal reply to this would be to tell you to
use OpenGL and use hardware acceleration to make it fast.

Of course. I had actualy written “requiring a 3D accelerator
is not an option” but I deleted it before sending the message.

[David Olofson] Yes - and looking at the performance
improvement when using RLE on alpha surfaces (antialiazed
sprites and stuff), I’m quite certain that SDL is already
doing what you suggest.

Wow! You’re right, SDL already does this, at least from 1.2.5
(the oldest source I looked at). In an extremely informal and
unscientific test, addding this line

SDL_SetAlpha(pImage, SDL_SRCALPHA | SDL_RLEACCEL, 255)

gave me a 21% increase in speed! (115 FPS to 141 FPS)

This is great! Who doesn’t love a free 21% boost in
performance? :slight_smile:

--Gabriel

Ing. Gabriel Gambetta
ARTech - GeneXus Development Team
ggambett at artech.com.uy