Browse Source

Fixed bug 2639 - SDL_BLENDMODE_BLEND not working properly for software renderer, thanks to Melker Narikka

Sam Lantinga 10 years ago
parent
commit
fd1da994fa
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/render/software/SDL_draw.h

+ 2 - 1
src/render/software/SDL_draw.h

@@ -51,11 +51,12 @@ do { \
 
 #define DRAW_SETPIXEL_BLEND(getpixel, setpixel) \
 do { \
-    unsigned sr, sg, sb, sa; (void) sa; \
+    unsigned sr, sg, sb, sa; \
     getpixel; \
     sr = DRAW_MUL(inva, sr) + r; \
     sg = DRAW_MUL(inva, sg) + g; \
     sb = DRAW_MUL(inva, sb) + b; \
+    sa = DRAW_MUL(inva, sa) + a; \
     setpixel; \
 } while (0)