Mesa (master): mesa: Allow color renderbuffers besides just RGB and RGBA.
Eric Anholt
anholt at kemper.freedesktop.org
Mon Jan 3 21:29:46 UTC 2011
Module: Mesa
Branch: master
Commit: beac6ee62aea196d6e670abd4b198190e33e6cb1
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=beac6ee62aea196d6e670abd4b198190e33e6cb1
Author: Eric Anholt <eric at anholt.net>
Date: Sun Jan 2 18:01:39 2011 -0800
mesa: Allow color renderbuffers besides just RGB and RGBA.
We did so already for textures to do ARB_fbo's
GL_ALPHA/GL_LUMINANCE/etc. support and for ARB_texture_rg's GL_RED and
GL_RG, but this path was missed.
---
src/mesa/main/fbobject.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c
index 975063d..b4101dd 100644
--- a/src/mesa/main/fbobject.c
+++ b/src/mesa/main/fbobject.c
@@ -542,8 +542,7 @@ test_attachment_completeness(const struct gl_context *ctx, GLenum format,
return;
}
if (format == GL_COLOR) {
- if (baseFormat != GL_RGB &&
- baseFormat != GL_RGBA) {
+ if (!is_legal_color_format(ctx, baseFormat)) {
att_incomplete("bad renderbuffer color format");
att->Complete = GL_FALSE;
return;
More information about the mesa-commit
mailing list