[gtk+/gtk-3-8] [gdkcairo] Fix color premultiplication



commit f68ad7b45a2dd323f086498231c4030101611d8e
Author: Behdad Esfahbod <behdad behdad org>
Date:   Thu Sep 5 18:42:45 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 2e1d8dc..1073e8f 100644
--- a/gdk/gdkcairo.c
+++ b/gdk/gdkcairo.c
@@ -250,7 +250,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]