st/mesa: enable ARB_shader_viewport_layer_array
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Thu, 13 Apr 2017 19:47:00 +0000 (21:47 +0200)
committerNicolai Hähnle <nicolai.haehnle@amd.com>
Fri, 14 Apr 2017 20:50:09 +0000 (22:50 +0200)
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Reviewed-by: Edward O'Callaghan <funfunctor@folklore1984.net>
src/mesa/state_tracker/st_extensions.c

index 8b623606dc3bda3e4c593d7f08892a9d8585d41a..1df2ba7616825a653b38a731e3b2e4720e60f20c 100644 (file)
@@ -1129,6 +1129,11 @@ void st_init_extensions(struct pipe_screen *screen,
          extensions->AMD_vertex_shader_viewport_index = GL_TRUE;
    }
 
+   if (extensions->AMD_vertex_shader_layer &&
+       extensions->AMD_vertex_shader_viewport_index &&
+       screen->get_param(screen, PIPE_CAP_TGSI_TES_LAYER_VIEWPORT))
+      extensions->ARB_shader_viewport_layer_array = GL_TRUE;
+
    /* ARB_framebuffer_no_attachments */
    if (screen->get_param(screen, PIPE_CAP_FRAMEBUFFER_NO_ATTACHMENT) &&
        ((consts->MaxSamples >= 4 && consts->MaxFramebufferLayers >= 2048) ||