Add glGetUniformIndices to GPU command buffer.
We try to return the cached data if available. Note that the cached data
do not come from previous glGetUniformIndices call, but from the internal
glGetProgramInfoCHROMIUM.
If that fails, we then send the GetUniformIndices command, which on the service
side call glGetUniformIndices() to query the info from the driver.
BUG=429053
TEST=gpu_unittests
[email protected]
Review URL: https://codereview.chromium.org/874743006
Cr-Commit-Position: refs/heads/master@{#316168}
diff --git a/gpu/command_buffer/cmd_buffer_functions.txt b/gpu/command_buffer/cmd_buffer_functions.txt
index e820b405..e3a6464 100644
--- a/gpu/command_buffer/cmd_buffer_functions.txt
+++ b/gpu/command_buffer/cmd_buffer_functions.txt
@@ -105,6 +105,7 @@
GL_APICALL GLuint GL_APIENTRY glGetUniformBlockIndex (GLidProgram program, const char* name);
GL_APICALL void GL_APIENTRY glGetUniformfv (GLidProgram program, GLintUniformLocation location, GLfloat* params);
GL_APICALL void GL_APIENTRY glGetUniformiv (GLidProgram program, GLintUniformLocation location, GLint* params);
+GL_APICALL void GL_APIENTRY glGetUniformIndices (GLidProgram program, GLsizeiNotNegative count, const char* const* names, GLuint* indices);
GL_APICALL GLint GL_APIENTRY glGetUniformLocation (GLidProgram program, const char* name);
GL_APICALL void GL_APIENTRY glGetVertexAttribfv (GLuint index, GLenumVertexAttribute pname, GLfloat* params);
GL_APICALL void GL_APIENTRY glGetVertexAttribiv (GLuint index, GLenumVertexAttribute pname, GLint* params);