Opened 7 years ago

Closed 7 years ago

#977 closed defect (fixed)

Health Bars shader errors

Reported by: abma Owned by:
Priority: major Milestone:
Component: BA trunk Version:
Keywords: Cc:

Description

happens with ati open source drivers:

[f=0000000] Error: OpenGL: source<Shader> type<error> id<3> severity<high>:
0:17(6): error: operands of `==' must have the same type
[f=0000000] Error: OpenGL: source<Shader> type<error> id<4> severity<high>:
0:20(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<5> severity<high>:
0:21(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<6> severity<high>:
0:24(12): error: operands of `==' must have the same type
[f=0000000] Error: OpenGL: source<Shader> type<error> id<7> severity<high>:
0:28(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<8> severity<high>:
0:29(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<9> severity<high>:
0:31(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<10> severity<high>:
0:31(2): error: value of type int cannot be assigned to variable of type float
[f=0000000] Error: OpenGL: source<Shader> type<error> id<11> severity<high>:
0:33(12): error: operands of `==' must have the same type
[f=0000000] Error: OpenGL: source<Shader> type<error> id<12> severity<high>:
0:37(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<13> severity<high>:
0:38(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<14> severity<high>:
0:40(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<15> severity<high>:
0:40(2): error: value of type int cannot be assigned to variable of type float
[f=0000000] Error: OpenGL: source<Shader> type<error> id<16> severity<high>:
0:42(12): error: operands of `==' must have the same type
[f=0000000] Error: OpenGL: source<Shader> type<error> id<17> severity<high>:
0:46(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<18> severity<high>:
0:47(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<19> severity<high>:
0:49(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<20> severity<high>:
0:49(2): error: value of type int cannot be assigned to variable of type float
[f=0000000] Error: OpenGL: source<Shader> type<error> id<21> severity<high>:
0:51(12): error: could not implicitly convert operands to relational operator
[f=0000000] Error: OpenGL: source<Shader> type<error> id<22> severity<high>:
0:51(12): error: if-statement condition must be scalar boolean
[f=0000000] Error: OpenGL: source<Shader> type<error> id<23> severity<high>:
0:53(38): error: could not implicitly convert operands to arithmetic operator
[f=0000000] Error: OpenGL: source<Shader> type<error> id<24> severity<high>:
0:53(25): error: operands to arithmetic operators must be numeric
[f=0000000] Error: OpenGL: source<Shader> type<error> id<25> severity<high>:
0:53(74): error: could not implicitly convert operands to arithmetic operator
[f=0000000] Error: OpenGL: source<Shader> type<error> id<26> severity<high>:
0:53(61): error: operands to arithmetic operators must be numeric
[f=0000000] Error: OpenGL: source<Shader> type<error> id<27> severity<high>:
0:53(110): error: could not implicitly convert operands to arithmetic operator
[f=0000000] Error: OpenGL: source<Shader> type<error> id<28> severity<high>:
0:53(97): error: operands to arithmetic operators must be numeric
[f=0000000] Error: OpenGL: source<Shader> type<error> id<29> severity<high>:
0:53(18): error: no function with name 'float4'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<30> severity<high>:
0:55(38): error: could not implicitly convert operands to arithmetic operator
[f=0000000] Error: OpenGL: source<Shader> type<error> id<31> severity<high>:
0:55(25): error: operands to arithmetic operators must be numeric
[f=0000000] Error: OpenGL: source<Shader> type<error> id<32> severity<high>:
0:55(74): error: could not implicitly convert operands to arithmetic operator
[f=0000000] Error: OpenGL: source<Shader> type<error> id<33> severity<high>:
0:55(61): error: operands to arithmetic operators must be numeric
[f=0000000] Error: OpenGL: source<Shader> type<error> id<34> severity<high>:
0:55(110): error: could not implicitly convert operands to arithmetic operator
[f=0000000] Error: OpenGL: source<Shader> type<error> id<35> severity<high>:
0:55(97): error: operands to arithmetic operators must be numeric
[f=0000000] Error: OpenGL: source<Shader> type<error> id<36> severity<high>:
0:55(18): error: no function with name 'float4'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<37> severity<high>:
0:59(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<38> severity<high>:
0:60(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<39> severity<high>:
0:62(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<40> severity<high>:
0:71(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<41> severity<high>:
0:72(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<42> severity<high>:
0:74(2): error: assignment to read-only variable 'gl_Vertex'
[f=0000000] Error: OpenGL: source<Shader> type<error> id<43> severity<high>:
0:76(2): error: assignment to read-only variable 'gl_Vertex'

Change History (3)

comment:1 by abma, 7 years ago

this fixes all errors for me, but the result looks broken:

http://paste.springfiles.com/view/raw/7c73ed4a

what am i doing wrong? :-/

comment:2 by beherith, 7 years ago

Did you forget to change gl_Vertex to vertex on the last line?

gl_Position = gl_ModelViewProjectionMatrix*gl_Vertex;

If this still does not fix it, could you post a screenshot of your result?

comment:3 by abma, 7 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.