--- simple_color_flat.psh 2009-09-24 14:54:07.602620721 +0200 +++ simple_color_flat.psh.new2 2009-09-24 13:10:06.000000000 +0200 @@ -74,7 +74,8 @@ uniform sampler2D fogofwar; uniform vec2 vShadowLeak; uniform vec2 vShadowFalloff; -#if (SHADOWMAP_TYPE == 0) // SHADOWMAP_R32F +#if (SHADOWMAP_TYPE == 0) +// SHADOWMAP_R32F uniform float fShadowmapSize; uniform float fShadowmapSizeInv; @@ -113,7 +114,8 @@ float shadow_r32f() return clamp(fSample * vShadowLeak.x + vShadowLeak.y, 0.0, 1.0); } -#else // SHADOWMAP_DEPTH +#else +// SHADOWMAP_DEPTH uniform sampler2DShadow shadowmap; //==================== @@ -136,9 +138,11 @@ float shadow(float fCamDistance) float fFade = 0.0; #endif - #if (SHADOWMAP_TYPE == 0) // SHADOWMAP_R32F + #if (SHADOWMAP_TYPE == 0) + // SHADOWMAP_R32F float fShadowmap = shadow_r32f(); - #else // SHADOWMAP_DEPTH + #else + // SHADOWMAP_DEPTH float fShadowmap = shadow_depth(); #endif @@ -199,7 +203,8 @@ void main() vDiffuse += v_vDiffLight.xyz * fShadow; - #else // 0 or 1 + #else + // 0 or 1 vec3 vLight = vSunPositionWorld; @@ -231,9 +236,11 @@ void main() } #endif - #endif // LIGHTING_QUALITY + #endif + // LIGHTING_QUALITY -#else // LIGHTING == 0 +#else +// LIGHTING == 0 vec3 vDiffuse = vec3(1.0, 1.0, 1.0); #endif @@ -241,19 +248,25 @@ void main() // Fog // -#if (FOG_TYPE != 0) // FOG_NONE +#if (FOG_TYPE != 0) +// FOG_NONE #if (FOG_QUALITY == 1) float fFog = v_vData0.w; #else - #if (FOG_TYPE == 0) // FOG_NONE + #if (FOG_TYPE == 0) + // FOG_NONE float fFog = 0.0; - #elif (FOG_TYPE == 1) // FOG_LINEAR + #elif (FOG_TYPE == 1) + // FOG_LINEAR float fFog = clamp(fCamDistance * vFog.x + vFog.y, 0.0, 1.0) * vFog.z; - #elif (FOG_TYPE == 2) // FOG_EXP2 + #elif (FOG_TYPE == 2) + // FOG_EXP2 float fFog = 1.0 - exp2(-fCamDistance * fFogDensity); - #elif (FOG_TYPE == 3) // FOG_EXP + #elif (FOG_TYPE == 3) + // FOG_EXP float fFog = 1.0 - exp(-fCamDistance * fFogDensity); - #elif (FOG_TYPE == 4) // FOG_HERMITE + #elif (FOG_TYPE == 4) + // FOG_HERMITE float fFog = smoothstep(fFogStart, fFogEnd, fCamDistance) * fFogScale; #endif #endif