With glFramebufferTexture, a renderbuffer may support all layers of the texture, so we need the depth of the renderbuffer to check for consistency which is required for framebuffer completeness. Signed-off-by: Jordan Justen <jordan.l.justen@intel.com> Reviewed-by: Brian Paul <brianp@vmware.com>tags/mesa-9.2-rc1
@@ -2566,6 +2566,7 @@ struct gl_renderbuffer | |||
GLuint Name; | |||
GLint RefCount; | |||
GLuint Width, Height; | |||
GLuint Depth; | |||
GLboolean Purgeable; /**< Is the buffer purgeable under memory pressure? */ | |||
GLboolean AttachedAnytime; /**< TRUE if it was attached to a framebuffer */ | |||
GLubyte NumSamples; |
@@ -53,6 +53,7 @@ _mesa_init_renderbuffer(struct gl_renderbuffer *rb, GLuint name) | |||
rb->Width = 0; | |||
rb->Height = 0; | |||
rb->Depth = 0; | |||
rb->InternalFormat = GL_RGBA; | |||
rb->Format = MESA_FORMAT_NONE; | |||
} |