diff options
author | Jakob Bornecrantz <[email protected]> | 2009-11-16 22:57:43 +0100 |
---|---|---|
committer | Jakob Bornecrantz <[email protected]> | 2009-11-16 23:33:45 +0100 |
commit | cb060f3b987c9fa07ebe06cf2e7e54d1eaded1e1 (patch) | |
tree | 857e08954e1c4c1aa462d0634f08a4c0d1eaf8aa /src/gallium/state_trackers/xorg/xorg_composite.c | |
parent | 5438ee3ecfe5c25102d196fd6d7258201e27e6ca (diff) |
st/xorg: Fix comp alpha code and deal with luminance masks
There are two fixes in here one is a one liner that fixes
component alpha logic. The other deals better with luminance
formats used for masks, sources not yet implemented.
Fixes component alpha text and icons in gnome. There are a one
or two cases that this code misses. Like if src_luminance is set
but no mask image is given.
Diffstat (limited to 'src/gallium/state_trackers/xorg/xorg_composite.c')
-rw-r--r-- | src/gallium/state_trackers/xorg/xorg_composite.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/state_trackers/xorg/xorg_composite.c b/src/gallium/state_trackers/xorg/xorg_composite.c index 1ff19a2a5c0..93a3e1b8cf0 100644 --- a/src/gallium/state_trackers/xorg/xorg_composite.c +++ b/src/gallium/state_trackers/xorg/xorg_composite.c @@ -235,8 +235,11 @@ picture_format_fixups(struct exa_pixmap_priv *pSrc, PicturePtr pSrcPicture, bool boolean swizzle = FALSE; unsigned ret = 0; - if (pSrc->picture_format == pSrcPicture->format) + if (pSrc->picture_format == pSrcPicture->format) { + if (pSrc->picture_format == PICT_a8) + return mask ? FS_MASK_LUMINANCE : FS_MASK_LUMINANCE; return 0; + } if (pSrc->picture_format != PICT_a8r8g8b8) { assert(!"can not handle formats"); |