diff options
author | Dave Airlie <[email protected]> | 2011-12-30 20:10:26 +0000 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2011-12-31 12:37:48 +0000 |
commit | 24668a38d176607dec5eee9ae351076487b57542 (patch) | |
tree | 0b430ceec09f99688df4d5e1eb47d11e4402da24 /src | |
parent | 99fbf7ce341c346631d11395c792a0589c5035dd (diff) |
llvmpipe: fix blending for intensity formats
This fixes the piglit fbo-blending-formats test for standard, ARB_texture_float
and EXT_texture_snorm.
Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/drivers/llvmpipe/lp_state_fs.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_state_fs.c b/src/gallium/drivers/llvmpipe/lp_state_fs.c index 5af74fe7925..53e35ef6b3e 100644 --- a/src/gallium/drivers/llvmpipe/lp_state_fs.c +++ b/src/gallium/drivers/llvmpipe/lp_state_fs.c @@ -1294,7 +1294,8 @@ make_variant_key(struct llvmpipe_context *lp, * * Also, force rgb/alpha func/factors match, to make AoS blending easier. */ - if (format_desc->swizzle[3] > UTIL_FORMAT_SWIZZLE_W) { + if (format_desc->swizzle[3] > UTIL_FORMAT_SWIZZLE_W || + format_desc->swizzle[3] == format_desc->swizzle[0]) { blend_rt->rgb_src_factor = force_dst_alpha_one(blend_rt->rgb_src_factor); blend_rt->rgb_dst_factor = force_dst_alpha_one(blend_rt->rgb_dst_factor); blend_rt->alpha_func = blend_rt->rgb_func; |