From 58d485467a6cdec6003923121648f47bd4366354 Mon Sep 17 00:00:00 2001 From: "nor..67" Date: Fri, 22 Jul 2011 00:15:55 +0000 Subject: [PATCH] - fix lighting compile error git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7894 75d07b2b-3a1a-0410-a2c5-0572b91ccdca --- engine/src/core-data/Common/MatDefs/Light/Lighting.frag | 2 +- engine/src/core-data/Common/MatDefs/Light/Lighting.vert | 2 +- engine/src/terrain/Common/MatDefs/Terrain/TerrainLighting.frag | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/engine/src/core-data/Common/MatDefs/Light/Lighting.frag b/engine/src/core-data/Common/MatDefs/Light/Lighting.frag index 7709de54b..829f762c9 100644 --- a/engine/src/core-data/Common/MatDefs/Light/Lighting.frag +++ b/engine/src/core-data/Common/MatDefs/Light/Lighting.frag @@ -149,7 +149,7 @@ void main(){ #endif #ifndef VERTEX_LIGHTING float spotFallOff = 1.0; - if(spotVec.w!=0){ + if(spotVec.w!=0.0){ vec3 L=normalize(lightVec.xyz); vec3 spotdir = normalize(spotVec.xyz); float curAngleCos = dot(-L, spotdir); diff --git a/engine/src/core-data/Common/MatDefs/Light/Lighting.vert b/engine/src/core-data/Common/MatDefs/Light/Lighting.vert index 3f2d30930..419b800c9 100644 --- a/engine/src/core-data/Common/MatDefs/Light/Lighting.vert +++ b/engine/src/core-data/Common/MatDefs/Light/Lighting.vert @@ -112,7 +112,7 @@ vec2 computeLighting(in vec3 wvPos, in vec3 wvNorm, in vec3 wvViewDir, in vec4 w vec4 lightDir; lightComputeDir(wvPos, g_LightColor, wvLightPos, lightDir); float spotFallOff = 1.0; - if(spotVec.w!=0){ + if(spotVec.w!=0.0){ vec3 L=normalize(lightVec.xyz); vec3 spotdir = normalize(spotVec.xyz); float curAngleCos = dot(-L, spotdir); diff --git a/engine/src/terrain/Common/MatDefs/Terrain/TerrainLighting.frag b/engine/src/terrain/Common/MatDefs/Terrain/TerrainLighting.frag index 5e26a1011..e9f2e8467 100644 --- a/engine/src/terrain/Common/MatDefs/Terrain/TerrainLighting.frag +++ b/engine/src/terrain/Common/MatDefs/Terrain/TerrainLighting.frag @@ -647,7 +647,7 @@ void main(){ #endif float spotFallOff = 1.0; - if(spotVec.w!=0){ + if(spotVec.w!=0.0){ vec3 L=normalize(lightVec.xyz); vec3 spotdir = normalize(spotVec.xyz); float curAngleCos = dot(-L, spotdir);