stk-code_catmod/data/shaders/ghost_karts.frag
Benau 23a1b08efe Allow normal map karts to be used in ghost race
Also split ghost karts out of additive shader, so fixed issues like
"drivers are facing backwards", "water in abyss affects ghost karts"

Todo: maybe transparency depend on current track color?
2016-10-16 15:40:40 +08:00

20 lines
378 B
GLSL

#ifdef Use_Bindless_Texture
layout(bindless_sampler) uniform sampler2D tex;
#else
uniform sampler2D tex;
#endif
in vec2 uv;
in vec4 color;
out vec4 FragColor;
void main()
{
vec4 Color = texture(tex, uv);
#ifdef Use_Bindless_Texture
Color.xyz = pow(Color.xyz, vec3(2.2));
#endif
Color.xyz *= pow(color.xyz, vec3(2.2));
FragColor = vec4(Color.rgb * 0.5, 0.5);
}