iris: actually init num_viewports
authorKenneth Graunke <kenneth@whitecape.org>
Wed, 20 Jun 2018 23:11:08 +0000 (16:11 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 21 Feb 2019 18:26:07 +0000 (10:26 -0800)
fixes regressions

src/gallium/drivers/iris/iris_program.c
src/gallium/drivers/iris/iris_state.c

index 136b1c388df58108b08381119fc16b0ea01293be..b4bfb45ec4c1f672289aa2f0c103851cab6d34bd 100644 (file)
@@ -452,7 +452,9 @@ update_last_vue_map(struct iris_context *ice)
       // XXX: could use ctx->Const.MaxViewports for old API efficiency
       ice->state.num_viewports =
          (vue_map->slots_valid & VARYING_BIT_VIEWPORT) ? IRIS_MAX_VIEWPORTS : 1;
-      ice->state.dirty |= IRIS_DIRTY_CLIP | IRIS_DIRTY_SF_CL_VIEWPORT;
+      ice->state.dirty |= IRIS_DIRTY_CLIP |
+                          IRIS_DIRTY_SF_CL_VIEWPORT |
+                          IRIS_DIRTY_SCISSOR_RECT;
       // XXX: CC_VIEWPORT?
    }
 
index 8fd0ad83b94002df7eadda80dc755fd1ce44e1bc..d35bcd4eb289127794f4baa77c344612fb33c65a 100644 (file)
@@ -3343,6 +3343,7 @@ genX(init_state)(struct iris_context *ice)
 
    ice->state.dirty = ~0ull;
 
+   ice->state.num_viewports = 1;
    ice->state.cso_vp = calloc(1, sizeof(struct iris_viewport_state));
    ice->state.cso_vertex_buffers =
       calloc(1, sizeof(struct iris_vertex_buffer_state));