Clean up deferred shaders by moving common methods into shared glsl file

This commit is contained in:
Shyotl
2018-01-17 23:44:02 -06:00
parent ec91f9a026
commit 85cb3cb0d0
36 changed files with 214 additions and 842 deletions

View File

@@ -37,11 +37,7 @@ VARYING vec3 vary_normal;
VARYING vec4 vertex_color;
VARYING vec2 vary_texcoord0;
vec2 encode_normal(vec3 n)
{
float f = sqrt(8 * n.z + 8);
return n.xy / f + 0.5;
}
vec2 encode_normal(vec3 n);
void main()
{