diff options
author | Brian Paul <[email protected]> | 2005-10-04 15:01:27 +0000 |
---|---|---|
committer | Brian Paul <[email protected]> | 2005-10-04 15:01:27 +0000 |
commit | bc6cced479b0ea854acff9f5fec253d462774290 (patch) | |
tree | d33260b40033b1c9c6521e0e49269cfb85f00de1 | |
parent | 14c38b8f4f1f3ffaf955fb4de4cb36a5f10d2bb2 (diff) |
fix behaviour of glIsFrame/Renderbuffer()
-rw-r--r-- | src/mesa/main/fbobject.c | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 07489f96205..324a3032535 100644 --- a/src/mesa/main/fbobject.c +++ b/src/mesa/main/fbobject.c @@ -509,10 +509,12 @@ _mesa_IsRenderbufferEXT(GLuint renderbuffer) { GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, GL_FALSE); - if (renderbuffer && lookup_renderbuffer(ctx, renderbuffer)) - return GL_TRUE; - else - return GL_FALSE; + if (renderbuffer) { + struct gl_renderbuffer *rb = lookup_renderbuffer(ctx, renderbuffer); + if (rb != NULL && rb != &DummyRenderbuffer) + return GL_TRUE; + } + return GL_FALSE; } @@ -843,10 +845,12 @@ _mesa_IsFramebufferEXT(GLuint framebuffer) { GET_CURRENT_CONTEXT(ctx); ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, GL_FALSE); - if (framebuffer && lookup_framebuffer(ctx, framebuffer)) - return GL_TRUE; - else - return GL_FALSE; + if (framebuffer) { + struct gl_framebuffer *rb = lookup_framebuffer(ctx, framebuffer); + if (rb != NULL && rb != &DummyFramebuffer) + return GL_TRUE; + } + return GL_FALSE; } |