summaryrefslogtreecommitdiffstats
path: root/src/mesa/shader/slang/slang_ir.h
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-01-18 15:35:44 -0700
committerBrian <[email protected]>2007-01-18 15:35:44 -0700
commitd70771752f7df031c4fd9a7ad17ddcef6d91377a (patch)
treefc97d1cabaaf5e7a006adf3a74c34ecb880ba4c8 /src/mesa/shader/slang/slang_ir.h
parentd885ff470a7d52f59538bd0ff3e2abb2452279ec (diff)
Reimplement code for swizzling so that expressions like (p+q).x for vectors p and q works correctly.
Diffstat (limited to 'src/mesa/shader/slang/slang_ir.h')
-rw-r--r--src/mesa/shader/slang/slang_ir.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mesa/shader/slang/slang_ir.h b/src/mesa/shader/slang/slang_ir.h
index 7fe3f7f153b..34dd1bb6910 100644
--- a/src/mesa/shader/slang/slang_ir.h
+++ b/src/mesa/shader/slang/slang_ir.h
@@ -83,6 +83,7 @@ typedef enum
IR_VAR, /* variable reference */
IR_VAR_DECL,/* var declaration */
IR_ELEMENT, /* array element */
+ IR_SWIZZLE, /* swizzled storage access */
IR_TEX, /* texture lookup */
IR_TEXB, /* texture lookup with LOD bias */
IR_TEXP, /* texture lookup with projection */
@@ -101,6 +102,7 @@ typedef struct
enum register_file File; /**< PROGRAM_TEMPORARY, PROGRAM_INPUT, etc */
GLint Index; /**< -1 means unallocated */
GLint Size; /**< number of floats */
+ GLuint Swizzle;
} slang_ir_storage;
@@ -113,11 +115,10 @@ typedef struct slang_ir_node_
struct slang_ir_node_ *Children[2];
const char *Comment;
const char *Target;
- GLuint Swizzle;
GLuint Writemask; /**< If Opcode == IR_MOVE */
GLfloat Value[4]; /**< If Opcode == IR_FLOAT */
slang_variable *Var;
- slang_ir_storage *Store;
+ slang_ir_storage *Store; /**< location of result of this operation */
} slang_ir_node;