diff options
author | Nian Wu <[email protected]> | 2007-03-16 17:00:24 +0800 |
---|---|---|
committer | Nian Wu <[email protected]> | 2007-03-16 17:00:24 +0800 |
commit | a02870f4f61a66560b3eb75f98a7fe57ebcb6ed6 (patch) | |
tree | 8f1ecfc19e60d583969fa1e34c24e86e877ef2f6 /src/mesa/shader/program.h | |
parent | d63eef4b86af02aea5b26f90de9cf3d46aee398c (diff) | |
parent | 95764262a7f2dfda761a0dbd87c3d9b12df0d534 (diff) |
Merge git://proxy01.pd.intel.com:9419/git/mesa/mesa into crestline
Diffstat (limited to 'src/mesa/shader/program.h')
-rw-r--r-- | src/mesa/shader/program.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mesa/shader/program.h b/src/mesa/shader/program.h index a0bde077629..7746289621b 100644 --- a/src/mesa/shader/program.h +++ b/src/mesa/shader/program.h @@ -53,6 +53,13 @@ #define MAKE_SWIZZLE4(a,b,c,d) (((a)<<0) | ((b)<<3) | ((c)<<6) | ((d)<<9)) #define SWIZZLE_NOOP MAKE_SWIZZLE4(0,1,2,3) + +#define SWIZZLE_XYZW MAKE_SWIZZLE4(SWIZZLE_X, SWIZZLE_Y, SWIZZLE_Z, SWIZZLE_W) +#define SWIZZLE_XXXX MAKE_SWIZZLE4(SWIZZLE_X, SWIZZLE_X, SWIZZLE_X, SWIZZLE_X) +#define SWIZZLE_YYYY MAKE_SWIZZLE4(SWIZZLE_Y, SWIZZLE_Y, SWIZZLE_Y, SWIZZLE_Y) +#define SWIZZLE_ZZZZ MAKE_SWIZZLE4(SWIZZLE_Z, SWIZZLE_Z, SWIZZLE_Z, SWIZZLE_Z) +#define SWIZZLE_WWWW MAKE_SWIZZLE4(SWIZZLE_W, SWIZZLE_W, SWIZZLE_W, SWIZZLE_W) + #define GET_SWZ(swz, idx) (((swz) >> ((idx)*3)) & 0x7) #define GET_BIT(msk, idx) (((msk) >> (idx)) & 0x1) @@ -121,6 +128,9 @@ extern struct prog_instruction * _mesa_realloc_instructions(struct prog_instruction *oldInst, GLuint numOldInst, GLuint numNewInst); +extern struct prog_instruction * +_mesa_copy_instructions (struct prog_instruction *dest, + const struct prog_instruction *src, GLuint n); /** * Used for describing GL state referenced from inside ARB vertex and |