/*
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
See https://js.arcgis.com/4.24/esri/copyright.txt for details.
*/
define(["exports","../../shaderModules/Float3PassUniform","../../shaderModules/FloatPassUniform","../../shaderModules/interfaces"],(function(i,n,t,a){"use strict";function o(i,o){const l=i.fragment;o.isGround?l.uniforms.add(new t.FloatPassUniform("lightingFixedFactor",((i,n)=>(1-n.lighting.groundLightingFactor)*(1-n.lighting.globalFactor)))):l.constants.add("lightingFixedFactor","float",0),l.uniforms.add([new n.Float3PassUniform("lightingMainDirection",((i,n)=>n.lighting.lightingMainDirection)),new n.Float3PassUniform("lightingMainIntensity",((i,n)=>n.lighting.mainLight.intensity))]),l.code.add(a.glsl`vec3 evaluateMainLighting(vec3 normal_global, float shadowing) {
float dotVal = clamp(dot(normal_global, lightingMainDirection), 0.0, 1.0);
dotVal = mix(dotVal, 1.0, lightingFixedFactor);
return lightingMainIntensity * ((1.0 - shadowing) * dotVal);
}`)}i.MainLighting=o,Object.defineProperties(i,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
