OSDN Git Service

main/version: add "(Core Profile) to version string for core profiles
authorJordan Justen <jordan.l.justen@intel.com>
Tue, 4 Sep 2012 22:49:01 +0000 (15:49 -0700)
committerJordan Justen <jordan.l.justen@intel.com>
Fri, 28 Sep 2012 21:17:12 +0000 (14:17 -0700)
Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/version.c

index 55638a8..19d514d 100644 (file)
@@ -65,13 +65,15 @@ create_version_string(struct gl_context *ctx, const char *prefix)
    ctx->VersionString = malloc(max);
    if (ctx->VersionString) {
       _mesa_snprintf(ctx->VersionString, max,
-                    "%s%u.%u Mesa " MESA_VERSION_STRING
+                    "%s%u.%u%s Mesa " MESA_VERSION_STRING
 #ifdef MESA_GIT_SHA1
                     " (" MESA_GIT_SHA1 ")"
 #endif
                     ,
                     prefix,
-                    ctx->Version / 10, ctx->Version % 10);
+                    ctx->Version / 10, ctx->Version % 10,
+                    (ctx->API == API_OPENGL_CORE) ? " (Core Profile)" : ""
+                    );
    }
 }