aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mesa/main/viewport.c
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/mesa/main/viewport.c')
-rw-r--r--mesalib/src/mesa/main/viewport.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/mesalib/src/mesa/main/viewport.c b/mesalib/src/mesa/main/viewport.c
index 6545bf68a..222ae307b 100644
--- a/mesalib/src/mesa/main/viewport.c
+++ b/mesalib/src/mesa/main/viewport.c
@@ -58,6 +58,12 @@ set_viewport_no_notify(struct gl_context *ctx, unsigned idx,
ctx->Const.ViewportBounds.Min, ctx->Const.ViewportBounds.Max);
}
+ if (ctx->ViewportArray[idx].X == x &&
+ ctx->ViewportArray[idx].Width == width &&
+ ctx->ViewportArray[idx].Y == y &&
+ ctx->ViewportArray[idx].Height == height)
+ return;
+
ctx->ViewportArray[idx].X = x;
ctx->ViewportArray[idx].Width = width;
ctx->ViewportArray[idx].Y = y;