diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/state_tracker/st_extensions.c | 2 | ||||
-rw-r--r-- | src/mesa/state_tracker/st_program.c | 4 |
2 files changed, 6 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c index 982413568a4..b8b3d504a76 100644 --- a/src/mesa/state_tracker/st_extensions.c +++ b/src/mesa/state_tracker/st_extensions.c @@ -816,6 +816,8 @@ void st_init_extensions(struct st_context *st) ctx->Const.ViewportBounds.Max = 16384.0; ctx->Extensions.ARB_viewport_array = GL_TRUE; ctx->Extensions.ARB_fragment_layer_viewport = GL_TRUE; + if (ctx->Extensions.AMD_vertex_shader_layer) + ctx->Extensions.AMD_vertex_shader_viewport_index = GL_TRUE; } } if (ctx->Const.MaxProgramTextureGatherComponents > 0) diff --git a/src/mesa/state_tracker/st_program.c b/src/mesa/state_tracker/st_program.c index 1df411c3b87..3570557fee6 100644 --- a/src/mesa/state_tracker/st_program.c +++ b/src/mesa/state_tracker/st_program.c @@ -262,6 +262,10 @@ st_prepare_vertex_program(struct gl_context *ctx, stvp->output_semantic_name[slot] = TGSI_SEMANTIC_LAYER; stvp->output_semantic_index[slot] = 0; break; + case VARYING_SLOT_VIEWPORT: + stvp->output_semantic_name[slot] = TGSI_SEMANTIC_VIEWPORT_INDEX; + stvp->output_semantic_index[slot] = 0; + break; case VARYING_SLOT_TEX0: case VARYING_SLOT_TEX1: |