From: numzero Date: Sun, 2 Apr 2023 18:24:36 +0000 (+0300) Subject: OpenGL3: Drop always-zero vSpecularColor from the shaders X-Git-Url: https://git.lizzy.rs/?a=commitdiff_plain;h=462657960d9a71de142937cb29e30917d57845af;p=irrlicht.git OpenGL3: Drop always-zero vSpecularColor from the shaders --- diff --git a/media/Shaders/OneTextureBlend.fsh b/media/Shaders/OneTextureBlend.fsh index c348016..7ecb7e1 100644 --- a/media/Shaders/OneTextureBlend.fsh +++ b/media/Shaders/OneTextureBlend.fsh @@ -18,7 +18,6 @@ uniform float uFogDensity; varying vec2 vTextureCoord0; varying vec4 vVertexColor; -varying vec4 vSpecularColor; varying float vFogCoord; float computeFog() @@ -54,7 +53,6 @@ void main() Color1 = texture2D(uTextureUnit0, vTextureCoord0); vec4 FinalColor = Color0 * Color1; - FinalColor += vSpecularColor; if (uBlendType == 1) { diff --git a/media/Shaders/Solid.fsh b/media/Shaders/Solid.fsh index df1010e..c85c6ba 100644 --- a/media/Shaders/Solid.fsh +++ b/media/Shaders/Solid.fsh @@ -17,7 +17,6 @@ uniform float uFogDensity; varying vec2 vTextureCoord0; varying vec4 vVertexColor; -varying vec4 vSpecularColor; varying float vFogCoord; float computeFog() @@ -50,7 +49,6 @@ void main() if (bool(uTextureUsage0)) Color *= texture2D(uTextureUnit0, vTextureCoord0); - Color += vSpecularColor; if (bool(uFogEnable)) { diff --git a/media/Shaders/Solid.vsh b/media/Shaders/Solid.vsh index c260409..7379e5b 100644 --- a/media/Shaders/Solid.vsh +++ b/media/Shaders/Solid.vsh @@ -20,7 +20,6 @@ uniform float uThickness; varying vec2 vTextureCoord0; varying vec4 vVertexColor; -varying vec4 vSpecularColor; varying float vFogCoord; void main() @@ -32,7 +31,6 @@ void main() vTextureCoord0 = vec4(uTMatrix0 * TextureCoord0).xy; vVertexColor = inVertexColor.bgra; - vSpecularColor = vec4(0.0, 0.0, 0.0, 0.0); vec3 Position = (uWVMatrix * vec4(inVertexPosition, 1.0)).xyz; diff --git a/media/Shaders/TransparentAlphaChannel.fsh b/media/Shaders/TransparentAlphaChannel.fsh index cef349a..8491068 100644 --- a/media/Shaders/TransparentAlphaChannel.fsh +++ b/media/Shaders/TransparentAlphaChannel.fsh @@ -18,7 +18,6 @@ uniform float uFogDensity; varying vec2 vTextureCoord0; varying vec4 vVertexColor; -varying vec4 vSpecularColor; varying float vFogCoord; float computeFog() @@ -57,7 +56,6 @@ void main() if (Color.a < uAlphaRef) discard; } - Color += vSpecularColor; if (bool(uFogEnable)) { diff --git a/media/Shaders/TransparentAlphaChannelRef.fsh b/media/Shaders/TransparentAlphaChannelRef.fsh index fab4eee..ac762f0 100644 --- a/media/Shaders/TransparentAlphaChannelRef.fsh +++ b/media/Shaders/TransparentAlphaChannelRef.fsh @@ -18,7 +18,6 @@ uniform float uFogDensity; varying vec2 vTextureCoord0; varying vec4 vVertexColor; -varying vec4 vSpecularColor; varying float vFogCoord; float computeFog() @@ -55,8 +54,6 @@ void main() if (Color.a < uAlphaRef) discard; - Color += vSpecularColor; - if (bool(uFogEnable)) { float FogFactor = computeFog(); diff --git a/media/Shaders/TransparentVertexAlpha.fsh b/media/Shaders/TransparentVertexAlpha.fsh index df1010e..c85c6ba 100644 --- a/media/Shaders/TransparentVertexAlpha.fsh +++ b/media/Shaders/TransparentVertexAlpha.fsh @@ -17,7 +17,6 @@ uniform float uFogDensity; varying vec2 vTextureCoord0; varying vec4 vVertexColor; -varying vec4 vSpecularColor; varying float vFogCoord; float computeFog() @@ -50,7 +49,6 @@ void main() if (bool(uTextureUsage0)) Color *= texture2D(uTextureUnit0, vTextureCoord0); - Color += vSpecularColor; if (bool(uFogEnable)) {