From 8baf2cd0c9a022be6b3d263f528773096dd2017a Mon Sep 17 00:00:00 2001 From: James Legg Date: Sat, 7 Feb 2015 23:33:15 +0000 Subject: [PATCH] Make renderbuffer FBO attachments not layered For framebuffer completeness checks, consider renderbuffers as not layered. Previously, they would have counted as layered if a layered textured had previously been bound to the same attachment point. This could cause framebuffer completeness checks to incorrectly fail with GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS, even if no layered attachments were present. --- src/mesa/main/fbobject.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 3305151..dae9d4e 100644 --- a/src/mesa/main/fbobject.c +++ b/src/mesa/main/fbobject.c @@ -468,6 +468,7 @@ set_renderbuffer_attachment(struct gl_context *ctx, remove_attachment(ctx, att); att->Type = GL_RENDERBUFFER_EXT; att->Texture = NULL; /* just to be safe */ + att->Layered = GL_FALSE; att->Complete = GL_FALSE; _mesa_reference_renderbuffer(&att->Renderbuffer, rb); } -- 2.1.0