summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2018-10-04 19:34:34 -0700
committerKenneth Graunke <[email protected]>2019-02-21 10:26:09 -0800
commit9b229d266df169a58199fd86ac15bf709984dbe5 (patch)
tree5bc8363579fc34e33b0bb14b55368638910c556b /src/gallium/drivers
parent822f91508e7459d8b367be266d5fb8c5ce3e6b65 (diff)
iris: fix Z32_S8 depth sampling
We were accidentally using the ISL_FORMAT_R32_FLOAT_X8X24_TYPELESS format, which is NOT what we use. We just store R32_FLOAT depth. fixes Piglit's texwrap GL_ARB_depth_buffer_float
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r--src/gallium/drivers/iris/iris_formats.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/gallium/drivers/iris/iris_formats.c b/src/gallium/drivers/iris/iris_formats.c
index 2b1950eaf7e..fa77b5bcf67 100644
--- a/src/gallium/drivers/iris/iris_formats.c
+++ b/src/gallium/drivers/iris/iris_formats.c
@@ -55,15 +55,18 @@ iris_isl_format_for_pipe_format(enum pipe_format pf)
//[PIPE_FORMAT_L16_UNORM] = ISL_FORMAT_L16_UNORM,
//[PIPE_FORMAT_UYVY] = ISL_FORMAT_UYVY,
//[PIPE_FORMAT_YUYV] = ISL_FORMAT_YUYV,
+
[PIPE_FORMAT_Z16_UNORM] = ISL_FORMAT_R16_UNORM,
[PIPE_FORMAT_Z32_UNORM] = ISL_FORMAT_R32_UNORM,
[PIPE_FORMAT_Z32_FLOAT] = ISL_FORMAT_R32_FLOAT,
- /* XXX: separate stencil */
+
+ /* We translate the combined depth/stencil formats to depth only here */
[PIPE_FORMAT_Z24_UNORM_S8_UINT] = ISL_FORMAT_R24_UNORM_X8_TYPELESS,
- //[PIPE_FORMAT_S8_UINT_Z24_UNORM] = ISL_FORMAT_S8_UINT_Z24_UNORM,
[PIPE_FORMAT_Z24X8_UNORM] = ISL_FORMAT_R24_UNORM_X8_TYPELESS,
- //[PIPE_FORMAT_X8Z24_UNORM] = ISL_FORMAT_R24_UNORM_X8_TYPELESS,
+ [PIPE_FORMAT_Z32_FLOAT_S8X24_UINT] = ISL_FORMAT_R32_FLOAT,
+
[PIPE_FORMAT_S8_UINT] = ISL_FORMAT_R8_UINT,
+
[PIPE_FORMAT_R64_FLOAT] = ISL_FORMAT_R64_FLOAT,
[PIPE_FORMAT_R64G64_FLOAT] = ISL_FORMAT_R64G64_FLOAT,
[PIPE_FORMAT_R64G64B64_FLOAT] = ISL_FORMAT_R64G64B64_FLOAT,
@@ -167,7 +170,6 @@ iris_isl_format_for_pipe_format(enum pipe_format pf)
[PIPE_FORMAT_R10G10B10A2_USCALED] = ISL_FORMAT_R10G10B10A2_USCALED,
[PIPE_FORMAT_R11G11B10_FLOAT] = ISL_FORMAT_R11G11B10_FLOAT,
[PIPE_FORMAT_R9G9B9E5_FLOAT] = ISL_FORMAT_R9G9B9E5_SHAREDEXP,
- [PIPE_FORMAT_Z32_FLOAT_S8X24_UINT] = ISL_FORMAT_R32_FLOAT_X8X24_TYPELESS,
[PIPE_FORMAT_R1_UNORM] = ISL_FORMAT_R1_UNORM,
[PIPE_FORMAT_R10G10B10X2_USCALED] = ISL_FORMAT_R10G10B10X2_USCALED,
//[PIPE_FORMAT_R10G10B10X2_SNORM] = ISL_FORMAT_R10G10B10X2_SNORM,