diff options
author | Ilia Mirkin <[email protected]> | 2016-11-09 14:31:25 -0500 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2016-11-09 20:11:57 -0500 |
commit | 828faaef40f9bd50cb75c2cde0d9393bc3fb6695 (patch) | |
tree | 4ab223adc58e1e6b5fb0d58d9d922dab08f4c78d /src | |
parent | 5be635d5e40d9741e456fb1711ec72896e572be5 (diff) |
swr: correct setting of independentAlphaBlendEnable
This setting is for whether color and alpha have different blend
settings, not for whether blending is enabled on a per-RT basis.
Signed-off-by: Ilia Mirkin <[email protected]>
Reviewed-by: Tim Rowley <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/gallium/drivers/swr/swr_state.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/gallium/drivers/swr/swr_state.cpp b/src/gallium/drivers/swr/swr_state.cpp index d19acfbb347..65327f39d02 100644 --- a/src/gallium/drivers/swr/swr_state.cpp +++ b/src/gallium/drivers/swr/swr_state.cpp @@ -1318,7 +1318,12 @@ swr_update_derived(struct pipe_context *pipe, compileState.desc.alphaTestEnable = ctx->depth_stencil->alpha.enabled; compileState.desc.independentAlphaBlendEnable = - ctx->blend->pipe.independent_blend_enable; + (compileState.blendState.sourceBlendFactor != + compileState.blendState.sourceAlphaBlendFactor) || + (compileState.blendState.destBlendFactor != + compileState.blendState.destAlphaBlendFactor) || + (compileState.blendState.colorBlendFunc != + compileState.blendState.alphaBlendFunc); compileState.desc.alphaToCoverageEnable = ctx->blend->pipe.alpha_to_coverage; compileState.desc.sampleMaskEnable = 0; // XXX |