dri/radeon: don't print TCL status on glGetString(GL_RENDERER)
authorEmil Velikov <emil.l.velikov@gmail.com>
Wed, 19 Feb 2014 21:53:38 +0000 (21:53 +0000)
committerEmil Velikov <emil.l.velikov@gmail.com>
Fri, 15 Aug 2014 16:35:37 +0000 (17:35 +0100)
Printing the TCL involves that context is available at the time of
query. The GLX_MESA_query_renderer states that glGetString(GL_RENDERER)
and glXQueryRendererStringMESA(GLX_RENDERER_DEVICE_ID_MESA) will have
the same format, thus removing the context dependenicy will help us
achieve that.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
src/mesa/drivers/dri/radeon/radeon_common_context.c

index 54db9d549e123cc09d23c5d7fadf8d8dcc56fced..353ecf5e243025d58276b916c6232eb4a1bef4bf 100644 (file)
@@ -84,10 +84,9 @@ static const GLubyte *radeonGetString(struct gl_context * ctx, GLenum name)
 
        case GL_RENDERER:
        {
-               unsigned offset;
+               char hardwarename[32];
                GLuint agp_mode = (radeon->radeonScreen->card_type==RADEON_CARD_PCI) ? 0 :
                        radeon->radeonScreen->AGPMode;
-               char hardwarename[32];
 
                sprintf(hardwarename, "%s (%s %04X)",
 #if defined(RADEON_R100)
@@ -98,11 +97,7 @@ static const GLubyte *radeonGetString(struct gl_context * ctx, GLenum name)
                        get_chip_family_name(radeon->radeonScreen->chip_family),
                        radeon->radeonScreen->device_id);
 
-               offset = driGetRendererString(buffer, hardwarename, agp_mode);
-
-               sprintf(&buffer[offset], " %sTCL",
-                       !(radeon->TclFallback & RADEON_TCL_FALLBACK_TCL_DISABLE)
-                       ? "" : "NO-");
+               driGetRendererString(buffer, hardwarename, agp_mode);
 
                strcat(buffer, " DRI2");