summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/depth.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2017-06-10 00:58:04 +0200
committerMarek Olšák <[email protected]>2017-06-22 01:51:02 +0200
commit37b834923d31bb170ffbfac882476659060b78b2 (patch)
tree2ec1e7563df2c6839549b7e738e80a035a27e57b /src/mesa/main/depth.c
parenta9315627bc35d5447484a804ecd891c8711a49d3 (diff)
mesa: don't flag _NEW_DEPTH for st/mesa
skipping _mesa_update_state_locked Reviewed-by: Nicolai Hähnle <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Timothy Arceri <[email protected]>
Diffstat (limited to 'src/mesa/main/depth.c')
-rw-r--r--src/mesa/main/depth.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/mesa/main/depth.c b/src/mesa/main/depth.c
index c3534407599..1ea7d1af5c0 100644
--- a/src/mesa/main/depth.c
+++ b/src/mesa/main/depth.c
@@ -83,7 +83,8 @@ _mesa_DepthFunc( GLenum func )
return;
}
- FLUSH_VERTICES(ctx, _NEW_DEPTH);
+ FLUSH_VERTICES(ctx, ctx->DriverFlags.NewDepth ? 0 : _NEW_DEPTH);
+ ctx->NewDriverState |= ctx->DriverFlags.NewDepth;
ctx->Depth.Func = func;
if (ctx->Driver.DepthFunc)
@@ -107,7 +108,8 @@ _mesa_DepthMask( GLboolean flag )
if (ctx->Depth.Mask == flag)
return;
- FLUSH_VERTICES(ctx, _NEW_DEPTH);
+ FLUSH_VERTICES(ctx, ctx->DriverFlags.NewDepth ? 0 : _NEW_DEPTH);
+ ctx->NewDriverState |= ctx->DriverFlags.NewDepth;
ctx->Depth.Mask = flag;
if (ctx->Driver.DepthMask)
@@ -138,7 +140,8 @@ _mesa_DepthBoundsEXT( GLclampd zmin, GLclampd zmax )
if (ctx->Depth.BoundsMin == zmin && ctx->Depth.BoundsMax == zmax)
return;
- FLUSH_VERTICES(ctx, _NEW_DEPTH);
+ FLUSH_VERTICES(ctx, ctx->DriverFlags.NewDepth ? 0 : _NEW_DEPTH);
+ ctx->NewDriverState |= ctx->DriverFlags.NewDepth;
ctx->Depth.BoundsMin = (GLfloat) zmin;
ctx->Depth.BoundsMax = (GLfloat) zmax;
}