summaryrefslogtreecommitdiffstats
path: root/src/glsl/linker.cpp
diff options
context:
space:
mode:
authorTimothy Arceri <t_arceri@yahoo.com.au>2015-07-08 09:20:40 +1000
committerTimothy Arceri <t_arceri@yahoo.com.au>2015-07-08 11:40:30 +1000
commit87d2e15b1aa6f438983405aa25bf067034c898b0 (patch)
treef6dffeec9f914bee371e7d1f8df4b203958a46e3 /src/glsl/linker.cpp
parent73d0e7f3451eaeb62ac039d2dcee1e1c6787e3db (diff)
downloadexternal_mesa3d-87d2e15b1aa6f438983405aa25bf067034c898b0.zip
external_mesa3d-87d2e15b1aa6f438983405aa25bf067034c898b0.tar.gz
external_mesa3d-87d2e15b1aa6f438983405aa25bf067034c898b0.tar.bz2
mesa: use implementation specified MAX_VERTEX_ATTRIBS rather than hardcoded value
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Diffstat (limited to 'src/glsl/linker.cpp')
-rw-r--r--src/glsl/linker.cpp8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/glsl/linker.cpp b/src/glsl/linker.cpp
index 8d4b40e..b7a783c 100644
--- a/src/glsl/linker.cpp
+++ b/src/glsl/linker.cpp
@@ -3070,12 +3070,8 @@ link_shaders(struct gl_context *ctx, struct gl_shader_program *prog)
}
}
- /* FINISHME: The value of the max_attribute_index parameter is
- * FINISHME: implementation dependent based on the value of
- * FINISHME: GL_MAX_VERTEX_ATTRIBS. GL_MAX_VERTEX_ATTRIBS must be
- * FINISHME: at least 16, so hardcode 16 for now.
- */
- if (!assign_attribute_or_color_locations(prog, MESA_SHADER_VERTEX, 16)) {
+ if (!assign_attribute_or_color_locations(prog, MESA_SHADER_VERTEX,
+ ctx->Const.Program[MESA_SHADER_VERTEX].MaxAttribs)) {
goto done;
}