mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 06:58:05 +02:00
radv: fix stencil only clears.
If we are clearing stencil only, we still need to provide a
a valid Z output from the vertex shader, we can't rely
on the depth clear value having any meaning, as we use this
for the position output, and it could get clipped, so we
don't end up clearing anything.
Fixes:
dEQP-VK.renderpass.simple.stencil
since I added S8 support.
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Signed-off-by: Dave Airlie <airlied@redhat.com>
(cherry picked from commit 3c73063974)
This commit is contained in:
parent
9105e36765
commit
9b808c5748
1 changed files with 3 additions and 0 deletions
|
|
@ -693,6 +693,9 @@ emit_depthstencil_clear(struct radv_cmd_buffer *cmd_buffer,
|
|||
VK_IMAGE_ASPECT_STENCIL_BIT));
|
||||
assert(pass_att != VK_ATTACHMENT_UNUSED);
|
||||
|
||||
if (!(aspects & VK_IMAGE_ASPECT_DEPTH_BIT))
|
||||
clear_value.depth = 1.0f;
|
||||
|
||||
const struct depthstencil_clear_vattrs vertex_data[3] = {
|
||||
{
|
||||
.position = {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue