[Mesa-dev] [PATCH] i965: Don't use CUBE wrap modes for integer formats.
Kenneth Graunke
kenneth at whitecape.org
Tue Mar 29 05:36:21 UTC 2016
There is no linear filtering for integer formats, so we should always
be using CLAMP_TO_EDGE mode.
Fixes 46 dEQP cases on Ivybridge.
This workaround doesn't appear to be necessary on later hardware, and
I haven't found any documentation mentioning errata in this area.
However, it seems harmless to apply generally, so we may as well.
Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
---
src/mesa/drivers/dri/i965/brw_sampler_state.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/mesa/drivers/dri/i965/brw_sampler_state.c b/src/mesa/drivers/dri/i965/brw_sampler_state.c
index 7bd21f7..7e44cf5 100644
--- a/src/mesa/drivers/dri/i965/brw_sampler_state.c
+++ b/src/mesa/drivers/dri/i965/brw_sampler_state.c
@@ -463,7 +463,8 @@ brw_update_sampler_state(struct brw_context *brw,
/* Cube maps must use the same wrap mode for all three coordinate
* dimensions. Prior to Haswell, only CUBE and CLAMP are valid.
*/
- if (tex_cube_map_seamless || sampler->CubeMapSeamless) {
+ if ((tex_cube_map_seamless || sampler->CubeMapSeamless) &&
+ !is_integer_format) {
wrap_s = BRW_TEXCOORDMODE_CUBE;
wrap_t = BRW_TEXCOORDMODE_CUBE;
wrap_r = BRW_TEXCOORDMODE_CUBE;
--
2.7.4
More information about the mesa-dev
mailing list