This is because the `glUniform1i` calls were not preceeded by `glUseProgram` which made parameters not stick.