shader_fp = glCreateShader(GL_FRAGMENT_SHADER); glShaderSourceARB(shader_fp, 1, &program_string, 0); glCompileShaderARB(shader_fp); shader_id = glCreateProgram(); glAttachShader(shader_id, shader_fp); glLinkProgramARB(shader_id);
and in the draw function I have...
glUseProgram(shader_id);
and in the fs program_string I have as a simple test...
void main(void) {
gl_FragColor = vec4(0.5, 0.0, 0.0, 1.0);
}
but everything is drawn as if the fs program is not called. Everything should be red instead. If I use glEnable(GL_FRAGMENT_PROGRAM_ARB); then the output is the backgound blue color as set with glClearColor.
Can anyine spot what my problem is? Thanks!












