From: Kenneth Graunke Date: Sat, 7 Apr 2018 07:58:07 +0000 (-0700) Subject: iris: fix a scissor bug X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e0eac28bd4287f4ed56b57ca9acb4bc07961a465;p=mesa.git iris: fix a scissor bug --- diff --git a/src/gallium/drivers/iris/iris_state.c b/src/gallium/drivers/iris/iris_state.c index a0f6a685b43..12eb57a821b 100644 --- a/src/gallium/drivers/iris/iris_state.c +++ b/src/gallium/drivers/iris/iris_state.c @@ -2253,7 +2253,8 @@ iris_upload_render_state(struct iris_context *ice, } if (dirty & IRIS_DIRTY_SCISSOR) { - uint32_t scissor_offset = + // XXX: allocate at set_scissor time? + uint32_t scissor_offset = ice->state.num_scissors == 0 ? 0 : emit_state(batch, ice->state.dynamic_uploader, ice->state.scissors, sizeof(struct pipe_scissor_state) * ice->state.num_scissors, 32);