diff options
| author | Simon Robertshaw <simon@hardwired.org.uk> | 2012-07-27 20:04:00 (GMT) |
|---|---|---|
| committer | Simon Robertshaw <simon@hardwired.org.uk> | 2012-07-27 20:04:00 (GMT) |
| commit | 385552ceab18ed968f12f6612159452510415048 (patch) | |
| tree | 4b9477b186c1e412ffb18d54d4cb21f57fc8d9cd /src/graphics/Graphics.cpp | |
| parent | b612c076ebf255655160274e9665faa16c6c5b9e (diff) | |
| download | powder-385552ceab18ed968f12f6612159452510415048.zip powder-385552ceab18ed968f12f6612159452510415048.tar.gz | |
Correct blending of SetPixel without alpha channel
Diffstat (limited to 'src/graphics/Graphics.cpp')
| -rw-r--r-- | src/graphics/Graphics.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/graphics/Graphics.cpp b/src/graphics/Graphics.cpp index 2b12b1d..ac6878c 100644 --- a/src/graphics/Graphics.cpp +++ b/src/graphics/Graphics.cpp @@ -73,7 +73,7 @@ TPT_INLINE void VideoBuffer::SetPixel(int x, int y, int r, int g, int b, int a) #ifdef PIX32OGL Buffer[y*(Width)+x] = PIXRGBA(r,g,b,a); #else - Buffer[y*(Width)+x] = PIXRGB(r,g,b); + Buffer[y*(Width)+x] = PIXRGB((r*a)>>8, (g*a)>>8, (b*a)>>8); #endif } |
