mesa: add missing RGB9_E5 format in _mesa_base_fbo_format
[mesa.git] / src / mesa / main / getstring.c
index c39a076091e007172a3ca38c6c771364af91c339..931f6a476cb0c22733eda64296aea35aa0e0a182 100644 (file)
@@ -65,6 +65,8 @@ shading_language_version(struct gl_context *ctx)
          return (const GLubyte *) "4.40";
       case 450:
          return (const GLubyte *) "4.50";
+      case 460:
+         return (const GLubyte *) "4.60";
       default:
          _mesa_problem(ctx,
                        "Invalid GLSL version in shading_language_version()");
@@ -80,6 +82,8 @@ shading_language_version(struct gl_context *ctx)
          return (const GLubyte *) "OpenGL ES GLSL ES 3.00";
       case 31:
          return (const GLubyte *) "OpenGL ES GLSL ES 3.10";
+      case 32:
+         return (const GLubyte *) "OpenGL ES GLSL ES 3.20";
       default:
          _mesa_problem(ctx,
                        "Invalid OpenGL ES version in shading_language_version()");
@@ -139,6 +143,8 @@ _mesa_GetString( GLenum name )
             _mesa_error(ctx, GL_INVALID_ENUM, "glGetString(GL_EXTENSIONS)");
             return (const GLubyte *) 0;
          }
+         if (!ctx->Extensions.String)
+            ctx->Extensions.String = _mesa_make_extension_string(ctx);
          return (const GLubyte *) ctx->Extensions.String;
       case GL_SHADING_LANGUAGE_VERSION:
          if (ctx->API == API_OPENGLES)
@@ -302,6 +308,17 @@ _mesa_GetError( void )
    GLenum e = ctx->ErrorValue;
    ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, 0);
 
+   /* From Issue (3) of the KHR_no_error spec:
+    *
+    *    "Should glGetError() always return NO_ERROR or have undefined
+    *    results?
+    *
+    *    RESOLVED: It should for all errors except OUT_OF_MEMORY."
+    */
+   if (_mesa_is_no_error_enabled(ctx) && e != GL_OUT_OF_MEMORY) {
+      e = GL_NO_ERROR;
+   }
+
    if (MESA_VERBOSE & VERBOSE_API)
       _mesa_debug(ctx, "glGetError <-- %s\n", _mesa_enum_to_string(e));