View Full Version : Setting constants in AFP

07-16-2003, 12:52 PM

After executing such sequence:

glProgramEnvParameter4fARB(GL_FRAGMENT_PROGRAM_ARB ,0,0,0,0,0);
glProgramEnvParameter4fARB(GL_FRAGMENT_PROGRAM_ARB ,0,1,1,1,0);

the value of the program.env[0] is equal to (0,0,0,0). Is it a driver bug or a correct behavior?
Hardware: GeForceFX 5200

[This message has been edited by h2 (edited 07-16-2003).]

07-16-2003, 05:46 PM
You don't need to bind before making that call and I don't think you need to have FP enabled.

How do you know it's all zeroes?

07-17-2003, 01:25 AM
I modulate with program.env[0] in FP and it looks like it's black, not white.

07-17-2003, 01:38 AM
I also experienced this, for local constants, It worked in cases when i didnt change the program ( kept the one all the time) but when i changed to another and back again the parameter wasn't updated ( bump specular), i moved the constant into the program itself and that worked.. I dont own a FX card so i couldnt test it anymore, but it felt like a driverbug. ( same program worked on an ATI card, but since that is what i develop on its not that strange http://www.opengl.org/discussion_boards/ubb/smile.gif )

07-17-2003, 02:24 AM

Really, It works only when I don't switch to another program. Looks like we share the same problem.

Damn, is there any bug-free driver? http://www.opengl.org/discussion_boards/ubb/frown.gif
My program doesn't work on ATI due to their render-texture bug, which is not being fixed for three or four months despite the fact that I sent a bugreport to them http://www.opengl.org/discussion_boards/ubb/frown.gif

[This message has been edited by h2 (edited 07-17-2003).]