src/render/opengl/SDL_shaders_gl.c
changeset 5229 c015d3e63631
parent 5228 811beeb698f9
child 5230 8efa43b915be
equal deleted inserted replaced
5228:811beeb698f9 5229:c015d3e63631
   181     for (i = 0; i < num_tmus_bound; ++i) {
   181     for (i = 0; i < num_tmus_bound; ++i) {
   182         char tex_name[5];
   182         char tex_name[5];
   183         SDL_snprintf(tex_name, SDL_arraysize(tex_name), "tex%d", i);
   183         SDL_snprintf(tex_name, SDL_arraysize(tex_name), "tex%d", i);
   184         location = ctx->glGetUniformLocationARB(data->program, tex_name);
   184         location = ctx->glGetUniformLocationARB(data->program, tex_name);
   185         if (location >= 0) {
   185         if (location >= 0) {
   186             ctx->glUniform1iARB(location, 1);
   186             ctx->glUniform1iARB(location, i);
   187         }
   187         }
   188     }
   188     }
   189     ctx->glUseProgramObjectARB(0);
   189     ctx->glUseProgramObjectARB(0);
   190     
   190     
   191     return (ctx->glGetError() == GL_NO_ERROR);
   191     return (ctx->glGetError() == GL_NO_ERROR);