Commit e0ccbeb2 authored by Jason Green's avatar Jason Green Committed by Alexandre Julliard

wined3d: Bind correct number of samplers for GLSL shaders.

We are only checking against GL_MAX_TEXTURES when binding samplers, when we should be checking against the maximum number of samplers that the card supports. Spotted by H. Verbeet.
parent e8992af0
......@@ -60,7 +60,7 @@ void shader_glsl_load_psamplers(
int i;
char sampler_name[20];
for (i=0; i< GL_LIMITS(textures); ++i) {
for (i=0; i< GL_LIMITS(samplers); ++i) {
if (stateBlock->textures[i] != NULL) {
snprintf(sampler_name, sizeof(sampler_name), "Psampler%d", i);
name_loc = GL_EXTCALL(glGetUniformLocationARB(programId, sampler_name));
......
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