diff --git a/Shaders/ws30-ALS-ultra.frag b/Shaders/ws30-ALS-ultra.frag index 8b2df9980..9ebf488c1 100644 --- a/Shaders/ws30-ALS-ultra.frag +++ b/Shaders/ws30-ALS-ultra.frag @@ -443,7 +443,11 @@ void main() if ((water_shader == 1) && (fg_photoScenery == false) && fg_materialParams3[lc].x > 0.5) { // This is a water fragment, so calculate the fragment color procedurally - texel = generateWaterTexel(); + // and mix with some sand colour if near an edge + //bool adjacentwater = fg_materialParams3[lc_n.x].x > 0.5; + //texel = mix(generateWaterTexel(), texel, adjacentwater ? 0.0 : smoothstep(0.1, 0.2, mfact[0])); + //texel = mix(generateWaterTexel(), vec4(0.6,0.6,0.4,1.0), adjacentwater ? 0.0 : smoothstep(0.1, 0.2, mfact[0])); + texel = mix(vec4(0.6,0.6,0.4,1.0), generateWaterTexel(), smoothstep(0.98,1.0,steepness)); fragColor = texel; fragColor.rgb += getClusteredLightsContribution(ecPosition.xyz, n, fragColor.rgb); } else {