[gtk+/gtk-2-24] [gdkcairo] Fix color premultiplication



commit 2eade26e68e6379755762f05ac909d5e3f80aa31
Author: Behdad Esfahbod <behdad behdad org>
Date:   Mon Sep 9 12:07:25 2013 -0400

    [gdkcairo] Fix color premultiplication
    
    https://bugzilla.gnome.org/show_bug.cgi?id=513812

 gdk/gdkcairo.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gdk/gdkcairo.c b/gdk/gdkcairo.c
index c423871..2ad77d1 100644
--- a/gdk/gdkcairo.c
+++ b/gdk/gdkcairo.c
@@ -247,7 +247,7 @@ gdk_cairo_set_source_pixbuf (cairo_t         *cr,
          guchar *end = p + 4 * width;
          guint t1,t2,t3;
            
-#define MULT(d,c,a,t) G_STMT_START { t = c * a + 0x7f; d = ((t >> 8) + t) >> 8; } G_STMT_END
+#define MULT(d,c,a,t) G_STMT_START { t = c * a + 0x80; d = ((t >> 8) + t) >> 8; } G_STMT_END
 
          while (p < end)
            {


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]