Colorkey blitting problem

I was having some trouble with certain blits failing.? I traced it down to the function SDL_CalculateBlit1, where the switch has a case for SDL_COPY_COLORKEY, but not for SDL_COPY_COLORKEY | SDL_COPY_BLEND, which is what my code was setting.? Any reason why they shouldn’t both be valid and equivalent to one another?

Mason

Colorkey is a single transparent pixel. Blend indicates that each pixel
has an alpha value. I think the current set of blitters don’t handle both
at the same time to reduce the combinatorial set of blitters, and because
it would be relatively slow using the generic blitter. You’re welcome to
submit a patch to support it though.On Tue, Jul 2, 2013 at 12:53 PM, Mason Wheeler wrote:

I was having some trouble with certain blits failing. I traced it down to
the function SDL_CalculateBlit1, where the switch has a case for
SDL_COPY_COLORKEY, but not for SDL_COPY_COLORKEY | SDL_COPY_BLEND, which is
what my code was setting. Any reason why they shouldn’t both be valid and
equivalent to one another?

Mason


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org