Mesa (master): mesa: remove useless comments in the viewport code path

Samuel Pitoiset hakzsam at kemper.freedesktop.org
Sat Jun 24 15:02:18 UTC 2017


Module: Mesa
Branch: master
Commit: 4178cea06d6976f25c4a84e0694f7cde4d23118f
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=4178cea06d6976f25c4a84e0694f7cde4d23118f

Author: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Date:   Thu Jun 22 15:01:12 2017 +0200

mesa: remove useless comments in the viewport code path

No need to explain why calling a driver callback is needed.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Reviewed-by: Nicolai Hähnle <nicolai.haehnle at amd.com>

---

 src/mesa/main/viewport.c | 12 ++----------
 1 file changed, 2 insertions(+), 10 deletions(-)

diff --git a/src/mesa/main/viewport.c b/src/mesa/main/viewport.c
index 67735b0862..d37c2f3f10 100644
--- a/src/mesa/main/viewport.c
+++ b/src/mesa/main/viewport.c
@@ -103,12 +103,8 @@ viewport(struct gl_context *ctx, GLint x, GLint y, GLsizei width,
    for (unsigned i = 0; i < ctx->Const.MaxViewports; i++)
       set_viewport_no_notify(ctx, i, x, y, width, height);
 
-   if (ctx->Driver.Viewport) {
-      /* Many drivers will use this call to check for window size changes
-       * and reallocate the z/stencil/accum/etc buffers if needed.
-       */
+   if (ctx->Driver.Viewport)
       ctx->Driver.Viewport(ctx);
-   }
 }
 
 /**
@@ -159,12 +155,8 @@ _mesa_set_viewport(struct gl_context *ctx, unsigned idx, GLfloat x, GLfloat y,
 {
    set_viewport_no_notify(ctx, idx, x, y, width, height);
 
-   if (ctx->Driver.Viewport) {
-      /* Many drivers will use this call to check for window size changes
-       * and reallocate the z/stencil/accum/etc buffers if needed.
-       */
+   if (ctx->Driver.Viewport)
       ctx->Driver.Viewport(ctx);
-   }
 }
 
 static void




More information about the mesa-commit mailing list