[965] Remove drawing rect upload, which is handled (better) by the kernel.
authorEric Anholt <eric@anholt.net>
Wed, 9 Jan 2008 21:24:29 +0000 (13:24 -0800)
committerEric Anholt <eric@anholt.net>
Wed, 9 Jan 2008 22:41:41 +0000 (14:41 -0800)
src/mesa/drivers/dri/i965/brw_misc_state.c
src/mesa/drivers/dri/i965/brw_state.h
src/mesa/drivers/dri/i965/brw_state_upload.c

index 15e4e612449d7b5720a668222ae0e7b24e2e23c4..37650dd94501a6fdc02a6a2e55c6019fe6998332 100644 (file)
@@ -71,57 +71,6 @@ const struct brw_tracked_state brw_blend_constant_color = {
    .update = upload_blend_constant_color
 };
 
-/***********************************************************************
- * Drawing rectangle -- Need for AUB file only.
- */
-static void upload_drawing_rect(struct brw_context *brw)
-{
-   struct intel_context *intel = &brw->intel;
-   struct brw_drawrect bdr;
-   int x1, y1;
-   int x2, y2;
-
-   /* If there is a single cliprect, set it here.  Otherwise iterate
-    * over them in brw_draw_prim().
-    */
-   if (brw->intel.numClipRects > 1) 
-      return; 
-   x1 = brw->intel.pClipRects[0].x1;
-   y1 = brw->intel.pClipRects[0].y1;
-   x2 = brw->intel.pClipRects[0].x2;
-   y2 = brw->intel.pClipRects[0].y2;
-        
-   if (x1 < 0) x1 = 0;
-   if (y1 < 0) y1 = 0;
-   if (x2 > intel->intelScreen->width) x2 = intel->intelScreen->width;
-   if (y2 > intel->intelScreen->height) y2 = intel->intelScreen->height;
-
-   memset(&bdr, 0, sizeof(bdr));
-   bdr.header.opcode = CMD_DRAW_RECT;
-   bdr.header.length = sizeof(bdr)/4 - 2;
-   bdr.xmin = x1;
-   bdr.ymin = y1;
-   bdr.xmax = x2;
-   bdr.ymax = y2;
-   bdr.xorg = intel->drawX;
-   bdr.yorg = intel->drawY;
-
-   /* Can't use BRW_CACHED_BATCH_STRUCT because this is also emitted
-    * uncached in brw_draw.c:
-    */
-   BRW_BATCH_STRUCT(brw, &bdr);
-}
-
-const struct brw_tracked_state brw_drawing_rect = {
-   .dirty = {
-      .mesa = _NEW_WINDOW_POS,
-      .brw = 0,
-      .cache = 0
-   },
-   .update = upload_drawing_rect
-};
-
 /**
  * Upload the binding table pointers, which point each stage's array of surface
  * state pointers.
index f0a740f456c67ee6121314e6bd8c9ecc9a8dc65c..e4bb39811a044e10d702cbdda1d8d417a9727c60 100644 (file)
@@ -48,7 +48,6 @@ const struct brw_tracked_state brw_curbe_offsets;
 const struct brw_tracked_state brw_invarient_state;
 const struct brw_tracked_state brw_gs_prog;
 const struct brw_tracked_state brw_gs_unit;
-const struct brw_tracked_state brw_drawing_rect;
 const struct brw_tracked_state brw_line_stipple;
 const struct brw_tracked_state brw_pipelined_state_pointers;
 const struct brw_tracked_state brw_binding_table_pointers;
index c8e3fb8ee8f5e1ba67ee9e569982e23644d3caef..46ae49262d11e51fc3eb335c8208fd1136477af4 100644 (file)
@@ -85,7 +85,6 @@ const struct brw_tracked_state *atoms[] =
    &brw_binding_table_pointers,
    &brw_blend_constant_color,
 
-   &brw_drawing_rect,
    &brw_depthbuffer,
 
    &brw_polygon_stipple,