mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 02:58:05 +02:00
anv/gen8: Fix SF_CLIP_VIEWPORT's Z elements
SF_CLIP_VIEWPORT does not clamp Z values. It only scales and shifts them. Clamping to VkViewport::minDepth,maxDepth is instead handled by CC_VIEWPORT. Fixes dEQP-VK.renderpass.simple.depth on Broadwell.
This commit is contained in:
parent
842b424d3b
commit
1afe33f8b3
1 changed files with 2 additions and 2 deletions
|
|
@ -88,10 +88,10 @@ emit_viewport_state(struct anv_cmd_buffer *cmd_buffer,
|
|||
struct GENX(SF_CLIP_VIEWPORT) sf_clip_viewport = {
|
||||
.ViewportMatrixElementm00 = vp->width / 2,
|
||||
.ViewportMatrixElementm11 = vp->height / 2,
|
||||
.ViewportMatrixElementm22 = (vp->maxDepth - vp->minDepth) / 2,
|
||||
.ViewportMatrixElementm22 = 1.0,
|
||||
.ViewportMatrixElementm30 = vp->x + vp->width / 2,
|
||||
.ViewportMatrixElementm31 = vp->y + vp->height / 2,
|
||||
.ViewportMatrixElementm32 = (vp->maxDepth + vp->minDepth) / 2,
|
||||
.ViewportMatrixElementm32 = 0.0,
|
||||
.XMinClipGuardband = -1.0f,
|
||||
.XMaxClipGuardband = 1.0f,
|
||||
.YMinClipGuardband = -1.0f,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue