Android Shader does not work at android

Mool

Member
Hello,
i have a little problem with my shaders.

If i apply shaders to my sprites or backgrounds, then nothing happens.
But if a apply the same shader to the application_surface, then they work.

So the Post draw works, but the normal draw event not.

On windows everything is fine.

#Huawei Honor 4x; 4.4.2;
 

Mool

Member
Code:
//
// Simple passthrough fragment shader
//
varying vec2 v_vTexcoord;
varying vec4 v_vColour;
uniform float iGlobalTime;
void main()
{
    vec2 uv = v_vTexcoord;
    vec4 textCol = texture2D( gm_BaseTexture, uv );
    
    vec3 col = textCol.rgb * vec3(vec2(0.5)+uv*vec2(0.5),0.5+0.5*sin(iGlobalTime));
    gl_FragColor = vec4(col,1.0);
}
GLSL ES
 
L

Lain V0hn Dyrec

Guest
when you draw your sprite and background, do you set their color to c_white? or -1?

i had this problem before coz i set the color to -1 (no blend).

-1 will work on computers while c_white will work on Androids
 
Top