Fix colorkeying in pixman_utils.c

We were masking out the alpha bit in the key color not int
the source pixel, so colorkeying didn't work when the high byte
was != 0. For instance in the shutdown dialog in XP.
This commit is contained in:
Alexander Larsson 2010-03-08 19:41:34 +01:00
parent 4f097150cb
commit 04b35fe7ff

View File

@ -816,10 +816,11 @@ void spice_pixman_blit_colorkey (pixman_image_t *dest,
uint32_t *d = (uint32_t *)byte_line;
uint32_t *s = (uint32_t *)byte_line;
transparent_color &= 0xffffff;
s = (uint32_t *)src_line;
for (x = 0; x < width; x++) {
uint32_t val = *s;
if (val != (0xffffff & transparent_color)) {
if ((0xffffff & val) != transparent_color) {
*d = val;
}
s++; d++;