summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/enable.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2017-06-10 00:30:18 +0200
committerMarek Olšák <[email protected]>2017-06-22 01:51:02 +0200
commitbe15028ede59bc1936be315321e8add7553641f3 (patch)
treea9b727293f9b7f8aeee0f503f181793999408746 /src/mesa/main/enable.c
parent124df5d71a051b6e7d46ac45331ad21bfd1df029 (diff)
mesa: don't flag _NEW_SCISSOR for st/mesa
Not needed and we get to bypass _mesa_update_state_locked that would be a no-op. 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/enable.c')
-rw-r--r--src/mesa/main/enable.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mesa/main/enable.c b/src/mesa/main/enable.c
index 522b71ecfc7..9410d5ea94e 100644
--- a/src/mesa/main/enable.c
+++ b/src/mesa/main/enable.c
@@ -670,7 +670,8 @@ _mesa_set_enable(struct gl_context *ctx, GLenum cap, GLboolean state)
GLbitfield newEnabled =
state * ((1 << ctx->Const.MaxViewports) - 1);
if (newEnabled != ctx->Scissor.EnableFlags) {
- FLUSH_VERTICES(ctx, _NEW_SCISSOR);
+ FLUSH_VERTICES(ctx, ctx->DriverFlags.NewScissorTest ? 0 :
+ _NEW_SCISSOR);
ctx->NewDriverState |= ctx->DriverFlags.NewScissorTest;
ctx->Scissor.EnableFlags = newEnabled;
}
@@ -1115,7 +1116,8 @@ _mesa_set_enablei(struct gl_context *ctx, GLenum cap,
return;
}
if (((ctx->Scissor.EnableFlags >> index) & 1) != state) {
- FLUSH_VERTICES(ctx, _NEW_SCISSOR);
+ FLUSH_VERTICES(ctx,
+ ctx->DriverFlags.NewScissorTest ? 0 : _NEW_SCISSOR);
ctx->NewDriverState |= ctx->DriverFlags.NewScissorTest;
if (state)
ctx->Scissor.EnableFlags |= (1 << index);