Removed obsolete gamma correct shader used on macOS only

This commit is contained in:
alexey.lysiuk 2016-07-30 15:30:35 +03:00
parent 39059b3b5c
commit 7de242930a
3 changed files with 0 additions and 32 deletions

View file

@ -37,7 +37,6 @@ enum EEffect
EFF_SPHEREMAP, EFF_SPHEREMAP,
EFF_BURN, EFF_BURN,
EFF_STENCIL, EFF_STENCIL,
EFF_GAMMACORRECTION,
MAX_EFFECTS MAX_EFFECTS
}; };

View file

@ -395,7 +395,6 @@ static const FEffectShader effectshaders[]=
{ "spheremap", "shaders/glsl/main.vp", "shaders/glsl/main.fp", "shaders/glsl/func_normal.fp", "#define SPHEREMAP\n#define NO_ALPHATEST\n" }, { "spheremap", "shaders/glsl/main.vp", "shaders/glsl/main.fp", "shaders/glsl/func_normal.fp", "#define SPHEREMAP\n#define NO_ALPHATEST\n" },
{ "burn", "shaders/glsl/main.vp", "shaders/glsl/burn.fp", NULL, "#define SIMPLE\n#define NO_ALPHATEST\n" }, { "burn", "shaders/glsl/main.vp", "shaders/glsl/burn.fp", NULL, "#define SIMPLE\n#define NO_ALPHATEST\n" },
{ "stencil", "shaders/glsl/main.vp", "shaders/glsl/stencil.fp", NULL, "#define SIMPLE\n#define NO_ALPHATEST\n" }, { "stencil", "shaders/glsl/main.vp", "shaders/glsl/stencil.fp", NULL, "#define SIMPLE\n#define NO_ALPHATEST\n" },
{ "gammacorrection", "shaders/glsl/main.vp", "shaders/glsl/gammacorrection.fp", NULL, "#define SIMPLE\n" },
}; };

View file

@ -1,30 +0,0 @@
uniform sampler2D tex;
in vec4 vTexCoord;
in vec4 vColor;
out vec4 FragColor;
void main()
{
vec3 color = texture(tex, vTexCoord.st).rgb;
// /* DEBUG */ if (vTexCoord.x > 0.5)
{
// Apply contrast
float contrast = clamp(vColor.y, 0.1, 3.0);
color = color.rgb * contrast - (contrast - 1.0) * 0.5;
// Apply gamma
float gamma = clamp(vColor.x, 0.1, 4.0);
color = sign(color) * pow(abs(color), vec3(1.0 / gamma));
// Apply brightness
float brightness = clamp(vColor.z, -0.8, 0.8);
color += brightness * 0.5;
color = clamp(color, 0.0, 1.0);
}
FragColor = vec4(color, 1.0);
}