PDA

View Full Version : GL_ZERO TexEnv?



09-02-2004, 02:58 PM
I can't find it documented anywhere but it seems to have the intended effect of "skipping" a texture stage if I call:


glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_ZERO);Is this kosher? It works here, but Lord knows what will happen down the road a few months...

dorbie
09-02-2004, 04:53 PM
No, this is illegal, it probably doesn't skip a stage it will still be enabled, the stage may be producing white but depending on the previous texenv that may have an undesired effect.

Do a glGetError and you'll see you've messed up.

Use glActiveTextureARB and glDisable to turn off a texture stage.

09-02-2004, 08:48 PM
I do not get anything from glGetError by passing GL_ZERO. I check every frame for glGetError and nothing occurs when this is called.

Something else illegal, like GL_ONE, for instance, kills the program like JFK.

09-03-2004, 04:44 PM
Nobody else, eh?

09-03-2004, 11:17 PM
man, you noobs are a trip. not only are you ungreatful for help, from a moderator no less, but you then decline to listen to his advice!
read the freakin spec if you dont believe him. once you are over the neck-ache from hanging your head in shame, return and say "thanks for the help!"

... maybe we need a "babe in the woods" forum.

09-05-2004, 02:55 PM
n00b my ass.

And if you'd read my reply, as I said, if I call

glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_ZERO);

glGetError() Does NOT report anything. Whether this is a "normal" thing or just on my drivers, I don't know, but you trolls who don't want to read everything are a trip.