try3.c: In function ‘main’:
try3.c:223: error: stray ‘\342’ in program
try3.c:223: error: stray ‘\200’ in program
try3.c:223: error: stray ‘\235’ in program
try3.c:223: error: stray ‘\342’ in program
try3.c:223: error: stray ‘\200’ in program
try3.c:223: error: stray ‘\235’ in program
try3.c:223: error: ‘texture’ undeclared (first use in this function)
try3.c:223: error: (Each undeclared identifier is reported only once
try3.c:223: error: for each function it appears in.)
I got this error. I dun know what is this error. Please help.
Here is the code:
static GLhandleARB programObject; // the program used to update
static GLhandleARB fragmentShader;
static GLint location; // a parameter to the fragment program
.
.
.
.
// Create the fragment program
fragmentShader = glCreateShaderObjectARB(GL_FRAGMENT_SHADER_ARB);
glShaderSourceARB(fragmentShader,1,&fragment_source,NULL);
glCompileShaderARB(fragmentShader);
glAttachObjectARB(programObject,fragmentShader);
// Link the shader into a complete GLSL program. glLinkProgramARB(programObject); glGetObjectParameterivARB(programObject,GL_OBJECT_LINK_STATUS_ARB,&progLinkSuccess); if (!progLinkSuccess){ fprintf(stderr, "Filter shader could not be linked
");
exit(1);
}
// Get location of the sampler uniform
location = glGetUniformLocationARB(programObject, ”texture”);
And the error comes from line 223. Which is the glGetUniformLocationARB() functions there.
Anyone experience this error? Please help…