diff --git a/src/ol/webgl/map.js b/src/ol/webgl/map.js index 7199c3fe93..860e351334 100644 --- a/src/ol/webgl/map.js +++ b/src/ol/webgl/map.js @@ -73,8 +73,8 @@ ol.webgl.map.shader.Fragment = function() { ' }', '', ' if (uSaturation != 0.) {', - ' float average = (color.r + color.g + color.b) / 3.0;', - ' if (uSaturation > 0.0) {', + ' float average = (color.r + color.g + color.b) / 3.;', + ' if (uSaturation > 0.) {', ' color.rgb += (average - color.rgb)', ' * (1. - 1. / (1. - uSaturation));', ' } else {', @@ -85,7 +85,7 @@ ol.webgl.map.shader.Fragment = function() { ' color.rgb += uBrightness;', '', ' if (uContrast != 0.) {', - ' if (uContrast > 0.0) {', + ' if (uContrast > 0.) {', ' color.rgb = (color.rgb - 0.5) / (1. - uContrast) + 0.5;', ' } else {', ' color.rgb = (color.rgb - 0.5) * (1. + uContrast) + 0.5;',