- glGetProgramiv(id, GL_ACTIVE_ATTRIBUTES, &count);
- for(int i=0; i<count; ++i)
+ count = get_program_i(id, GL_ACTIVE_ATTRIBUTES);
+ for(unsigned i=0; i<count; ++i)
- glGetProgramiv(id, GL_ACTIVE_UNIFORM_BLOCKS, &count);
- for(int i=0; i<count; ++i)
+ count = get_program_i(id, GL_ACTIVE_UNIFORM_BLOCKS);
+ for(unsigned i=0; i<count; ++i)
glGetActiveUniformBlockiv(id, i, GL_UNIFORM_BLOCK_DATA_SIZE, &value);
info.data_size = value;
glGetActiveUniformBlockiv(id, i, GL_UNIFORM_BLOCK_DATA_SIZE, &value);
info.data_size = value;
char *buf = new char[len+1];
glGetProgramInfoLog(id, len+1, &len, buf);
string log(buf, len);
char *buf = new char[len+1];
glGetProgramInfoLog(id, len+1, &len, buf);
string log(buf, len);