From e3eb6597e140b13a693ae20e053dad5f1ee67c97 Mon Sep 17 00:00:00 2001 From: Alexander Malmberg Date: Wed, 2 Apr 2003 12:07:34 +0000 Subject: [PATCH] Fix calculation up alpha in plusd_aa. Clean up some includes. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/back/trunk@16329 72102866-910b-0410-8b05-ffd578937521 --- ChangeLog | 6 ++++++ Source/art/ARTContext.m | 3 +++ Source/art/blit.h | 3 --- Source/art/blit.m | 4 +--- 4 files changed, 10 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 6c84c40..366c451 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2003-04-02 14:04 Alexander Malmberg + + * Source/art/ARTContext.m, Source/art/blit.h: Clean up includes. + + * Source/art/blit.m (plusd_aa): Fix calculation of alpha. + 2003-03-29 19:13 Alexander Malmberg * Source/art/ARTContext.m, Source/art/blit.h, Source/art/blit.m, diff --git a/Source/art/ARTContext.m b/Source/art/ARTContext.m index 720cacb..2ba5982 100644 --- a/Source/art/ARTContext.m +++ b/Source/art/ARTContext.m @@ -35,6 +35,9 @@ #include "ftfont.h" +#include + + #ifndef PI #define PI 3.14159265358979323846264338327950288 #endif diff --git a/Source/art/blit.h b/Source/art/blit.h index a87cace..0bee37f 100644 --- a/Source/art/blit.h +++ b/Source/art/blit.h @@ -24,9 +24,6 @@ #define blit_h -#include - - /** Information about how we draw stuff **/ diff --git a/Source/art/blit.m b/Source/art/blit.m index 2209fe0..a80c10f 100644 --- a/Source/art/blit.m +++ b/Source/art/blit.m @@ -31,8 +31,6 @@ This file includes itself. Many times. You have been warned. #include -#include "x11/XGServer.h" - #include "blit.h" #endif @@ -1142,7 +1140,7 @@ static void MPRE(plusd_aa) (composite_run_t *c, int num) dr += sr - 255; if (dr<0) dr = 0; dg += sg - 255; if (dg<0) dg = 0; db += sb - 255; if (db<0) db = 0; - da += sa - 255; if (da<0) da = 0; + da += sa; if (da>255) da = 255; BLEND_WRITE_ALPHA(d, dst_alpha, dr, dg, db, da)