From a531513b06be45868bc4d4f6a9757fe6992ef304 Mon Sep 17 00:00:00 2001 From: Christoph Bumiller Date: Thu, 2 Jun 2011 14:01:24 +0200 Subject: [PATCH] d3d1x/sm4: fix swizzle for 1 component operands For example, "mov o0.w, l(1)" would use imm_values[3], which is not valid. --- src/gallium/state_trackers/d3d1x/d3d1xshader/src/sm4_parse.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/state_trackers/d3d1x/d3d1xshader/src/sm4_parse.cpp b/src/gallium/state_trackers/d3d1x/d3d1xshader/src/sm4_parse.cpp index 2c0f8269af3..de4a1e551e2 100644 --- a/src/gallium/state_trackers/d3d1x/d3d1xshader/src/sm4_parse.cpp +++ b/src/gallium/state_trackers/d3d1x/d3d1xshader/src/sm4_parse.cpp @@ -91,6 +91,7 @@ struct sm4_parser break; case SM4_OPERAND_COMPNUM_1: op.comps = 1; + op.swizzle[1] = op.swizzle[2] = op.swizzle[3] = 0; break; case SM4_OPERAND_COMPNUM_4: op.comps = 4; -- 2.30.2