Problem:
I am learning OpenGL from the http://www.arcsynthesis.org/gltut/index.html tutorial and it was very difficult for me to get study guide 13: Geometry workers working (6+ hours)) and now it works after a really minor change code that won't actually work, and I need your help to find out why this is changing something.
Explanation - Edited:
The problem was that with the invariable code, the fragment shader did not get the correct input from the geometry shader, but either replacing the shader interface block with the geometry with separate variables, or giving the block an instance name, makes the program work fine. But these changes must be non-op.
The problem is probably a name clash.
How it doesnβt work:
in VertexData { vec3 cameraSpherePos; float sphereRadius; } vert[]; out FragData { flat vec3 cameraSpherePos; flat float sphereRadius; smooth vec2 mapping; }; void main() { mapping = cameraSpherePos = sphereRadius = EmitVertex(); }
But either providing FragData with an instance name such as frag, using the frag.mappaing layout function, or using 3 separate variables solves the problem.
Why doesn't it work without an instance name?
Edit: It looks like a driver issue.
Icecool
source share