Mattias Engdeg?rd wrote:
Okay, this is the bit that doesn’t make sense to me. Why is SDL_SRCALPHA
set if Amask != 0?
I think it was Sam who put it in so I’ll let him answer. Anyway it’s just
but rather a behaviour for SDL_BlitSurface. It seems like [SDL_SRCALPHA]
would make more sense for SDL_SRCALPHA to be given in a “flags” argument
to SDL_BlitSurface than being a surface property.
my opinion as well and one of many things I would like to change for
an API revision, but in 1.2 we’re stuck with this
Okay, fair enough.
SDL_SetAlpha(rgba, rgba->flags & (SDL_RLEACCEL | SDL_RLEACCELOK), 0);
and it should work. This is another quirk: when you set SDL_RLEACCEL
(either by calling SetAlpha or SetColorKey), SDL_RLEACCEL isn’t set at
once but just SDL_RLEACCELOK to mark the surface as RLE-able, and at
the next blit it will be RLE-coded and SDL_RLEACCEL will be set to
mark it as such
yes, this is another thing that should be cleaned up
Great, thanks for all your help.