GLint glGetAttribLocation(GLuint program, const GLchar *name);
The association between an attribute variable name and a generic attribute index can be specified at any time by calling glBindAttribLocation(). Attribute bindings do not go into effect until glLinkProgram() is called. After a program object has been linked successfully, the index values for attribute variables remain fixed until the next link command occurs. The attribute values can only be queried after a link if the link was successful. glGetAttribLocation returns the binding that actually went into effect the last time glLinkProgram() was called for the specified program object. Attribute bindings that have been specified since the last link operation are not returned by glGetAttribLocation.
GL_INVALID_OPERATION is generated if program is not a program object.
GL_INVALID_OPERATION is generated if program has not been successfully linked.
|Function / Feature Name||2.0||2.1||3.0||3.1||3.2||3.3||4.0||4.1||4.2||4.3||4.4||4.5|
Copyright © 2010-2014 Khronos Group