Removed the NDS hack for ARGB1555 surfaces, since it's a general problem; added full color expansion for 16 bpp packed pixels.

This commit is contained in:
Sam Lantinga 2011-03-07 01:34:38 -08:00
parent e43f8d8003
commit 1c83266beb
5 changed files with 79 additions and 68 deletions

View file

@ -97,7 +97,6 @@ BlitNto1PixelAlpha(SDL_BlitInfo * info)
SDL_PixelFormat *dstfmt = info->dst_fmt;
int srcbpp = srcfmt->BytesPerPixel;
/* FIXME: fix alpha bit field expansion here too? */
while (height--) {
/* *INDENT-OFF* */
DUFFS_LOOP4(
@ -2082,11 +2081,6 @@ BlitNtoNPixelAlpha(SDL_BlitInfo * info)
srcbpp = srcfmt->BytesPerPixel;
dstbpp = dstfmt->BytesPerPixel;
/* FIXME: for 8bpp source alpha, this doesn't get opaque values
quite right. for <8bpp source alpha, it gets them very wrong
(check all macros!)
It is unclear whether there is a good general solution that doesn't
need a branch (or a divide). */
while (height--) {
/* *INDENT-OFF* */
DUFFS_LOOP4(