mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-22 04:10:40 +01:00
panfrost: Disable early-z when alpha test is used
Fixes rendering artefacts in Minetest on Midgard.
Fixes: 275277a2b4 ("panfrost: Implement alpha testing natively")
Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/9676>
This commit is contained in:
parent
9d947127d3
commit
ae62fb3737
1 changed files with 2 additions and 1 deletions
|
|
@ -490,7 +490,8 @@ panfrost_prepare_midgard_fs_state(struct panfrost_context *ctx,
|
|||
|
||||
/* Reasons to disable early-Z from a shader perspective */
|
||||
bool late_z = fs->info.fs.can_discard || fs->info.writes_global ||
|
||||
fs->info.fs.writes_depth || fs->info.fs.writes_stencil;
|
||||
fs->info.fs.writes_depth || fs->info.fs.writes_stencil ||
|
||||
(zsa->alpha_func != MALI_FUNC_ALWAYS);
|
||||
|
||||
/* If either depth or stencil is enabled, discard matters */
|
||||
bool zs_enabled =
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue