Commit f9cc6acb authored by Brian Paul's avatar Brian Paul

st/mesa: raise shader MaxParameters if driver supports more

The default value is 64 but drivers usually advertise more, like 4096.
Allows ARB vp/fp programs to use more parameters.
Reviewed-by: Jose Fonseca's avatarJose Fonseca <>
parent f3c92c23
......@@ -167,6 +167,8 @@ void st_init_limits(struct st_context *st)
pc->MaxNativeAddressRegs = screen->get_shader_param(screen, sh, PIPE_SHADER_CAP_MAX_ADDRS);
pc->MaxNativeParameters = screen->get_shader_param(screen, sh, PIPE_SHADER_CAP_MAX_CONSTS);
pc->MaxUniformComponents = 4 * MIN2(pc->MaxNativeParameters, MAX_UNIFORMS);
/* raise MaxParameters if native support is higher */
pc->MaxParameters = MAX2(pc->MaxParameters, pc->MaxNativeParameters);
options->EmitNoNoise = TRUE;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment