diff options
author | Dave Airlie <[email protected]> | 2011-06-07 15:39:29 +1000 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2011-06-08 11:47:00 +1000 |
commit | e66053d01c011e3bdcf1cdab8ea9224b868ae246 (patch) | |
tree | 073e2aadb20930ec70c477841ada719b415cf266 | |
parent | ba78a5a679b3f6b00d0f2070bb1ab6d56443ab16 (diff) |
r600g: take alpha ref update out of line.
Signed-off-by: Dave Airlie <[email protected]>
-rw-r--r-- | src/gallium/drivers/r600/r600_state_common.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/gallium/drivers/r600/r600_state_common.c b/src/gallium/drivers/r600/r600_state_common.c index 0928d964dc2..a670ac02be2 100644 --- a/src/gallium/drivers/r600/r600_state_common.c +++ b/src/gallium/drivers/r600/r600_state_common.c @@ -318,12 +318,10 @@ void r600_delete_vs_shader(struct pipe_context *ctx, void *state) static void r600_update_alpha_ref(struct r600_pipe_context *rctx) { - unsigned alpha_ref = rctx->alpha_ref; + unsigned alpha_ref; struct r600_pipe_state rstate; - if (!rctx->alpha_ref_dirty) - return; - + alpha_ref = rctx->alpha_ref; rstate.nregs = 0; if (rctx->export_16bpc) alpha_ref &= ~0x1FFF; @@ -595,7 +593,8 @@ void r600_draw_vbo(struct pipe_context *ctx, const struct pipe_draw_info *info) return; } - r600_update_alpha_ref(rctx); + if (rctx->alpha_ref_dirty) + r600_update_alpha_ref(rctx); mask = 0; for (int i = 0; i < rctx->framebuffer.nr_cbufs; i++) { |