---
src/mesa/drivers/dri/i965/brw_fs_generator.cpp | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
index 974219f..dad541b 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
@@ -680,7 +680,15 @@ fs_generator::generate_tex(fs_inst *inst, struct brw_reg
dst, struct brw_reg src
switch (dst.type) {
case BRW_REGISTER_TYPE_D:
- return_format = BRW_SAMPLER_RETURN_FORMAT_SINT32;
+ /* SINT32 isn't actually allowed for TXS. This isn't explicitly stated
+ * in the PRM, but the i965 PRM explicitly lists UINT32 and FLOAT32 as
+ * being valid for resinfo but not SINT32 (Vol. 4 Section 4.8.1.1).
+ * Emperical testing has also verified this.
+ */
+ if (inst->opcode == SHADER_OPCODE_TXS)
+ return_format = BRW_SAMPLER_RETURN_FORMAT_UINT32;
+ else
+ return_format = BRW_SAMPLER_RETURN_FORMAT_SINT32;
break;
case BRW_REGISTER_TYPE_UD:
return_format = BRW_SAMPLER_RETURN_FORMAT_UINT32;
--
2.5.0.400.gff86faf
_______________________________________________
mesa-dev mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-dev