I’m having a weird problem with a fragment program that uses non-consecutive tex units.
My fragment program uses TEX with texture,2D and texture,2D (but does not touch texture), and I am binding textures to these units with:
This works, until I also have something bound to GL_TEXTURE0+1, at which points it all goes pear shaped - the fragments all come out ‘black’.
Attempting to somehow ‘unbind’ tex unit 1 (with glActiveTexture/glBindTexture target,0 ) doesn’t help.
Is it legal to uses tex units like this? I can’t find anything in the ARB spec about it not being legal so assumed it was.
The reason I am not just renaming the tex units to 0/1 is because I am writing a little preprocessor designed to ‘strip’ bits of fragment code out for lesser HW.
My hardware is a MacG5 running OSx10.3.8 with a GeForce6800 Ultra.