Attempt to fix effect shaders

This commit is contained in:
Siana Gearz
2012-08-30 02:58:50 +02:00
parent 32f9cbb11d
commit be2598bc4c
4 changed files with 19 additions and 10 deletions

View File

@@ -8,7 +8,9 @@
#extension GL_ARB_texture_rectangle : enable
#ifdef DEFINE_GL_FRAGCOLOR
out vec4 gl_FragColor;
out vec4 frag_color;
#else
#define frag_color gl_FragColor
#endif
uniform sampler2DRect tex0;
@@ -18,6 +20,6 @@ VARYING vec2 vary_texcoord0;
void main(void)
{
vec3 color = pow(floor(pow(vec3(texture2D(tex0, vary_texcoord0.st)),vec3(.6)) * layerCount)/layerCount,vec3(1.66666));
gl_FragColor = vec4(color, 1.0);
vec3 color = pow(floor(pow(vec3(texture2DRect(tex0, vary_texcoord0.st)),vec3(.6)) * layerCount)/layerCount,vec3(1.66666));
frag_color = vec4(color, 1.0);
}