Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files
Fixed bug 1638 - Blit Alpha surface bug
The DUFFS_LOOP_124() macro was trying to be too clever and wasn't doing the right thing, it was checking n & 4 instead of width.
I'm not sure how we didn't catch this before, but it should be fixed now.
  • Loading branch information
slouken committed Aug 1, 2013
1 parent acd09b2 commit 3f46cc367e9a8b4ad27b5001bb00102eb64012f2
Showing with 8 additions and 6 deletions.
  1. +8 −6 src/video/SDL_blit.h
@@ -510,13 +510,15 @@ do { \
if (n & 2) { \
pixel_copy_increment2; n -= 2; \
} \
if (n & 4) { \
pixel_copy_increment4; n -= 4; \
} \
if (n) { \
n = (n+7)/ 8; \
switch (n & 4) { \
case 0: do { pixel_copy_increment4; \
case 4: pixel_copy_increment4; \
} while (--n > 0); \
} \
n /= 8; \
do { \
pixel_copy_increment4; \
pixel_copy_increment4; \
} while (--n > 0); \
} \
}

0 comments on commit 3f46cc3

Please sign in to comment.