Goldoche
Member
I'm using a very simple shader for my game which displays a sprite pure white.
shader.vsh:
shader.fsh:
This works fine on windows but on linux it just displays a white box.
Windows:
Linux:
I've already tried setting the shader type from "GLSL ES" to "GLSL" but it makes no difference. Anybody knows what could be wrong?
I have two slightly more complex shaders that seem to display fine on Linux.
shader.vsh:
Code:
attribute vec3 in_Position; // (x,y,z)
attribute vec4 in_Colour; // (r,g,b,a)
attribute vec2 in_TextureCoord; // (u,v)
varying vec2 v_vTexcoord;
varying vec4 v_vColour;
void main()
{
vec4 object_space_pos = vec4( in_Position.x, in_Position.y, in_Position.z, 1.0);
gl_Position = gm_Matrices[MATRIX_WORLD_VIEW_PROJECTION] * object_space_pos;
v_vColour = in_Colour;
v_vTexcoord = in_TextureCoord;
}
Code:
varying vec2 v_vTexcoord;
varying vec4 v_vColour;
void main()
{
vec4 couleur = texture2D( gm_BaseTexture, v_vTexcoord );
if (couleur.a != 0.0)
gl_FragColor = vec4(1.0,1.0,1.0,1.0);
}
Windows:
Linux:
I've already tried setting the shader type from "GLSL ES" to "GLSL" but it makes no difference. Anybody knows what could be wrong?
I have two slightly more complex shaders that seem to display fine on Linux.