vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
New commits: commit 92e00f2e536ce0458961d329a3c676acc86249e6 Author: Ivan Timofeev <timofeev....@gmail.com> Date: Thu Aug 2 16:06:33 2012 +0400 cairo uses pre-multiplied alpha Change-Id: I6cf04b10bfdd6c7b16761b2aa2f31c1392c49546 diff --git a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx index 5e0972f..4298493 100644 --- a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx +++ b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx @@ -972,9 +972,9 @@ void GtkSalGraphics::renderAreaToPix( cairo_t *cr, for (int x = 0; x < awidth && y < aheight; ++x) { double alpha = ((float)cairo_data[x*4 + 3])/255.0; - src[x*3 + 0] = src[x*3 + 0] * (1.0 - alpha) + cairo_data[x*4+0] * alpha; - src[x*3 + 1] = src[x*3 + 1] * (1.0 - alpha) + cairo_data[x*4+1] * alpha; - src[x*3 + 2] = src[x*3 + 2] * (1.0 - alpha) + cairo_data[x*4+2] * alpha; + src[x*3 + 0] = src[x*3 + 0] * (1.0 - alpha) + cairo_data[x*4+0]; + src[x*3 + 1] = src[x*3 + 1] * (1.0 - alpha) + cairo_data[x*4+1]; + src[x*3 + 2] = src[x*3 + 2] * (1.0 - alpha) + cairo_data[x*4+2]; } src += nStride; cairo_data += cairo_stride; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits