if (format == GL_COLOR) {
if (baseFormat != GL_RGB &&
- baseFormat != GL_RGBA) {
+ baseFormat != GL_RGBA &&
+ (!ctx->Extensions.ARB_framebuffer_object ||
+ baseFormat != GL_ALPHA)) {
att_incomplete("bad format");
att->Complete = GL_FALSE;
return;
f = texImg->_BaseFormat;
numImages++;
if (f != GL_RGB && f != GL_RGBA && f != GL_DEPTH_COMPONENT
- && f != GL_DEPTH_STENCIL_EXT) {
+ && f != GL_DEPTH_STENCIL_EXT
+ && (!ctx->Extensions.ARB_framebuffer_object || f != GL_ALPHA)) {
fb->_Status = GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT;
fbo_incomplete("texture attachment incomplete", -1);
return;
const GLenum baseFormat = _mesa_get_format_base_format(rb->Format);
const gl_format fmt = rb->Format;
- if (baseFormat == GL_RGBA || baseFormat == GL_RGB) {
+ if (baseFormat == GL_RGBA || baseFormat == GL_RGB ||
+ baseFormat == GL_ALPHA) {
fb->Visual.redBits = _mesa_get_format_bits(fmt, GL_RED_BITS);
fb->Visual.greenBits = _mesa_get_format_bits(fmt, GL_GREEN_BITS);
fb->Visual.blueBits = _mesa_get_format_bits(fmt, GL_BLUE_BITS);