diff options
Diffstat (limited to 'driver/xf86-video-geode/src/lx_exa.c')
-rw-r--r-- | driver/xf86-video-geode/src/lx_exa.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/driver/xf86-video-geode/src/lx_exa.c b/driver/xf86-video-geode/src/lx_exa.c index 31f9b0e38..b267cc0fb 100644 --- a/driver/xf86-video-geode/src/lx_exa.c +++ b/driver/xf86-video-geode/src/lx_exa.c @@ -582,6 +582,12 @@ lx_check_composite(int op, PicturePtr pSrc, PicturePtr pMsk, PicturePtr pDst) if (pSrc->format == PICT_a8 || pDst->format == PICT_a8) return FALSE; + if (pMsk && op != PictOpClear) { + /* We can only do masks with a 8bpp or a 4bpp mask */ + if (pMsk->format != PICT_a8 && pMsk->format != PICT_a4) + return FALSE; + } + return TRUE; } @@ -638,11 +644,6 @@ lx_prepare_composite(int op, PicturePtr pSrc, PicturePtr pMsk, struct blend_ops_t *opPtr = &lx_alpha_ops[op * 2]; int direction = (opPtr->channel == CIMGP_CHANNEL_A_SOURCE) ? 0 : 1; - /* We can only do masks with a 8bpp or a 4bpp mask */ - - if (pMsk->format != PICT_a8 && pMsk->format != PICT_a4) - return FALSE; - /* Direction 0 indicates src->dst, 1 indiates dst->src */ if (((direction == 0) && (pxSrc->drawable.bitsPerPixel < 16)) || |