I’m trying to learn some OpenGL via this tutorial.
My question is regarding these lines of code:
glObjectParameteri(GL_MODIFY, GL_OBJECT_AN_INTEGER, 5);
glObjectParameterf(GL_MODIFY, GL_OBJECT_A_FLOAT, 0.4f);
glObjectParameters(GL_MODIFY, GL_OBJECT_A_STRING, "Some String");
So far, an OpenGL object was made Object, bound to the target GL_MODIFY and now these codes are supposed to modify the contents of the object. My question is, what is the point of the second parameter in each of these functions? (GL_OBJECT_AN_INTEGER, GL_OBJECT_A_FLOAT, and GL_OBJECT_A_STRING) It seems that the function glObjectParameteri would be specific to integers since the function has an i at the end.
It’s the name of the parameter, not its type (example puts the type in the name to show what
i,fandssuffixes mean). There can be more than one parameter of each type, and I believe psychic abilities haven’t made their way into OpenGL standard yet.