Fixed parsing details of swizzles.
authorRyan C. Gordon <icculus@icculus.org>
Tue, 03 Feb 2009 17:16:32 -0500
changeset 548 b37cdacb50d5
parent 547 90ea52905fca
child 549 13714d3b3fa2
Fixed parsing details of swizzles.
mojoshader_assembler.c
--- a/mojoshader_assembler.c	Tue Feb 03 17:06:09 2009 -0500
+++ b/mojoshader_assembler.c	Tue Feb 03 17:16:32 2009 -0500
@@ -1032,6 +1032,8 @@
 
         if (saw_xyzw && saw_rgba)
             invalid_swizzle = 1;
+        else if (saw_rgba && !shader_is_pixel(ctx))
+            invalid_swizzle = 1;
     } // else
 
     if (invalid_swizzle)