radv: Fix RB+ blending for VK_FORMAT_E5B9G9R9_UFLOAT_PACK32.

Fixes: e893102bcf ("radv: Add VK_FORMAT_E5B9G9R9_UFLOAT_PACK32 rendering support.")
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7716>
This commit is contained in:
Bas Nieuwenhuizen
2020-11-21 20:58:37 +01:00
committed by Marge Bot
parent 0742edba5e
commit 025cb90042
2 changed files with 5 additions and 3 deletions
+5
View File
@@ -1119,6 +1119,11 @@ radv_emit_rbplus_state(struct radv_cmd_buffer *cmd_buffer)
has_alpha = false;
}
/* The HW doesn't quite blend correctly with rgb9e5 if we disable the alpha
* optimization, even though it has no alpha. */
if (has_rgb && format == V_028C70_COLOR_5_9_9_9)
has_alpha = true;
/* Disable value checking for disabled channels. */
if (!has_rgb)
sx_blend_opt_control |= S_02875C_MRT0_COLOR_OPT_DISABLE(1) << (i * 4);