I have the following GLSL shader (being loaded into an OpenGL 3.3 forward context, but I get the same behavior in 2.1):
const GLchar* const glsl_vertex_timeseries = {
"#version 330\n"
"#extension GL_EXT_gpu_shader4 : enable\n"
""
"in vec2 in_Y;"
""
"void main()"
"{"
// " int dummy = gl_VertexID;"
" gl_Position = vec4(in_Y, 0.0, 1.0);"
"}"
};
It's very much simplified in order to locate the problem.
As shown, it compiles, links, and my geometry displays.
If the commented line is activated, it compiles and links without warnings, but nothing renders (glClear
still works, but not glDrawArrays
).
What is needed to make gl_VertexID
work?
The application is a 32-bit C++ program running on Windows 7 64-bit. Video card is an ATI Mobility Radeon 5650, Catalyst 8.812