Hi guys,
I am developing some shader programs, and I encountered some problems when I try to run them on an ATI graphic card, although the same version on nVidia does compile without any errors.
Here is the bit incriminated:
void calDiffuseSpecular(Light light, vec4 pos, vec3 norm, vec4 camPos, float shininess,
out vec4 diffuseOut, out vec4 specularOut)
{
// some code …
vec4 lightVec = normalize(light.position - pos);
float diffuseLight = max(dot(norm, lightVec), 0);
error on previous line
ERROR: 0:129: ‘dot’ : no matching overloaded function found
ERROR: 0:129: ‘max’ : no matching overloaded function found
I tried to cast both lightVec and norm to vec4, but it was still not working. Any ideas of what is wrong?
Some more info about the graphic card:
Version: 1.5.4517 WinXP Release
Vendor: ATI Technologies Inc.
Renderer: RADEON 9550 x86/SSE2
Many thank
Alexis