瀏覽代碼

swr: disable logic op when the rt format is float or srgb

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Tim Rowley <timothy.o.rowley@intel.com>
tags/17.0-branchpoint
Ilia Mirkin 9 年之前
父節點
當前提交
f037afb701
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6
    0
      src/gallium/drivers/swr/swr_state.cpp

+ 6
- 0
src/gallium/drivers/swr/swr_state.cpp 查看文件

@@ -1305,6 +1305,12 @@ swr_update_derived(struct pipe_context *pipe,
&ctx->blend->compileState[target],
sizeof(compileState.blendState));

const SWR_FORMAT_INFO& info = GetFormatInfo(compileState.format);
if (compileState.blendState.logicOpEnable &&
((info.type[0] == SWR_TYPE_FLOAT) || info.isSRGB)) {
compileState.blendState.logicOpEnable = false;
}

if (compileState.blendState.blendEnable == false &&
compileState.blendState.logicOpEnable == false &&
ctx->depth_stencil->alpha.enabled == 0) {

Loading…
取消
儲存