965: fix off-by-one in scissor rect
authorKeith Whitwell <keith@tungstengraphics.com>
Wed, 19 Dec 2007 11:36:03 +0000 (11:36 +0000)
committerKeith Whitwell <keith@tungstengraphics.com>
Wed, 19 Dec 2007 11:37:16 +0000 (11:37 +0000)
src/mesa/pipe/i965simple/brw_sf_state.c

index 2dde2779910c0c4d376b1c71bb3260761b16038b..9acd3ea61b2611b92e877ee5f6878f7b8f42e756 100644 (file)
@@ -58,9 +58,9 @@ static void upload_sf_vp(struct brw_context *brw)
 
    /* _NEW_SCISSOR */
    sfv.scissor.xmin = brw->attribs.Scissor.minx;
-   sfv.scissor.xmax = brw->attribs.Scissor.maxx;
+   sfv.scissor.xmax = brw->attribs.Scissor.maxx - 1;
    sfv.scissor.ymin = brw->attribs.Scissor.miny;
-   sfv.scissor.ymax = brw->attribs.Scissor.maxy;
+   sfv.scissor.ymax = brw->attribs.Scissor.maxy - 1;
 
    brw->sf.vp_gs_offset = brw_cache_data( &brw->cache[BRW_SF_VP], &sfv );
 }