glsl: fix a swizzle-related regression
authorBrian Paul <brianp@vmware.com>
Wed, 18 Feb 2009 18:06:57 +0000 (11:06 -0700)
committerBrian Paul <brianp@vmware.com>
Wed, 18 Feb 2009 20:15:13 +0000 (13:15 -0700)
This new issue was exposed by commit 6eabfc27f19a10dfc2663e99f9560966ba1ff697

src/mesa/shader/slang/slang_emit.c

index ac01462bd5519dc303d4d594a4373cc0cd0ae40c..feff1b7474deea04ae259db87d1ce13fa5820ce8 100644 (file)
@@ -164,7 +164,7 @@ _slang_var_swizzle(GLint size, GLint comp)
 {
    switch (size) {
    case 1:
-      return MAKE_SWIZZLE4(comp, comp, comp, comp);
+      return MAKE_SWIZZLE4(comp, SWIZZLE_NIL, SWIZZLE_NIL, SWIZZLE_NIL);
    case 2:
       return MAKE_SWIZZLE4(SWIZZLE_X, SWIZZLE_Y, SWIZZLE_NIL, SWIZZLE_NIL);
    case 3: