1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5670],{94672:function(e,t,r){r.d(t,{QM:function(){return a},hy:function(){return s},uI:function(){return i}});var n=r(3957),o=r(19431);const i=(()=>{if(!("document"in n.Z))return()=>null;const e=document.createElement("canvas"),t=e.getContext("2d");return e.height=512,e.width=1,r=>{t.clearRect(0,0,1,e.height);const n=t.createLinearGradient(0,0,0,e.height);for(const{ratio:e,color:t}of r.colorStops)n.addColorStop(Math.max(e,.001),`rgba(${t[0]}, ${t[1]}, ${t[2]}, ${t[3]})`);return t.fillStyle=n,t.fillRect(0,0,1,e.height),t.getImageData(0,0,1,e.height).data}})();function a(e,t,r,n){const{blurRadius:o,fieldOffset:i,field:a}=t,s=new Float64Array(r*n),c=l(o),d=Math.round(3*o);let u,h=Number.NEGATIVE_INFINITY;const f=function(e,t){return null!=e?"string"==typeof t?t=>-1*+t.readAttribute(e):r=>+r.readAttribute(e)+t:e=>1}(a,i),p=new Set;for(const l of e){const e=l.getCursor();for(;e.next();){const t=e.getObjectId();if(p.has(t))continue;p.add(t);const o=e.readLegacyPointGeometry(),i=128;if(o.x<-i||o.x>=r+i||o.y<-i||o.y>n+i)continue;const a=+f(e),l=Math.round(o.x)-d,y=Math.round(o.y)-d,m=Math.max(0,l),M=Math.max(0,y),g=Math.min(n,Math.round(o.y)+d),w=Math.min(r,Math.round(o.x)+d);for(let e=M;e<g;e++){const t=c[e-y];for(let n=m;n<w;n++){const o=c[n-l];u=s[e*r+n]+=t*o*a,u>h&&(h=u)}}}}return{matrix:s.buffer,max:h}}function s(e,t,r,n,i,a){e.canvas.width=e.canvas.height=t,e.clearRect(0,0,t,t);const s=e.getImageData(0,0,t,t);r&&n&&s.data.set(new Uint8ClampedArray(function(e,t,r,n,i){const a=new Uint32Array(e*e),s="buffer"in t?t:new Float64Array(t),l="buffer"in r?new Uint32Array(r.buffer):new Uint32Array(new Uint8Array(r).buffer),c=l.length/(i-n);for(let d=0;d<s.length;d++){const e=s[d],t=Math.floor((e-n)*c);a[d]=l[(0,o.uZ)(t,0,l.length-1)]}return a.buffer}(t,r,n,i,a))),e.putImageData(s,0,0)}function l(e){const t=Math.round(3*e),r=2*e*e,n=new Float64Array(2*t+1);for(let o=0;o<=n.length;o++)n[o]=Math.exp(-((o-t)**2)/r)/Math.sqrt(2*Math.PI)*(e/2);return n}},67766:function(e,t,r){var n=r(36663),o=(r(39994),r(13802),r(7283),r(81977)),i=r(66645),a=(r(3466),r(12173),r(51876),r(53280));let s=class extends a.r{initialize(){}destroy(){}get supportsTileUpdates(){return!1}get spatialReference(){const e=this.get("tileStore.tileScheme.spatialReference");return e&&e.toJSON()||null}};(0,n._)([(0,o.Cb)({readOnly:!0})],s.prototype,"supportsTileUpdates",null),(0,n._)([(0,o.Cb)({constructOnly:!0})],s.prototype,"remoteClient",void 0),(0,n._)([(0,o.Cb)({constructOnly:!0})],s.prototype,"service",void 0),(0,n._)([(0,o.Cb)()],s.prototype,"spatialReference",null),(0,n._)([(0,o.Cb)({constructOnly:!0})],s.prototype,"tileInfo",void 0),(0,n._)([(0,o.Cb)({constructOnly:!0})],s.prototype,"tileStore",void 0),s=(0,n._)([(0,i.j)("esri.views.2d.layers.features.processors.BaseProcessor")],s);var l=s;t.Z=l},5670:function(e,t,r){r.r(t);var n=r(36663),o=(r(39994),r(61681)),i=(r(13802),r(7283),r(81977),r(66645)),a=(r(3466),r(12173),r(51876),r(27281)),s=r(14266),l=r(94672),c=r(6413),d=r(67766);class u{constructor(e,t){this.offset=e,this.extent=t}}let h=class extends d.Z{constructor(){super(...arguments),this.type="heatmap",this._tileKeyToFeatureSets=new Map}initialize(){this.handles.add([this.tileStore.on("update",this.onTileUpdate.bind(this))])}async update(e,t){const r=t.schema.processors[0];"heatmap"===r.type&&(0,a.Hg)(this._schema,r)&&(e.mesh=!0,this._schema=r)}onTileUpdate(e){for(const t of e.removed)this._tileKeyToFeatureSets.delete(t.key.id)}onTileClear(e){return this._tileKeyToFeatureSets.delete(e.key.id),this.remoteClient.invoke("tileRenderer.onTileData",{tileKey:e.id,data:{clear:!0}})}async onTileMessage(e,t,r){this._tileKeyToFeatureSets.has(e.key.id)||this._tileKeyToFeatureSets.set(e.key.id,new Map);const n=this._tileKeyToFeatureSets.get(e.key.id);if((0,o.pC)(t.addOrUpdate)&&t.addOrUpdate.hasFeatures&&n.set(t.addOrUpdate.instance,t),t.end){const t=[],n=function(e){const t=e.key,r=new Map,n=256,o=s.I_,i=e.tileInfoView.tileInfo.isWrappable;return r.set((0,c.M)(t,-1,-1,i).id,new u([-o,-o],[o-n,o-n,o,o])),r.set((0,c.M)(t,0,-1,i).id,new u([0,-o],[0,o-n,o,o])),r.set((0,c.M)(t,1,-1,i).id,new u([o,-o],[0,o-n,n,o])),r.set((0,c.M)(t,-1,0,i).id,new u([-o,0],[o-n,0,o,o])),r.set((0,c.M)(t,1,0,i).id,new u([o,0],[0,0,n,o]
1)),r.set((0,c.M)(t,-1,1,i).id,new u([-o,o],[o-n,0,o,n])),r.set((0,c.M)(t,0,1,i).id,new u([0,o],[0,0,o,n])),r.set((0,c.M)(t,1,1,i).id,new u([o,o],[0,0,n,n])),r}(e);this._tileKeyToFeatureSets.forEach(((r,i)=>{if(i===e.key.id)r.forEach((e=>(0,o.Po)(e.addOrUpdate,(e=>t.push(e)))));else if(n.has(i)){const e=n.get(i),[a,s]=e.offset;r.forEach((e=>(0,o.Po)(e.addOrUpdate,(e=>{const r=e.transform(a,s,1,1);t.push(r)}))))}}));const i=(0,l.QM)(t,this._schema.mesh,512,512),a={tileKey:e.key.id,intensityInfo:i},d=[i.matrix];return this.remoteClient.invoke("tileRenderer.onTileData",a,{...r,transferList:d})}}onTileError(e,t,r){return this.remoteClient.invoke("tileRenderer.onTileError",{tileKey:e.id,error:t},r)}};h=(0,n._)([(0,i.j)("esri.views.2d.layers.features.processors.HeatmapProcessor")],h);var f=h;t.default=f}}]);
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.