From 4c4f98c6fcabc4a2c9ede3647de390a4585cf58a Mon Sep 17 00:00:00 2001 From: José Fonseca Date: Wed, 12 May 2010 17:24:34 +0100 Subject: llvmpipe: Use RAST_WHOLE/EDGE_TEST in more places. --- src/gallium/drivers/llvmpipe/lp_jit.h | 5 ----- src/gallium/drivers/llvmpipe/lp_rast_priv.h | 1 + src/gallium/drivers/llvmpipe/lp_state.h | 5 +++++ src/gallium/drivers/llvmpipe/lp_state_fs.c | 4 ++-- 4 files changed, 8 insertions(+), 7 deletions(-) (limited to 'src/gallium/drivers/llvmpipe') diff --git a/src/gallium/drivers/llvmpipe/lp_jit.h b/src/gallium/drivers/llvmpipe/lp_jit.h index fc43d0bf5a..8d06e65725 100644 --- a/src/gallium/drivers/llvmpipe/lp_jit.h +++ b/src/gallium/drivers/llvmpipe/lp_jit.h @@ -150,11 +150,6 @@ enum { -/** Indexes into jit_function[] array */ -#define RAST_WHOLE 0 -#define RAST_EDGE_TEST 1 - - typedef void (*lp_jit_frag_func)(const struct lp_jit_context *context, uint32_t x, diff --git a/src/gallium/drivers/llvmpipe/lp_rast_priv.h b/src/gallium/drivers/llvmpipe/lp_rast_priv.h index 0ceba209e0..efc013ff3f 100644 --- a/src/gallium/drivers/llvmpipe/lp_rast_priv.h +++ b/src/gallium/drivers/llvmpipe/lp_rast_priv.h @@ -33,6 +33,7 @@ #include "gallivm/lp_bld_debug.h" #include "lp_rast.h" #include "lp_scene.h" +#include "lp_state.h" #include "lp_texture.h" #include "lp_tile_soa.h" #include "lp_limits.h" diff --git a/src/gallium/drivers/llvmpipe/lp_state.h b/src/gallium/drivers/llvmpipe/lp_state.h index 73778449ea..bae5de0cb3 100644 --- a/src/gallium/drivers/llvmpipe/lp_state.h +++ b/src/gallium/drivers/llvmpipe/lp_state.h @@ -63,6 +63,11 @@ struct llvmpipe_context; struct lp_fragment_shader; +/** Indexes into jit_function[] array */ +#define RAST_WHOLE 0 +#define RAST_EDGE_TEST 1 + + struct lp_fragment_shader_variant_key { struct pipe_depth_state depth; diff --git a/src/gallium/drivers/llvmpipe/lp_state_fs.c b/src/gallium/drivers/llvmpipe/lp_state_fs.c index 429aaab569..ff193d61aa 100644 --- a/src/gallium/drivers/llvmpipe/lp_state_fs.c +++ b/src/gallium/drivers/llvmpipe/lp_state_fs.c @@ -962,8 +962,8 @@ generate_variant(struct llvmpipe_context *lp, memcpy(&variant->key, key, sizeof *key); - generate_fragment(lp, shader, variant, 0); - generate_fragment(lp, shader, variant, 1); + generate_fragment(lp, shader, variant, RAST_WHOLE); + generate_fragment(lp, shader, variant, RAST_EDGE_TEST); /* TODO: most of these can be relaxed, in particular the colormask */ variant->opaque = -- cgit v1.2.3