From: Zhenyu Wang Date: Sun, 26 Sep 2010 05:17:18 +0000 (+0800) Subject: i965: enable polygon offset on sandybridge X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=3f3059fcc0cfb797830eb5e0755b5b4ec3fd218b;p=mesa.git i965: enable polygon offset on sandybridge Depth offset function is moved to SF stage on sandybridge. --- diff --git a/src/mesa/drivers/dri/i965/gen6_sf_state.c b/src/mesa/drivers/dri/i965/gen6_sf_state.c index b5984255afa..a0322784685 100644 --- a/src/mesa/drivers/dri/i965/gen6_sf_state.c +++ b/src/mesa/drivers/dri/i965/gen6_sf_state.c @@ -87,6 +87,9 @@ upload_sf_state(struct brw_context *brw) if ((ctx->Polygon.FrontFace == GL_CCW) ^ render_to_fbo) dw2 |= GEN6_SF_WINDING_CCW; + if (ctx->Polygon.OffsetFill) + dw2 |= GEN6_SF_GLOBAL_DEPTH_OFFSET_SOLID; + /* _NEW_SCISSOR */ if (ctx->Scissor.Enabled) dw3 |= GEN6_SF_SCISSOR_ENABLE;