<!-- SAGA-STAGING · part 162 -->
}function mr(t,e){t.uniform1iv(this.addr,e)}function fr(t,e){t.uniform2iv(this.addr,e)}function gr(t,e){t.uniform3iv(this.addr,e)}function vr(t,e){t.uniform4iv(this.addr,e)}function yr(t,e){t.uniform1uiv(this.addr,e)}function xr(t,e){t.uniform2uiv(this.addr,e)}function _r(t,e){t.uniform3uiv(this.addr,e)}function wr(t,e){t.uniform4uiv(this.addr,e)}function br(t,e,n){const i=e.length,r=Ui(n,i);t.uniform1iv(this.addr,r);for(let t=0;t!==i;++t)n.safeSetTexture2D(e[t]||Ri,r[t])}function Mr(t,e,n){const i=e.length,r=Ui(n,i);t.uniform1iv(this.addr,r);for(let t=0;t!==i;++t)n.safeSetTextureCube(e[t]||Di,r[t])}function Sr(t,e,n){this.id=t,this.addr=n,this.cache=[],this.setValue=function(t){switch(t){case 5126:return ki;case 35664:return Vi;case 35665:return Wi;case 35666:return ji;case 35674:return qi;case 35675:return Xi;case 35676:return Yi;case 5124:case 35670:return Zi;case 35667:case 35671:return Ji;case 35668:case 35672:return Qi;case 35669:case 35673:return Ki;case 5125:return $i;case 36294:return tr;case 36295:return er;case 36296:return nr;case 35678:case 36198:case 36298:case 36306:case 35682:return ir;case 35679:case 36299:case 36307:return rr;case 35680:case 36300:case 36308:case 36293:return sr;case 36289:case 36303:case 36311:case 36292:return ar}}(e.type)}function Tr(t,e,n){this.id=t,this.addr=n,this.cache=[],this.size=e.size,this.setValue=function(t){switch(t){case 5126:return or;case 35664:return lr;case 35665:return cr;case 35666:return hr;case 35674:return ur;case 35675:return dr;case 35676:return pr;case 5124:case 35670:return mr;case 35667:case 35671:return fr;case 35668:case 35672:return gr;case 35669:case 35673:return vr;case 5125:return yr;case 36294:return xr;case 36295:return _r;case 36296:return wr;case 35678:case 36198:case 36298:case 36306:case 35682:return br;case 35680:case 36300:case 36308:case 36293:return Mr}}(e.type)}function Er(t){this.id=t,this.seq=[],this.map={}}Tr.prototype.updateCache=function(t){const e=this.cache;t instanceof Float32Array&&e.length!==t.length&&(this.cache=new Float32Array(t.length)),Gi(e,t)},Er.prototype.setValue=function(t,e,n){const i=this.seq;for(let r=0,s=i.length;r!==s;++r){const s=i[r];s.setValue(t,e[s.id],n)}};const Ar=/(\w+)(\])?(\[|\.)?/g;function Lr(t,e){t.seq.push(e),t.map[e.id]=e}function Rr(t,e,n){const i=t.name,r=i.length;for(Ar.lastIndex=0;;){const s=Ar.exec(i),a=Ar.lastIndex;let o=s[1];const l="]"===s[2],c=s[3];if(l&&(o|=0),void 0===c||"["===c&&a+2===r){Lr(n,void 0===c?new Sr(o,t,e):new Tr(o,t,e));break}{let t=n.map[o];void 0===t&&(t=new Er(o),Lr(n,t)),n=t}}}function Cr(t,e){this.seq=[],this.map={};const n=t.getProgramParameter(e,35718);for(let i=0;i<n;++i){const n=t.getActiveUniform(e,i);Rr(n,t.getUniformLocation(e,n.name),this)}}function Pr(t,e,n){const i=t.createShader(e);return t.shaderSource(i,n),t.compileShader(i),i}Cr.prototype.setValue=function(t,e,n,i){const r=this.map[e];void 0!==r&&r.setValue(t,n,i)},Cr.prototype.setOptional=function(t,e,n){const i=e[n];void 0!==i&&this.setValue(t,n,i)},Cr.upload=function(t,e,n,i){for(let r=0,s=e.length;r!==s;++r){const s=e[r],a=n[s.id];!1!==a.needsUpdate&&s.setValue(t,a.value,i)}},Cr.seqWithValue=function(t,e){const n=[];for(let i=0,r=t.length;i!==r;++i){const r=t[i];r.id in e&&n.push(r)}return n};let Dr=0;function Ir(t){switch(t){case X:return["Linear","( value )"];case Y:return["sRGB","( value )"];case J:return["RGBE","( value )"];case Q:return["RGBM","( value, 7.0 )"];case K:return["RGBM","( value, 16.0 )"];case $:return["RGBD","( value, 256.0 )"];case Z:return["Gamma","( value, float( GAMMA_FACTOR ) )"];case 3003:return["LogLuv","( value )"];default:return console.warn("THREE.WebGLProgram: Unsupported encoding:",t),["Linear","( value )"]}}function Nr(t,e,n){const i=t.getShaderParameter(e,35713),r=t.getShaderInfoLog(e).trim();if(i&&""===r)return"";return"THREE.WebGLShader: gl.getShaderInfoLog() "+n+"\n"+r+function(t){const e=t.split("\n");for(let t=0;t<e.length;t++)e[t]=t+1+": "+e[t];return e.join("\n")}(t.getShaderSource(e))}function Br(t,e){const n=Ir(e);return"vec4 "+t+"( vec4 value ) { return "+n[0]+"ToLinear"+n[1]+"; }"}function zr(t,e){const n=Ir(e);return"vec4 "+t+"( vec4 value ) { return LinearTo"+n[0]+n[1]+"; }"}function Fr(t,e){let n;switch(e){case 1:n="Linear";break;case 2:n="Reinhard";break;case 3:n="OptimizedCineon";break;case 4:n="ACESFilmic";break;case 5:n="Custom";break;default:console.warn("THREE.WebGLProgram: Unsupported toneMapping:",e),n="Linear"}return"vec3 "+t+"( vec3 color ) { return "+n+"ToneMapping( color ); }"}function Or(t){return""!==t}function Hr(t,e){return t.replace(/NUM_DIR_LIGHTS/g,e.numDirLights).replace(/NUM_SPOT_LIGHTS/g,e.numSpotLights).replace(/NUM_RECT_AREA_LIGHTS/g,e.numRectAreaLights).replace(/NUM_POINT_LIGHTS/g,e.numPointLights).replace(/NUM_HEMI_LIGHTS/g,e.numHemiLights).replace(/NUM_DIR_LIGHT_SHADOWS/g,e.numDirLightShadows).replace(/NUM_SPOT_LIGHT_SHADOWS/g,e.numSpotLightShadows).replace(/NUM_POINT_LIGHT_SHADOWS/g,e.nu