title: In OpenGL is there a way to get a list of all uniforms & attribs used by a shader program?
body: <p>I'd like to get a list of all the uniforms &amp; attribs used by a shader program object.  <code>glGetAttribLocation()</code> &amp; <code>glGetUniformLocation()</code> can be used to map a string to a location, but what I would really like is the list of strings without having to parse the glsl code.</p>
  
  <p>Note: In OpenGL 2.0 <code>glGetObjectParameteriv()</code> is replaced by <code>glGetProgramiv()</code>.  And the enum is <code>GL_ACTIVE_UNIFORMS</code> &amp; <code>GL_ACTIVE_ATTRIBUTES</code>.</p>