mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-09 14:50:11 +01:00
i965: Use brw_wm_prog_data::uses_kill, not gl_fragment_program::UsesKill
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:
parent
a0f8b363c0
commit
06372c3fa9
5 changed files with 7 additions and 6 deletions
|
|
@ -175,7 +175,8 @@ brw_upload_wm_unit(struct brw_context *brw)
|
|||
wm->wm5.program_computes_depth = 0;
|
||||
|
||||
/* _NEW_COLOR */
|
||||
wm->wm5.program_uses_killpixel = fp->UsesKill || ctx->Color.AlphaEnabled;
|
||||
wm->wm5.program_uses_killpixel =
|
||||
prog_data->uses_kill || ctx->Color.AlphaEnabled;
|
||||
|
||||
wm->wm5.enable_8_pix = 1;
|
||||
if (prog_data->prog_offset_16)
|
||||
|
|
|
|||
|
|
@ -188,7 +188,7 @@ upload_wm_state(struct brw_context *brw)
|
|||
GEN6_WM_BARYCENTRIC_INTERPOLATION_MODE_SHIFT;
|
||||
|
||||
/* _NEW_COLOR, _NEW_MULTISAMPLE */
|
||||
if (fp->program.UsesKill || ctx->Color.AlphaEnabled ||
|
||||
if (prog_data->uses_kill || ctx->Color.AlphaEnabled ||
|
||||
ctx->Multisample.SampleAlphaToCoverage ||
|
||||
prog_data->uses_omask)
|
||||
dw5 |= GEN6_WM_KILL_ENABLE;
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@ upload_wm_state(struct brw_context *brw)
|
|||
/* _NEW_COLOR, _NEW_MULTISAMPLE */
|
||||
/* Enable if the pixel shader kernel generates and outputs oMask.
|
||||
*/
|
||||
if (fp->program.UsesKill || ctx->Color.AlphaEnabled ||
|
||||
if (prog_data->uses_kill || ctx->Color.AlphaEnabled ||
|
||||
ctx->Multisample.SampleAlphaToCoverage ||
|
||||
prog_data->uses_omask) {
|
||||
dw1 |= GEN7_WM_KILL_ENABLE;
|
||||
|
|
|
|||
|
|
@ -286,7 +286,7 @@ pma_fix_enable(const struct brw_context *brw)
|
|||
(fp->Base.OutputsWritten & BITFIELD64_BIT(FRAG_RESULT_DEPTH)) &&
|
||||
fp->FragDepthLayout != FRAG_DEPTH_LAYOUT_UNCHANGED;
|
||||
|
||||
/* BRW_NEW_FRAGMENT_PROGRAM: 3DSTATE_PS_EXTRA::PixelShaderKillsPixels
|
||||
/* CACHE_NEW_WM_PROG: 3DSTATE_PS_EXTRA::PixelShaderKillsPixels
|
||||
* CACHE_NEW_WM_PROG: 3DSTATE_PS_EXTRA::oMask Present to RenderTarget
|
||||
* _NEW_MULTISAMPLE: 3DSTATE_PS_BLEND::AlphaToCoverageEnable
|
||||
* _NEW_COLOR: 3DSTATE_PS_BLEND::AlphaTestEnable
|
||||
|
|
@ -295,7 +295,7 @@ pma_fix_enable(const struct brw_context *brw)
|
|||
* 3DSTATE_WM::ForceKillPix != ForceOff is always true.
|
||||
*/
|
||||
const bool kill_pixel =
|
||||
fp->UsesKill ||
|
||||
brw->wm.prog_data->uses_kill ||
|
||||
brw->wm.prog_data->uses_omask ||
|
||||
(ctx->Multisample._Enabled && ctx->Multisample.SampleAlphaToCoverage) ||
|
||||
ctx->Color.AlphaEnabled;
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ upload_ps_extra(struct brw_context *brw)
|
|||
|
||||
dw1 |= GEN8_PSX_PIXEL_SHADER_VALID;
|
||||
|
||||
if (fp->program.UsesKill)
|
||||
if (prog_data->uses_kill)
|
||||
dw1 |= GEN8_PSX_KILL_ENABLE;
|
||||
|
||||
if (prog_data->num_varying_inputs != 0)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue