mesa: add missing RGB9_E5 format in _mesa_base_fbo_format
authorJuan A. Suarez Romero <jasuarez@igalia.com>
Mon, 15 Jan 2018 10:58:50 +0000 (10:58 +0000)
committerJuan A. Suarez Romero <jasuarez@igalia.com>
Thu, 25 Jan 2018 08:54:31 +0000 (09:54 +0100)
This fixes KHR-GL45.internalformat.renderbuffer.rgb9_e5.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/fbobject.c

index d23916d1ad72318baa85bb42b66db1149e96a4f4..c72204e11a07721a004a609eaafa9b9c03418b75 100644 (file)
@@ -1976,6 +1976,9 @@ _mesa_base_fbo_format(const struct gl_context *ctx, GLenum internalFormat)
                ctx->Extensions.ARB_texture_float) ||
               _mesa_is_gles3(ctx) /* EXT_color_buffer_float */ )
          ? GL_RGBA : 0;
+   case GL_RGB9_E5:
+      return (_mesa_is_desktop_gl(ctx) && ctx->Extensions.EXT_texture_shared_exponent)
+         ? GL_RGB: 0;
    case GL_ALPHA16F_ARB:
    case GL_ALPHA32F_ARB:
       return ctx->API == API_OPENGL_COMPAT &&