rsx: Fix alpha testing

- We no longer reload fragment state when toggling alpha-test. Instead, a different shader variant is picked.
This commit is contained in:
kd-11 2025-12-15 00:43:26 +03:00
parent 4fd3e536d0
commit a7e0e4d76e

View File

@ -680,12 +680,9 @@ namespace rsx
ROP_control_t rop_control{}; ROP_control_t rop_control{};
alignas(16) fragment_context_t payload{}; alignas(16) fragment_context_t payload{};
if (REGS(m_ctx)->alpha_test_enabled()) // Always encode the alpha function. Toggling alpha-test is not guaranteed to trigger context param reload anymore.
{ const u32 alpha_func = static_cast<u32>(REGS(m_ctx)->alpha_func());
const u32 alpha_func = static_cast<u32>(REGS(m_ctx)->alpha_func()); rop_control.set_alpha_test_func(alpha_func);
rop_control.set_alpha_test_func(alpha_func);
rop_control.enable_alpha_test();
}
// Generate wpos coefficients // Generate wpos coefficients
// wpos equation is now as follows (ignoring pixel center offset): // wpos equation is now as follows (ignoring pixel center offset):