i965: Update gen6 paths for the streaming rework.
authorEric Anholt <eric@anholt.net>
Fri, 11 Jun 2010 22:35:52 +0000 (15:35 -0700)
committerEric Anholt <eric@anholt.net>
Sun, 13 Jun 2010 04:47:31 +0000 (21:47 -0700)
src/mesa/drivers/dri/i965/brw_state.h
src/mesa/drivers/dri/i965/brw_state_upload.c
src/mesa/drivers/dri/i965/gen6_viewport_state.c

index 5756b8f029eff0066ed92eaa5796f7db46477d1e..40eece276b7f349c0c35cc2c3e46f5456c3ef324 100644 (file)
@@ -95,7 +95,6 @@ const struct brw_tracked_state brw_index_buffer;
 const struct brw_tracked_state gen6_binding_table_pointers;
 const struct brw_tracked_state gen6_blend_state;
 const struct brw_tracked_state gen6_cc_state_pointers;
-const struct brw_tracked_state gen6_cc_vp;
 const struct brw_tracked_state gen6_clip_state;
 const struct brw_tracked_state gen6_clip_vp;
 const struct brw_tracked_state gen6_color_calc_state;
index fac57c935fe5907b25943ac5d5b9469b031af138..f92a19c2aa0f7c28905d562d6661244ceb794a4f 100644 (file)
@@ -116,7 +116,6 @@ const struct brw_tracked_state *gen6_atoms[] =
 
    &gen6_clip_vp,
    &gen6_sf_vp,
-   &gen6_cc_vp,
 
    /* Command packets: */
    &brw_invarient_state,
@@ -129,9 +128,13 @@ const struct brw_tracked_state *gen6_atoms[] =
    &gen6_depth_stencil_state,  /* must do before cc unit */
    &gen6_cc_state_pointers,
 
+   &brw_vs_constants, /* Before vs_surfaces and constant_buffer */
+   &brw_wm_constants, /* Before wm_surfaces and constant_buffer */
+
    &brw_vs_surfaces,           /* must do before unit */
    &brw_wm_constant_surface,   /* must do before wm surfaces/bind bo */
    &brw_wm_surfaces,           /* must do before samplers and unit */
+   &brw_wm_binding_table,
 
    &brw_wm_samplers,
    &gen6_sampler_state,
index f8ee26bc5edf735585c0d62fe2a66d945d1d28c3..008b05a194b99e9bfd357bade6f1060e545457cd 100644 (file)
@@ -106,35 +106,6 @@ const struct brw_tracked_state gen6_sf_vp = {
    .prepare = prepare_sf_vp,
 };
 
-static void
-prepare_cc_vp(struct brw_context *brw)
-{
-   GLcontext *ctx = &brw->intel.ctx;
-   struct brw_cc_viewport ccv;
-
-   /* _NEW_TRANSOFORM */
-   if (ctx->Transform.DepthClamp) {
-      /* _NEW_VIEWPORT */
-      ccv.min_depth = MIN2(ctx->Viewport.Near, ctx->Viewport.Far);
-      ccv.max_depth = MAX2(ctx->Viewport.Near, ctx->Viewport.Far);
-   } else {
-      ccv.min_depth = 0.0;
-      ccv.max_depth = 1.0;
-   }
-
-   drm_intel_bo_unreference(brw->cc.vp_bo);
-   brw->cc.vp_bo = brw_cache_data(&brw->cache, BRW_CC_VP, &ccv, sizeof(ccv));
-}
-
-const struct brw_tracked_state gen6_cc_vp = {
-   .dirty = {
-      .mesa = _NEW_VIEWPORT | _NEW_TRANSFORM,
-      .brw = 0,
-      .cache = 0,
-   },
-   .prepare = prepare_cc_vp,
-};
-
 static void prepare_viewport_state_pointers(struct brw_context *brw)
 {
    brw_add_validated_bo(brw, brw->sf.state_bo);