1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[30364],{59384:function(e,t,r){r.d(t,{f:function(){return h}});var i=r(78177);r(95263);var a=r(58583),n=r(10314),o=r(93988),s=r(58046);let l=()=>a.Z.getLogger("esri.views.webgl.BufferObject");class h{static createIndex(e,t,r){return new h(e,s.w0.ELEMENT_ARRAY_BUFFER,t,r)}static createVertex(e,t,r){return new h(e,s.w0.ARRAY_BUFFER,t,r)}static createUniform(e,t,r){return new h(e,s.w0.UNIFORM_BUFFER,t,r)}static createPixelPack(e,t=s.l1.STREAM_READ,r){let i=new h(e,s.w0.PIXEL_PACK_BUFFER,t);return r&&i.setSize(r),i}static createPixelUnpack(e,t=s.l1.STREAM_DRAW,r){return new h(e,s.w0.PIXEL_UNPACK_BUFFER,t,r)}static createTransformFeedback(e,t=s.l1.STATIC_DRAW,r){let i=new h(e,s.w0.TRANSFORM_FEEDBACK_BUFFER,t);return i.setSize(r),i}constructor(e,t,r,i){this._context=e,this.bufferType=t,this.usage=r,this._glName=null,this._size=-1,this._indexType=void 0,e.instanceCounter.increment(s._g.BufferObject,this),this._glName=this._context.gl.createBuffer(),(0,o.zu)(this._context.gl),i&&this.setData(i)}get glName(){return this._glName}get size(){return this._size}get indexType(){return this._indexType}get usedMemory(){if(this.bufferType===s.w0.ELEMENT_ARRAY_BUFFER){if(this._indexType===s.g.UNSIGNED_INT)return 4*this._size;if(this._indexType===s.g.UNSIGNED_SHORT)return 2*this._size}return this._size}get _isVAOAware(){return this.bufferType===s.w0.ELEMENT_ARRAY_BUFFER||this.bufferType===s.w0.ARRAY_BUFFER}dispose(){this._context?.gl?(this._glName&&(this._context.gl.deleteBuffer(this._glName),this._glName=null),this._context.instanceCounter.decrement(s._g.BufferObject,this),this._context=null):this._glName&&l().warn("Leaked WebGL buffer object")}setSize(e,t=null){if(this.bufferType===s.w0.ELEMENT_ARRAY_BUFFER&&null!=t)switch(this._indexType=t,t){case s.g.UNSIGNED_SHORT:e*=2;break;case s.g.UNSIGNED_INT:e*=4}this._setBufferData(e)}setData(e){if(!e)return;let t=e.byteLength;this.bufferType===s.w0.ELEMENT_ARRAY_BUFFER&&((0,n.lq)(e)?this._indexType=s.g.UNSIGNED_BYTE:(0,n.Uc)(e)?(t/=2,this._indexType=s.g.UNSIGNED_SHORT):(0,n.ZY)(e)&&(t/=4,this._indexType=s.g.UNSIGNED_INT)),this._setBufferData(t,e)}_setBufferData(e,t=null){this._size=e;let r=this._context.getBoundVAO();this._isVAOAware&&this._context.bindVAO(null),this._context.bindBuffer(this);let i=this._context.gl;null!=t?i.bufferData(this.bufferType,t,this.usage):i.bufferData(this.bufferType,e,this.usage),(0,o.zu)(i),this._isVAOAware&&this._context.bindVAO(r)}setSubData(e,t,r,i){if(!e)return;let a=this._context.getBoundVAO();this._isVAOAware&&this._context.bindVAO(null),this._context.bindBuffer(this);let{gl:n}=this._context;n.bufferSubData(this.bufferType,t*e.BYTES_PER_ELEMENT,e,r,i-r),(0,o.zu)(n),this._isVAOAware&&this._context.bindVAO(a)}getSubData(e,t=0,r,a){if(r<0||a<0)return;let n=(0,i.zG)(e)?e.BYTES_PER_ELEMENT:1;if(n*((r??0)+(a??0))>e.byteLength)return;t+n*(a??0)>this.usedMemory&&l().warn("Potential problem getting subdata: requested data exceeds buffer size!");let o=this._context.gl;this.bufferType===s.w0.TRANSFORM_FEEDBACK_BUFFER?(this._context.bindBuffer(this,s.w0.TRANSFORM_FEEDBACK_BUFFER),o.getBufferSubData(s.w0.TRANSFORM_FEEDBACK_BUFFER,t,e,r,a),this._context.unbindBuffer(s.w0.TRANSFORM_FEEDBACK_BUFFER)):(this._context.bindBuffer(this,s.w0.COPY_READ_BUFFER),o.getBufferSubData(s.w0.COPY_READ_BUFFER,t,e,r,a),this._context.unbindBuffer(s.w0.COPY_READ_BUFFER))}async getSubDataAsync(e,t=0,r,i){await this._context.clientWaitAsync(),this.get
1SubData(e,t,r,i)}}},38054:function(e,t,r){r.d(t,{$:function(){return g}}),r(95263);var i=r(93988),a=r(58046);let n=["layout","centroid","smooth","case","mat2x2","mat2x3","mat2x4","mat3x2","mat3x3","mat3x4","mat4x2","mat4x3","mat4x4","uint","uvec2","uvec3","uvec4","samplerCubeShadow","sampler2DArray","sampler2DArrayShadow","isampler2D","isampler3D","isamplerCube","isampler2DArray","usampler2D","usampler3D","usamplerCube","usampler2DArray","coherent","restrict","readonly","writeonly","resource","atomic_uint","noperspective","patch","sample","subroutine","common","partition","active","filter","image1D","image2D","image3D","imageCube","iimage1D","iimage2D","iimage3D","iimageCube","uimage1D","uimage2D","uimage3D","uimageCube","image1DArray","image2DArray","iimage1DArray","iimage2DArray","uimage1DArray","uimage2DArray","image1DShadow","image2DShadow","image1DArrayShadow","image2DArrayShadow","imageBuffer","iimageBuffer","uimageBuffer","sampler1DArray","sampler1DArrayShadow","isampler1D","isampler1DArray","usampler1D","usampler1DArray","isampler2DRect","usampler2DRect","samplerBuffer","isamplerBuffer","usamplerBuffer","sampler2DMS","isampler2DMS","usampler2DMS","sampler2DMSArray","isampler2DMSArray","usampler2DMSArray","trunc","round","roundEven","isnan","isinf","floatBitsToInt","floatBitsToUint","intBitsToFloat","uintBitsToFloat","packSnorm2x16","unpackSnorm2x16","packUnorm2x16","unpackUnorm2x16","packHalf2x16","unpackHalf2x16","outerProduct","transpose","determinant","inverse","texture","textureSize","textureProj","textureLod","textureOffset","texelFetch","texelFetchOffset","textureProjOffset","textureLodOffset","textureProjLod","textureProjLodOffset","textureGrad","textureGradOffset","textureProjGrad","textureProjGradOffset"],o=["precision","highp","mediump","lowp","attribute","const","uniform","varying","break","continue","do","for","while","if","else","in","out","inout","float","int","void","bool","true","false","discard","return","mat2","mat3","mat4","vec2","vec3","vec4","ivec2","ivec3","ivec4","uvec2","uvec3","uvec4","bvec2","bvec3","bvec4","sampler1D","sampler2D","sampler3D","usampler1D","usampler2D","usampler3D","samplerCube","sampler1DShadow","sampler2DShadow","struct","asm","class","union","enum","typedef","template","this","packed","goto","switch","default","inline","noinline","volatile","public","static","extern","external","interface","long","short","double","half","fixed","unsigned","input","output","hvec2","hvec3","hvec4","dvec2","dvec3","dvec4","fvec2","fvec3","fvec4","sampler2DRect","sampler3DRect","sampler2DRectShadow","sizeof","cast","namespace","using"],s=["<<=",">>=","++","--","<<",">>","<=",">=","==","!=","&&","||","+=","-=","*=","/=","%=","&=","^^","^=","|=","(",")","[","]",".","!","~","*","/","%","+","-","<",">","&","^","|","?",":","=",",",";","{","}"],l=["abs","acos","all","any","asin","atan","ceil","clamp","cos","cross","dFdx","dFdy","degrees","distance","dot","equal","exp","exp2","faceforward","floor","fract","gl_BackColor","gl_BackLightModelProduct","gl_BackLightProduct","gl_BackMaterial","gl_BackSecondaryColor","gl_ClipPlane","gl_ClipVertex","gl_Color","gl_DepthRange","gl_DepthRangeParameters","gl_EyePlaneQ","gl_EyePlaneR","gl_EyePlaneS","gl_EyePlaneT","gl_Fog","gl_FogCoord","gl_FogFragCoord","gl_FogParameters","gl_FragColor","gl_FragCoord","gl_FragData","gl_FragDepth","gl_FragDepthEXT","gl_FrontColor","gl_FrontFacing","gl_FrontLightModelProduct","gl_FrontLightProduct","gl_FrontMaterial","gl_FrontSecondaryColor","gl_LightModel","gl_LightModelParameters","gl_LightModelProducts","gl_LightProducts","gl_LightSource","gl_LightSourceParameters","gl_MaterialParameters","gl_MaxClipPlanes","gl_MaxCombinedTextureImageUnits","gl_MaxDrawBuffers","gl_MaxFragmentUniformComponents","gl_MaxLights","gl_MaxTextureCoords","gl_MaxTextureImageUnits","gl_MaxTextureUnits","gl_MaxVaryingFloats","gl_MaxVertexAttribs","gl_MaxVertexTextureImageUnits","gl_MaxVertexUniformComponents","gl_ModelViewMatrix","gl_ModelViewMatrixInverse","gl_ModelViewMatrixInverseTranspose","gl_ModelViewMatrixTranspose","gl_ModelViewProjectionMatrix","gl_ModelViewProjectionMatrixInverse","gl_ModelViewProjectionMatrixInverseTranspose","gl_ModelViewProjectionMatrixTranspose","gl_MultiTexCoord0","gl_MultiTexCoord1","gl_MultiTexCoord2","gl_MultiTexCoord3","gl_MultiTexCoord4","gl_MultiTexCoord5","gl_MultiTexCoord6","gl_MultiTexCoord7","gl_Normal","gl_NormalMatrix","gl_NormalScale","gl_ObjectPlaneQ","gl_ObjectPlaneR","gl_ObjectPlaneS","gl_ObjectPlaneT","gl_Point","gl_PointCoord","gl_PointParameters","gl_PointSize","gl_Position","gl_ProjectionMatrix","gl_ProjectionMatrixInverse","gl_ProjectionMatrixInverseTranspose","gl_ProjectionMatrixTranspose","gl_SecondaryColor","gl_TexCoord","gl_TextureEnvColor","gl_TextureMatrix","gl_TextureMatrixInverse","gl_TextureMatrixInverseTranspose","gl_TextureMatrixTranspose","gl_Vertex","greaterThan","greaterThanEqual","inversesqrt","length","lessThan","lessThanEqual","log","log2","matrixCompMult","max","min","mix","mod","normalize","not","notEqual","pow","radians","reflect","refract","sign","sin","smoothstep","sqrt","step","tan","texture2D","texture2DLod","texture2DProj","texture2DProjLod","textureCube","textureCubeLod","texture2DLodEXT","texture2DProjLodEXT","textureCubeLodEXT","texture2DGradEXT","texture2DProjGradEXT","textureCubeGradEXT","textureSize","texelFetch"];var h=["block-comment","line-comment","preprocessor","operator","integer","float","ident","builtin","keyword","whitespace","eof","integer"];let f=new Set(["GL_OES_standard_derivatives","GL_EXT_frag_depth","GL_EXT_draw_buffers","GL_EXT_shader_texture_lod"]);
1function u(e,t,r,i){for(let a of(i=i||r,e))if("ident"===a.type&&a.data===r)return i in t?t[i]++:t[i]=0,u(e,t,i+"_"+t[i],i);return r}function c(e,t,r="afterVersion"){let i={data:"\n",type:"whitespace"},a=t=>t<e.length&&/[^\r\n]$/.test(e[t].data),n=function(e){let t=-1,i=0,a=-1;for(let n=0;n<e.length;n++){let o=e[n];if("preprocessor"===o.type&&(/#(if|ifdef|ifndef)\s+.+/.test(o.data)?++i:/#endif\s*.*/.test(o.data)&&--i),"afterVersion"!==r&&"afterPrecision"!==r||"preprocessor"===o.type&&o.data.startsWith("#version")&&(a=Math.max(a,n)),"afterPrecision"===r&&"keyword"===o.type&&"precision"===o.data){let t=function(e,t){for(let r=t;r<e.length;r++){let t=e[r];if("operator"===t.type&&";"===t.data)return r}return null}(e,n);if(null===t)throw Error("precision statement not followed by any semicolons!");a=Math.max(a,t)}t<a&&0===i&&(t=n)}return t+1}(e);for(let r of(a(n-1)&&e.splice(n++,0,i),t))e.splice(n++,0,r);a(n-1)&&a(n)&&e.splice(n,0,i)}function _(e,t){var r,i;if(e.startsWith("#version 300"))return e;let _=[].concat((r=function(){var e,t,r,i=0,a=0,n=999,f=[],u=[],c=1,_=0,g=0,d=!1,m=!1,p="";return function(s){return u=[],null!==s?function(s){var h;for(i=0,r=(p+=s).length;e=p[i],i<r;){switch(h=i,n){case 0:"/"===e&&"*"===t?(f.push(e),x(f.join("")),n=999):(f.push(e),t=e),i+=1;break;case 1:case 2:i=function(){return"\r"!==e&&"\n"!==e||"\\"===t?(f.push(e),t=e,i+1):(x(f.join("")),n=999,i)}();break;case 3:i=function(){if("."===t&&/\d/.test(e))return n=5,i;if("/"===t&&"*"===e)return n=0,i;if("/"===t&&"/"===e)return n=1,i;if("."===e&&f.length){for(;y(f););return n=5,i}if(";"===e||")"===e||"("===e){if(f.length)for(;y(f););return x(e),n=999,i+1}var r=2===f.length&&"="!==e;if(/[\w_\d\s]/.test(e)||r){for(;y(f););return n=999,i}return f.push(e),t=e,i+1}();break;case 4:i="."===e||/[eE]/.test(e)?(f.push(e),n=5,t=e,i+1):"x"===e&&1===f.length&&"0"===f[0]?(n=11,f.push(e),t=e,i+1):/[^\d]/.test(e)?(x(f.join("")),n=999,i):(f.push(e),t=e,i+1);break;case 11:i=/[^a-fA-F0-9]/.test(e)?(x(f.join("")),n=999,i):(f.push(e),t=e,i+1);break;case 5:"f"===e&&(f.push(e),t=e,i+=1),i=/[eE]/.test(e)||"-"===e&&/[eE]/.test(t)?(f.push(e),t=e,i+1):/[^\d]/.test(e)?(x(f.join("")),n=999,i):(f.push(e),t=e,i+1);break;case 9999:i=function(){if(/[^\d\w_]/.test(e)){var r=f.join("");return n=o.indexOf(r)>-1?8:l.indexOf(r)>-1?7:6,x(f.join("")),n=999,i}return f.push(e),t=e,i+1}();break;case 9:i=/[^\s]/g.test(e)?(x(f.join("")),n=999,i):(f.push(e),t=e,i+1);break;case 999:f=f.length?[]:f,i="/"===t&&"*"===e?(g=a+i-1,n=0,t=e,i+1):"/"===t&&"/"===e?(g=a+i-1,n=1,t=e,i+1):("#"===e?(n=2,g=a+i):/\s/.test(e)?(n=9,g=a+i):(d=/\d/.test(e),m=/[^\w_]/.test(e),g=a+i,n=d?4:m?3:9999),i)}h!==i&&("\n"===p[h]?(_=0,++c):++_)}return a+=i,p=p.slice(i),u}(s.replace?s.replace(/\r\n/g,"\n"):s):(f.length&&x(f.join("")),n=10,x("(eof)"),u)};function x(e){e.length&&u.push({type:h[n],data:e,position:g,line:c,column:_})}function y(e){for(var t,r,i=0;;){if(t=s.indexOf(e.slice(0,e.length+i).join("")),r=s[t],-1===t){if(i--+e.length>0)continue;r=e.slice(0,1).join("")}return x(r),g+=r.length,(f=f.slice(r.length)).length}}}())(e)).concat(r(null));if("300 es"===function(e,t="100",r="300 es"){let i=/^\s*#version\s+([0-9]+(\s+[a-zA-Z]+)?)\s*/;for(let a of e)if("preprocessor"===a.type){let e=i.exec(a.data);if(e){let i=e[1].replaceAll(/\s{2,}/g," ");if(i===r)return i;if(i===t)return a.data="#version "+r,t;throw Error("unknown glsl version: "+i)}}return e.splice(0,0,{type:"preprocessor",data:"#version "+r},{type:"whitespace",data:"\n"}),null}(_,"100","300 es"))return e;let g=null,d=null,m={},p={};for(let e=0;e<_.length;++e){let r=_[e];switch(r.type){case"keyword":t===a.Ho.VERTEX_SHADER&&"attribute"===r.data?r.data="in":"varying"===r.data&&(r.data=t===a.Ho.VERTEX_SHADER?"out":"in");break;case"builtin":if(/^texture(2D|Cube)(Proj)?(Lod|Grad)?(EXT)?$/.test(r.data.trim())&&(r.data=r.data.replaceAll(/(2D|Cube|EXT)/g,"")),t===a.Ho.FRAGMENT_SHADER&&"gl_FragColor"===r.data&&(g||(g=u(_,m,"fragColor"),function(e,t,r,i="lowp"){c(e,[{type:"keyword",data:"out"},{type:"whitespace",data:" "},{type:"keyword",data:i},{type:"whitespace",data:" "},{type:"keyword",data:r},{type:"whitespace",data:" "},{type:"ident",data:t},{type:"operator",data:";"}],"afterPrecision")}(_,g,"vec4")),r.data=g),t===a.Ho.FRAGMENT_SHADER&&"gl_FragData"===r.data){let t=function(e,t){let r,i,a=-1;for(let n=t;n<e.length;n++){let t=e[n];if("operator"===t.type&&("["===t.data&&(r=n),"]"===t.data)){i=n;break}"integer"===t.type&&(a=parseInt(t.data,10))}return r&&i&&e.splice(r,i-r+1),a}(_,e+1),i=u(_,m,"fragData");(function(e,t,r,i,a="lowp"){c(e,[{type:"keyword",data:"layout"},{type:"operator",data:"("},{type:"keyword",data:"location"},{type:"whitespace",data:" "},{type:"operator",data:"="},{type:"whitespace",data:" "},{type:"integer",data:i.toString()},{type:"operator",data:")"},{type:"whitespace",data:" "},{type:"keyword",data:"out"},{type:"whitespace",data:" "},{type:"keyword",data:a},{type:"whitespace",data:" "},{type:"keyword",data:r},{type:"whitespace",data:" "},{type:"ident",data:t},{type:"operator",data:";"}],"afterPrecision")})(_,i,"vec4",t,"mediump"),r.data=i}else t===a.Ho.FRAGMENT_SHADER&&"gl_FragDepthEXT"===r.data&&(d||(d=u(_,m,"gl_FragDepth")),r.data=d);break;
1case"ident":if(n.includes(r.data)){if(t===a.Ho.VERTEX_SHADER&&function(e,t){for(let r=t-1;r>=0;r--){let t=e[r];if("whitespace"!==t.type&&"block-comment"!==t.type){if("keyword"!==t.type)break;if("attribute"===t.data||"in"===t.data)return!0}}return!1}(_,e))throw Error("attribute in vertex shader uses a name that is a reserved word in glsl 300 es");r.data in p||(p[r.data]=u(_,m,r.data)),r.data=p[r.data]}}}for(let e=_.length-1;e>=0;--e){let t=_[e];if("preprocessor"===t.type){let r=t.data.match(/#extension\s+(.*):/);if(r?.[1]&&f.has(r[1].trim())){let t=_[e+1];_.splice(e,t&&"whitespace"===t.type?2:1)}let i=t.data.match(/#ifdef\s+(.*)/);i?.[1]&&f.has(i[1].trim())&&(t.data="#if 1");let a=t.data.match(/#ifndef\s+(.*)/);a?.[1]&&f.has(a[1].trim())&&(t.data="#if 0")}}return _.map(e=>"eof"!==e.type?e.data:"").join("")}class g{constructor(e,t,r,n,o=new Map,s=[]){this._context=e,this._locations=n,this._uniformBlockBindings=o,this._transformFeedbackVaryings=s,this._refCount=1,this._compiled=!1,this._linesOfCode=0,this._nameToUniformLocation=new Map,this._nameToUniform1=new Map,this._nameToUniform1v=new Map,this._nameToUniform2=new Map,this._nameToUniform3=new Map,this._nameToUniform4=new Map,this._nameToUniformMatrix3=new Map,this._nameToUniformMatrix4=new Map,e||console.error("RenderingContext isn't initialized!"),0===t.length&&console.error("Shaders source should not be empty!"),t=_(t,a.Ho.VERTEX_SHADER),r=_(r,a.Ho.FRAGMENT_SHADER),this._vShader=d(this._context,a.Ho.VERTEX_SHADER,t),this._fShader=d(this._context,a.Ho.FRAGMENT_SHADER,r),p.enabled&&(this._linesOfCode=t.match(/\n/g).length+r.match(/\n/g).length+2,this._context.instanceCounter.increment(a._g.LinesOfCode,this._vShader,this._linesOfCode)),this._vShader&&this._fShader||console.error("Error loading shaders!"),this._context.instanceCounter.increment(a._g.Shader,this),(0,i.CG)()&&(this.vertexShader=t,this.fragmentShader=r),this.usedMemory=t.length+r.length;let l=this._context.gl,h=l.createProgram();for(let[e,t]of(l.attachShader(h,this._vShader),l.attachShader(h,this._fShader),this._locations.forEach((e,t)=>l.bindAttribLocation(h,e,t)),this._transformFeedbackVaryings?.length&&l.transformFeedbackVaryings(h,this._transformFeedbackVaryings,l.SEPARATE_ATTRIBS),l.linkProgram(h),(0,i.CG)()&&!l.getProgramParameter(h,l.LINK_STATUS)&&console.error(`Could not link shader 2validated: ${l.getProgramParameter(h,l.VALIDATE_STATUS)}, gl error ${l.getError()}, vertex: ${l.getShaderParameter(this._vShader,l.COMPILE_STATUS)}, fragment: ${l.getShaderParameter(this._fShader,l.COMPILE_STATUS)}, info log: ${l.getProgramInfoLog(h)}, vertex source: ${this.vertexShader}, fragment source: ${this.fragmentShader}`),this._uniformBlockBindings)){let r=l.getUniformBlockIndex(h,e);r<4294967295&&l.uniformBlockBinding(h,r,t)}this._glName=h,this._context.instanceCounter.increment(a._g.Program,this)}get glName(){return this._glName}get hasGLName(){return null!=this._glName}get hasTransformFeedbackVaryings(){return!!this._transformFeedbackVaryings?.length}get compiled(){return!!this._compiled||(this._context.capabilities.parallelShaderCompile&&null!=this.glName?(this._compiled=!!this._context.gl.getProgramParameter(this.glName,a.hj.COMPLETION_STATUS_KHR),this._compiled):(this._compiled=!0,!0))}dispose(){if(--this._refCount>0)return;let e=this._context.gl,t=this._context.instanceCounter;this._nameToUniformLocation.forEach(e=>e&&t.decrement(a._g.Uniform,e)),this._nameToUniformLocation.clear(),this._vShader&&(this._linesOfCode>0&&(t.decrement(a._g.LinesOfCode,this._vShader,this._linesOfCode),this._linesOfCode=0),e.deleteShader(this._vShader),this._vShader=null,t.decrement(a._g.Shader,this)),this._fShader&&(e.deleteShader(this._fShader),this._fShader=null),this._glName&&(e.deleteProgram(this._glName),this._glName=null,t.decrement(a._g.Program,this))}ref(){++this._refCount}_getUniformLocation(e){let t=this._nameToUniformLocation.get(e);if(void 0!==t)return t;if(this.glName){let t=this._context.gl.getUniformLocation(this.glName,e);return this._nameToUniformLocation.set(e,t),t&&this._context.instanceCounter.increment(a._g.Uniform,t),t}return null}hasUniform(e){return null!=this._getUniformLocation(e)}setUniform1i(e,t){x(t);let r=this._nameToUniform1.get(e);void 0!==r&&t===r||(this._context.gl.uniform1i(this._getUniformLocation(e),t),this._nameToUniform1.set(e,t))}
2setUniform1iv(e,t){y(t),m(this._nameToUniform1v,e,t)&&this._context.gl.uniform1iv(this._getUniformLocation(e),t)}setUniform2iv(e,t){y(t),m(this._nameToUniform2,e,t)&&this._context.gl.uniform2iv(this._getUniformLocation(e),t)}setUniform3iv(e,t){y(t),m(this._nameToUniform3,e,t)&&this._context.gl.uniform3iv(this._getUniformLocation(e),t)}setUniform4iv(e,t){y(t),m(this._nameToUniform4,e,t)&&this._context.gl.uniform4iv(this._getUniformLocation(e),t)}setUniform1f(e,t){x(t);let r=this._nameToUniform1.get(e);void 0!==r&&t===r||(this._context.gl.uniform1f(this._getUniformLocation(e),t),this._nameToUniform1.set(e,t))}setUniform1fv(e,t){y(t),m(this._nameToUniform1v,e,t)&&this._context.gl.uniform1fv(this._getUniformLocation(e),t)}setUniform2f(e,t,r){x(t,r);let i=this._nameToUniform2.get(e);void 0===i?(this._context.gl.uniform2f(this._getUniformLocation(e),t,r),this._nameToUniform2.set(e,[t,r])):t===i[0]&&r===i[1]||(this._context.gl.uniform2f(this._getUniformLocation(e),t,r),i[0]=t,i[1]=r)}setUniform2fv(e,t){y(t),m(this._nameToUniform2,e,t)&&this._context.gl.uniform2fv(this._getUniformLocation(e),t)}setUniform3f(e,t,r,i){x(t,r,i);let a=this._nameToUniform3.get(e);void 0===a?(this._context.gl.uniform3f(this._getUniformLocation(e),t,r,i),this._nameToUniform3.set(e,[t,r,i])):t===a[0]&&r===a[1]&&i===a[2]||(this._context.gl.uniform3f(this._getUniformLocation(e),t,r,i),a[0]=t,a[1]=r,a[2]=i)}setUniform3fv(e,t){y(t);let r=this._getUniformLocation(e);null!=r&&m(this._nameToUniform3,e,t)&&this._context.gl.uniform3fv(r,t)}setUniform4f(e,t,r,i,a){x(t,r,i,a);let n=this._nameToUniform4.get(e);void 0===n?(this._context.gl.uniform4f(this._getUniformLocation(e),t,r,i,a),this._nameToUniform4.set(e,[t,r,i,a])):void 0!==n&&t===n[0]&&r===n[1]&&i===n[2]&&a===n[3]||(this._context.gl.uniform4f(this._getUniformLocation(e),t,r,i,a),n[0]=t,n[1]=r,n[2]=i,n[3]=a)}setUniform4fv(e,t){y(t);let r=this._getUniformLocation(e);null!=r&&m(this._nameToUniform4,e,t)&&this._context.gl.uniform4fv(r,t)}setUniformMatrix3fv(e,t,r=!1){y(t);let i=this._getUniformLocation(e);null!=i&&m(this._nameToUniformMatrix3,e,t)&&this._context.gl.uniformMatrix3fv(i,r,t)}setUniformMatrix4fv(e,t,r=!1){y(t);let i=this._getUniformLocation(e);null!=i&&m(this._nameToUniformMatrix4,e,t)&&this._context.gl.uniformMatrix4fv(i,r,t)}stop(){}}function d(e,t,r){let n;let o=e.gl,s=o.createShader(t);return o.shaderSource(s,r),o.compileShader(s),(0,i.CG)()&&!o.getShaderParameter(s,o.COMPILE_STATUS)&&(console.error("Compile error in ".concat(t===a.Ho.VERTEX_SHADER?"vertex":"fragment"," shader")),console.error(o.getShaderInfoLog(s)),console.error((n=2,r.replaceAll("\n",()=>{var e;return"\n"+((e=n++)>=1e3?e.toString():(" "+e).slice(-3))+":"})))),s}function m(e,t,r){let i=e.get(t);if(!i)return e.set(t,Array.from(r)),!0;let a=r.length;if(i.length!==a)return e.set(t,Array.from(r)),!0;for(let e=0;e<a;++e){let t=r[e];if(i[e]!==t){for(i[e]=t;e<a;++e)i[e]=r[e];return!0}}return!1}let p={enabled:!1},x=(0,i.hZ)()?(...e)=>y(e):()=>{},y=(0,i.hZ)()?e=>{let t=e.length;for(let r=0;r<t;++r){let t=e[r];Number.isNaN(t)&&console.error(`Got ${t} as uniform value from ${Error().stack}`)}}:()=>{}},65357:function(e,t,r){r.d(t,{H:function(){return a}});var i=r(38054);function a(e,t,r=""){return new i.$(e,r+t.shaders.vertexShader,r+t.shaders.fragmentShader,t.attributes)}},11881:function(e,t,r){r.d(t,{B:function(){return i}});class i{constructor(e){this._readFile=e}resolveIncludes(e){return this._resolve(e)}_resolve(e,t=new Map){if(t.has(e))return t.get(e);let r=this._read(e);if(!r)throw Error(`cannot find shader file ${e}`);let i=/^[^\S\n]*#include\s+<(\S+)>[^\S\n]?/gm,a=i.exec(r),n=[];for(;null!=a;)n.push({path:a[1],start:a.index,length:a[0].length}),a=i.exec(r);let o=0,s="";return n.forEach(e=>{s+=r.slice(o,e.start)+(t.has(e.path)?"":this._resolve(e.path,t)),o=e.start+e.length}),s+=r.slice(o),t.set(e,s),s}_read(e){return this._readFile(e)}}},33761:function(e,t,r){r.d(t,{U:function(){return h}});var i=r(58583),a=r(4509),n=r(63592),o=r(58046),s=r(1399);let l=()=>i.Z.getLogger("esri.views.webgl.VertexArrayObject"),h=class{constructor(e,t,r,i,a=null){this._context=e,this._locations=t,this._layout=r,this._buffers=i,this._indexBuffer=a,this._glName=null,this._initialized=!1}get glName(){return this._glName}get context(){return this._context}get vertexBuffers(){return this._buffers}get indexBuffer(){return this._indexBuffer}getByteLength(e){return this._buffers.get(e)?.usedMemory??0}get layout(){return this._layout}get locations(){return this._locations}get usedMemory(){return Array.from(this._buffers.values()).reduce((e,t)=>
2e+t.usedMemory,this._indexBuffer?.usedMemory??0+(this._buffers.size+(this._indexBuffer?1:0))*n.Qi)}get cachedMemory(){return this.usedMemory}dispose(){this._context?(this._context.getBoundVAO()===this&&this._context.bindVAO(null),this._buffers.forEach(e=>e.dispose()),this._buffers.clear(),this._indexBuffer=(0,a.M2)(this._indexBuffer),this.disposeVAOOnly()):(this._glName||this._buffers.size>0)&&l().warn("Leaked WebGL VAO")}disposeVAOOnly(){this._glName&&(this._context.gl.deleteVertexArray(this._glName),this._glName=null,this._context.instanceCounter.decrement(o._g.VertexArrayObject,this)),this._context=null}initialize(){if(this._initialized)return;let{gl:e}=this._context,t=e.createVertexArray();e.bindVertexArray(t),this._bindLayout(),e.bindVertexArray(null),this._glName=t,this._context.instanceCounter.increment(o._g.VertexArrayObject,this),this._initialized=!0}bind(){this.initialize(),this._context.gl.bindVertexArray(this.glName)}_bindLayout(){let{_buffers:e,_layout:t,_indexBuffer:r}=this;e||l().error("Vertex buffer dictionary is empty!");let i=this._context.gl;this._buffers.forEach((e,r)=>{let i=t.get(r);i?(0,s.XP)(this._context,this._locations,e,i):l().error("Vertex element descriptor is empty!")}),null!=r&&i.bindBuffer(i.ELEMENT_ARRAY_BUFFER,r.glName)}unbind(){this.initialize(),this._context.gl.bindVertexArray(null)}}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.