From: Brian Paul Date: Sat, 21 Oct 2000 00:02:47 +0000 (+0000) Subject: polygon offset changes; added Visual->MRD field X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=d0d7d62120d7448924655c4683bab6bd5667256e;p=mesa.git polygon offset changes; added Visual->MRD field --- diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c index 3f4bcec2fb5..c57f37c5791 100644 --- a/src/mesa/main/context.c +++ b/src/mesa/main/context.c @@ -1,4 +1,4 @@ -/* $Id: context.c,v 1.93 2000/10/20 19:54:49 brianp Exp $ */ +/* $Id: context.c,v 1.94 2000/10/21 00:02:47 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -295,6 +295,7 @@ _mesa_initialize_visual( GLvisual *vis, vis->DepthMax = 0xffffffff; vis->DepthMaxF = (GLfloat) vis->DepthMax; } + vis->MRD = 1; /* XXX temporary value */ return GL_TRUE; } @@ -1157,6 +1158,7 @@ init_attrib_groups( GLcontext *ctx ) ctx->Polygon.StippleFlag = GL_FALSE; ctx->Polygon.OffsetFactor = 0.0F; ctx->Polygon.OffsetUnits = 0.0F; + ctx->Polygon.OffsetMRD = 0.0F; ctx->Polygon.OffsetPoint = GL_FALSE; ctx->Polygon.OffsetLine = GL_FALSE; ctx->Polygon.OffsetFill = GL_FALSE; diff --git a/src/mesa/main/polygon.c b/src/mesa/main/polygon.c index 5ca3ffbc945..c96d3355b32 100644 --- a/src/mesa/main/polygon.c +++ b/src/mesa/main/polygon.c @@ -1,4 +1,4 @@ -/* $Id: polygon.c,v 1.12 2000/09/26 20:53:53 brianp Exp $ */ +/* $Id: polygon.c,v 1.13 2000/10/21 00:02:47 brianp Exp $ */ /* * Mesa 3-D graphics library @@ -178,6 +178,7 @@ _mesa_PolygonOffset( GLfloat factor, GLfloat units ) ctx->Polygon.OffsetFactor = factor; ctx->Polygon.OffsetUnits = units; + ctx->Polygon.OffsetMRD = units * ctx->Visual.MRD; }