Mesa (master): mesa: reduce calls to _mesa_test_framebuffer_completeness()

Brian Paul brianp at kemper.freedesktop.org
Tue Mar 1 01:34:41 UTC 2011


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

Author: Brian Paul <brianp at vmware.com>
Date:   Mon Feb 28 18:24:25 2011 -0700

mesa: reduce calls to _mesa_test_framebuffer_completeness()

when updating/validating framebuffer state.  The _Status field is set
to zero when we need to recompute _Status.  Otherwise, it's up to date.

---

 src/mesa/main/framebuffer.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/mesa/main/framebuffer.c b/src/mesa/main/framebuffer.c
index 948b3b7..139a842 100644
--- a/src/mesa/main/framebuffer.c
+++ b/src/mesa/main/framebuffer.c
@@ -802,7 +802,7 @@ update_framebuffer(struct gl_context *ctx, struct gl_framebuffer *fb)
       /* This is a user-created framebuffer.
        * Completeness only matters for user-created framebuffers.
        */
-      if (fb->_Status != GL_FRAMEBUFFER_COMPLETE) {
+      if (fb->_Status == 0) {
          _mesa_test_framebuffer_completeness(ctx, fb);
       }
    }




More information about the mesa-commit mailing list