Could someone enumerate for me exactly which texture properties are stored in a texture object and which ones aren’t? The ultimate thing would be to see the class / struct definition of a texture object.
If I bind a texture and call texParameter*(), these properties seem to stick. However, I just learned (through much hair pulling) that glTexGen() stuff does not
This is really making things difficult for me…can anyone shed some light on this?
IIRC, texture objects do not store state, however in a multitexturing environment, both texture stages store the appropriate state variables describing the texturing environment.
TexGen is entirely separate state from the texture itself. This generates vertex coordinate values.
It is desirable to keep state separate because you may want to bind a texture for use with changing state information without having to reimplement that state whenever you bind a texture.
It should be fairly intuitive what state is stored with a bound texture once you are familiar with the functionality. In the case of texgen this is enabled by glEnable(GL_TEXTURE_GEN_*), not glEnable(GL_TEXTURE_2D), and is clearly out of scope for a texbind.