Closed larspensjo closed 10 years ago
Hi,
I don't have any modern AMD GPU at hand at the moment and I'm curious, what error message does the shader compiler print for the two fixed examples?
This is a copy of the error printed when I run the examples. I'll be happy to test more of the examples, but many of them require external file input that I can't find.
$ ./023_waves Program build error Source file: '/home/lars/src/oglplus/implement/oglplus/shader.ipp' Source line: 52 Source function: 'Compile' Message: 'OpenGL shading language compilation error' GL constant: 'TESS_EVALUATION_SHADER' Object type: 'SHADER' Object: 'TessEvaluation' Log: Tessellation evaluation shader failed to compile with the following errors: ERROR: 0:4: error(#198) Redefinition error: w ERROR: error(#273) 1 compilation errors. No code generated
$ ./031_brick_torus Program build error Source file: '/home/lars/src/oglplus/implement/oglplus/shader.ipp' Source line: 52 Source function: 'Compile' Message: 'OpenGL shading language compilation error' GL constant: 'GEOMETRY_SHADER' Object type: 'SHADER' Object: (3) Log: Geometry shader failed to compile with the following errors: ERROR: 0:3: error(#133) Reserved word: input ERROR: 0:3: error(#132) Syntax error: "input" parse error ERROR: error(#273) 2 compilation errors. No code generated
$ glxgears -info GL_RENDERER = AMD Radeon HD 7800 Series GL_VERSION = 4.3.12798 Compatibility Profile Context 13.35.1005 GL_VENDOR = ATI Technologies Inc.
I see, thanks for the feedback.
I've replaced the 'inp' parameter with 'attrib' (hopefully not reserved by AMD :))
"attrib" should be fine (but "attribute isn't). According to http://www.opengl.org/registry/doc/GLSLangSpec.4.10.6.clean.pdf section 3.6, "input" is a reserved keyword that will generate an error.
Yes, in the meantime I've had a look at the GLSL 4.30 specs and found that input
is indeed reserved for future use.
Thanks again for catching this.
023_waves: Redeclaration of 'w'. 031_brick_torus.cpp: illegal variable name 'input'.