summaryrefslogtreecommitdiffstats
path: root/src/mesa/pipe
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-08-22 18:48:28 -0600
committerBrian <[email protected]>2007-08-22 18:52:40 -0600
commitace2b98dd3511ea6959980a2ae2ee90fa7c28748 (patch)
treeefb7bfd7379723c0ae12b9d1743e7f1444cbb198 /src/mesa/pipe
parent69ab4b23f5a67451e262b75f4a1a40949fc5868c (diff)
fix assertions in swizzle()
Diffstat (limited to 'src/mesa/pipe')
-rw-r--r--src/mesa/pipe/i915simple/i915_fpc.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mesa/pipe/i915simple/i915_fpc.h b/src/mesa/pipe/i915simple/i915_fpc.h
index afef7064187..af347c7c8cc 100644
--- a/src/mesa/pipe/i915simple/i915_fpc.h
+++ b/src/mesa/pipe/i915simple/i915_fpc.h
@@ -185,12 +185,12 @@ struct i915_fp_compile {
/* One neat thing about the UREG representation:
*/
static INLINE int
-swizzle(int reg, int x, int y, int z, int w)
+swizzle(int reg, uint x, uint y, uint z, uint w)
{
- assert(x < 4);
- assert(y < 4);
- assert(z < 4);
- assert(w < 4);
+ assert(x <= SRC_ONE);
+ assert(y <= SRC_ONE);
+ assert(z <= SRC_ONE);
+ assert(w <= SRC_ONE);
return ((reg & ~UREG_XYZW_CHANNEL_MASK) |
CHANNEL_SRC(GET_CHANNEL_SRC(reg, x), 0) |
CHANNEL_SRC(GET_CHANNEL_SRC(reg, y), 1) |