diff options
Diffstat (limited to 'src/renderergl2/glsl')
-rw-r--r-- | src/renderergl2/glsl/generic_fp.glsl | 33 | ||||
-rw-r--r-- | src/renderergl2/glsl/generic_vp.glsl | 9 |
2 files changed, 1 insertions, 41 deletions
diff --git a/src/renderergl2/glsl/generic_fp.glsl b/src/renderergl2/glsl/generic_fp.glsl index aefa33c3..50db0785 100644 --- a/src/renderergl2/glsl/generic_fp.glsl +++ b/src/renderergl2/glsl/generic_fp.glsl @@ -1,45 +1,12 @@ uniform sampler2D u_DiffuseMap; -#if defined(USE_LIGHTMAP) -uniform sampler2D u_LightMap; - -uniform int u_Texture1Env; -#endif - varying vec2 var_DiffuseTex; -#if defined(USE_LIGHTMAP) -varying vec2 var_LightTex; -#endif - varying vec4 var_Color; void main() { vec4 color = texture2D(u_DiffuseMap, var_DiffuseTex); -#if defined(USE_LIGHTMAP) - vec4 color2 = texture2D(u_LightMap, var_LightTex); - #if defined(RGBM_LIGHTMAP) - color2.rgb *= color2.a; - color2.a = 1.0; - #endif - - if (u_Texture1Env == TEXENV_MODULATE) - { - color *= color2; - } - else if (u_Texture1Env == TEXENV_ADD) - { - color += color2; - } - else if (u_Texture1Env == TEXENV_REPLACE) - { - color = color2; - } - - //color = color * (u_Texture1Env.xxxx + color2 * u_Texture1Env.z) + color2 * u_Texture1Env.y; -#endif - gl_FragColor = color * var_Color; } diff --git a/src/renderergl2/glsl/generic_vp.glsl b/src/renderergl2/glsl/generic_vp.glsl index 859b4363..bbe08e84 100644 --- a/src/renderergl2/glsl/generic_vp.glsl +++ b/src/renderergl2/glsl/generic_vp.glsl @@ -9,7 +9,7 @@ attribute vec3 attr_Normal2; attribute vec4 attr_Color; attribute vec4 attr_TexCoord0; -#if defined(USE_LIGHTMAP) || defined(USE_TCGEN) +#if defined(USE_TCGEN) attribute vec4 attr_TexCoord1; #endif @@ -57,9 +57,6 @@ uniform float u_VertexLerp; #endif varying vec2 var_DiffuseTex; -#if defined(USE_LIGHTMAP) -varying vec2 var_LightTex; -#endif varying vec4 var_Color; #if defined(USE_DEFORM_VERTEXES) @@ -230,10 +227,6 @@ void main() var_DiffuseTex = tex; #endif -#if defined(USE_LIGHTMAP) - var_LightTex = attr_TexCoord1.st; -#endif - #if defined(USE_RGBAGEN) var_Color = CalcColor(position, normal); #else |