const struct gl_uniform_storage *const uni = &shProg->UniformStorage[index];
if (nameOut) {
- _mesa_copy_string(nameOut, maxLength, length, uni->name);
+ _mesa_get_uniform_name(uni, maxLength, length, nameOut);
}
if (size) {
}
if (uniformName) {
- _mesa_copy_string(uniformName, bufSize, length,
- shProg->UniformStorage[uniformIndex].name);
+ _mesa_get_uniform_name(& shProg->UniformStorage[uniformIndex],
+ bufSize, length, uniformName);
}
}
+
+void
+_mesa_get_uniform_name(const struct gl_uniform_storage *uni,
+ GLsizei maxLength, GLsizei *length,
+ GLchar *nameOut)
+{
+ _mesa_copy_string(nameOut, maxLength, length, uni->name);
+}
extern const struct gl_program_parameter *
get_uniform_parameter(struct gl_shader_program *shProg, GLint index);
+extern void
+_mesa_get_uniform_name(const struct gl_uniform_storage *uni,
+ GLsizei maxLength, GLsizei *length,
+ GLchar *nameOut);
+
struct gl_builtin_uniform_element {
const char *field;
int tokens[STATE_LENGTH];