mars3d-heatmap 3.6.2 → 3.6.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * Mars3D平台插件,结合heatmap可视化功能插件 mars3d-heatmap
3
3
  *
4
- * 版本信息:v3.6.2
5
- * 编译日期:2023-08-21 21:14:23
4
+ * 版本信息:v3.6.4
5
+ * 编译日期:2023-09-05 22:32:16
6
6
  * 版权所有:Copyright by 火星科技 http://mars3d.cn
7
7
  * 使用单位:免费公开版 ,2023-03-17
8
8
  */
@@ -11,5 +11,5 @@
11
11
  typeof define === 'function' && define.amd ? define(['exports', 'mars3d', '@mars3d/heatmap.js'], factory) :
12
12
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["mars3d-heatmap"] = {}, global.mars3d, global.h337));
13
13
  })(this, (function (exports, mars3d, h337) {
14
- 'use strict';const _0x5776f6=_0x1173;function _0x1173(_0x2f9668,_0x2f057c){const _0x2743ca=_0x2743();return _0x1173=function(_0x11736f,_0x4606cd){_0x11736f=_0x11736f-0xd6;let _0xce577d=_0x2743ca[_0x11736f];return _0xce577d;},_0x1173(_0x2f9668,_0x2f057c);}(function(_0x14a291,_0x53783f){const _0x466bc6={_0x1c3851:0xe7,_0x1a191b:0x11c,_0x2444ac:0x117,_0x485ff5:0xfd},_0x3d08de=_0x1173,_0x55540b=_0x14a291();while(!![]){try{const _0x3d5ced=-parseInt(_0x3d08de(0x123))/0x1+parseInt(_0x3d08de(0x11b))/0x2+-parseInt(_0x3d08de(_0x466bc6._0x1c3851))/0x3+-parseInt(_0x3d08de(_0x466bc6._0x1a191b))/0x4+-parseInt(_0x3d08de(0x128))/0x5+-parseInt(_0x3d08de(0x101))/0x6*(parseInt(_0x3d08de(_0x466bc6._0x2444ac))/0x7)+parseInt(_0x3d08de(_0x466bc6._0x485ff5))/0x8;if(_0x3d5ced===_0x53783f)break;else _0x55540b['push'](_0x55540b['shift']());}catch(_0x8f0ee5){_0x55540b['push'](_0x55540b['shift']());}}}(_0x2743,0x8a554));function _interopNamespace(_0x651f18){const _0x1230e5={_0x303077:0x110},_0x26e4e1=_0x1173;if(_0x651f18&&_0x651f18['__esModule'])return _0x651f18;var _0x5abbf0=Object['create'](null);return _0x651f18&&Object['keys'](_0x651f18)['forEach'](function(_0x3f4607){const _0x467600=_0x1173;if(_0x3f4607!==_0x467600(0x115)){var _0x57fa46=Object[_0x467600(0x11d)](_0x651f18,_0x3f4607);Object['defineProperty'](_0x5abbf0,_0x3f4607,_0x57fa46[_0x467600(_0x1230e5._0x303077)]?_0x57fa46:{'enumerable':!![],'get':function(){return _0x651f18[_0x3f4607];}});}}),_0x5abbf0[_0x26e4e1(0x115)]=_0x651f18,_0x5abbf0;}var mars3d__namespace=_interopNamespace(mars3d),h337__namespace=_interopNamespace(h337),HeatMaterial='uniform\x20sampler2D\x20image;\x0a\x0aczm_material\x20czm_getMaterial(czm_materialInput\x20materialInput)\x20{\x0a\x20\x20czm_material\x20material\x20=\x20czm_getDefaultMaterial(materialInput);\x0a\x20\x20vec2\x20st\x20=\x20materialInput.st;\x0a\x20\x20vec4\x20colorImage\x20=\x20texture(image,\x20st);\x0a\x20\x20if(colorImage.rgb\x20==\x20vec3(1.0)\x20||\x20colorImage.rgb\x20==\x20vec3(0.0))\x20{\x0a\x20\x20\x20\x20discard;\x0a\x20\x20}\x0a\x20\x20material.diffuse\x20=\x20colorImage.rgb;\x0a\x20\x20material.alpha\x20=\x20colorImage.a;\x0a\x20\x20return\x20material;\x0a}\x0a';if(!h337__namespace[_0x5776f6(0xf2)])throw new Error('请引入\x20heatmap.js\x20库\x20');const Cesium=mars3d__namespace['Cesium'],BaseLayer=mars3d__namespace[_0x5776f6(0x121)][_0x5776f6(0x129)],DEF_HEATSTYLE={'maxOpacity':0.8,'minOpacity':0.1,'blur':0.85,'radius':0x19,'gradient':{0.4:'blue',0.6:'green',0.8:'yellow',0.9:'red'}},DEF_STYLE={'arcRadiusScale':1.5,'arcBlurScale':1.5,'vertexFormat':Cesium[_0x5776f6(0xe2)]['VERTEX_FORMAT']};class HeatLayer extends BaseLayer{constructor(_0x42e96d={}){const _0x130b01={_0x2bf88c:0x126,_0x1d5134:0xdf,_0x15a2d9:0x126,_0x38926e:0xef,_0x219bf0:0xf9,_0x73ab70:0x126},_0x2f7da9=_0x5776f6;super(_0x42e96d),this['options']['maxCanvasSize']=this[_0x2f7da9(_0x130b01._0x2bf88c)][_0x2f7da9(0xef)]??document['body'][_0x2f7da9(_0x130b01._0x1d5134)],this['options']['maxCanvasSize']=Math['min'](this[_0x2f7da9(_0x130b01._0x15a2d9)][_0x2f7da9(_0x130b01._0x38926e)],0x1388),this[_0x2f7da9(0x126)]['minCanvasSize']=this[_0x2f7da9(_0x130b01._0x15a2d9)][_0x2f7da9(0xe0)]??document['body']['clientHeight'],this['options']['minCanvasSize']=Math['max'](this[_0x2f7da9(_0x130b01._0x15a2d9)]['minCanvasSize'],0x2bc),this[_0x2f7da9(0x126)][_0x2f7da9(_0x130b01._0x219bf0)]={...DEF_HEATSTYLE,...this[_0x2f7da9(_0x130b01._0x73ab70)]['heatStyle']},this[_0x2f7da9(0x126)]['style']={...DEF_STYLE,...this[_0x2f7da9(0x126)]['style']};}get['layer'](){const _0x23af75={_0x2656bf:0xf8},_0x29d012=_0x5776f6;return this[_0x29d012(_0x23af75._0x2656bf)];}get[_0x5776f6(0xf9)](){return this['options']['heatStyle'];}set['heatStyle'](_0x4b44b9){const _0x3c9f51={_0x31990c:0x127,_0x3baadf:0xf9},_0x55a983=_0x5776f6;this['options']['heatStyle']=mars3d__namespace[_0x55a983(_0x3c9f51._0x31990c)]['merge'](this['options'][_0x55a983(_0x3c9f51._0x3baadf)],_0x4b44b9),this['_heat']&&(this['_heat']['configure'](this['options']['heatStyle']),this['_updatePositionsHook'](!![]));}get['style'](){return this['options']['style'];}set['style'](_0x554281){const _0x9068ec={_0x141428:0x126,_0x3367d4:0x126},_0x58ecc5=_0x5776f6;this[_0x58ecc5(_0x9068ec._0x141428)][_0x58ecc5(0xd6)]=mars3d__namespace['Util']['merge'](this[_0x58ecc5(_0x9068ec._0x3367d4)]['style'],_0x554281);}get[_0x5776f6(0x11a)](){return this['_positions'];}set['positions'](_0xe27769){this['setPositions'](_0xe27769);}get[_0x5776f6(0xff)](){const _0x49c3f3={_0x5e5939:0xd9},_0x4a05d1=[];return this['points']['forEach'](_0x27786f=>{const _0x29d334=_0x1173;_0x4a05d1[_0x29d334(_0x49c3f3._0x5e5939)](_0x27786f['toArray']());}),_0x4a05d1;}get[_0x5776f6(0x113)](){const _0x11693b={_0x1e9896:0xee},_0x155ea2=_0x5776f6;return this[_0x155ea2(_0x11693b._0x1e9896)];}['_setOptionsHook'](_0x3ea709,_0xeedec9){_0x3ea709['positions']&&(this['positions']=_0x3ea709['positions']);}['_mountedHook'](){const _0x283b7b={_0x4621e8:0xf8},_0x15c229=_0x5776f6;this['style']['type']==='image'?this[_0x15c229(_0x283b7b._0x4621e8)]=new mars3d__namespace[(_0x15c229(0x121))]['ImageLayer']({'crs':'EPSG:3857','private':!![]}):this['_layer']=new mars3d__namespace['layer'][(_0x15c229(0xe9))]({'private':!![]});}['_addedHook'](){const _0x572d94={_0x487ce3:0xed},_0x2bace9=_0x5776f6;this['_map']['addLayer'](this['_layer']),this['_container']=mars3d__namespace['DomUtil']['create']('div',_0x2bace9(0x109),this['_map']['container']),this['options']['positions']&&(this['positions']=this['options']['positions']),this['options']['flyTo']&&this[_0x2bace9(_0x572d94._0x487ce3)]();}['_removedHook'](){const _0x5b15e6={_0x5dd20b:0xf7,_0x5d1940:0x104,_0x3bfda7:0xf8},_0x46ec78=_0x5776f6;this[_0x46ec78(_0x5b15e6._0x5dd20b)]&&(mars3d__namespace['DomUtil'][_0x46ec78(_0x5b15e6._0x5d1940)](this['_container']),delete this['_container']),this[_0x46ec78(0xd7)](),this['_map']['removeLayer'](this[_0x46ec78(_0x5b15e6._0x3bfda7)]);}['addPosition'](_0x420f6f,_0x2d1ae1){const _0x564349={_0x4eca97:0xd9},_0x3178ca=_0x5776f6;this['_positions']=this['_positions']||[],this[_0x3178ca(0xe3)][_0x3178ca(_0x564349._0x4eca97)](_0x420f6f),this[_0x3178ca(0x103)](_0x2d1ae1);}['setPositions'](_0x3680cb,_0x39d345){const _0x429253=_0x5776f6;this[_0x429253(0xe3)]=_0x3680cb,this['_updatePositionsHook'](_0x39d345);}[_0x5776f6(0xd7)](){const _0x533f3c=_0x5776f6;this[_0x533f3c(0x105)]&&(this['_layer']['removeGraphic'](this['_graphic'],!![]),delete this['_graphic']),this['_graphic2']&&(this['_layer']['removeGraphic'](this['_graphic2'],!![]),delete this[_0x533f3c(0xe4)]);}['_updatePositionsHook'](_0x378ac5){const _0xaf74c4={_0x532548:0xee,_0x4f5b0a:0x105,_0x1d9747:0xde,_0x1b6672:0xe4,_0x3d3328:0xeb,_0x577b76:0x105,_0x474027:0x114},_0x3cffb7=_0x5776f6;if(!this['show']||!this['_map']||!this['positions']||this['positions']['length']===0x0)return this;const _0x506053=this[_0x3cffb7(0xf6)]();if(this['style']['type']===_0x3cffb7(0xde))this['_layer']['setOptions']({'url':_0x506053['toDataURL']('image/png'),'rectangle':this[_0x3cffb7(_0xaf74c4._0x532548)],'opacity':this[_0x3cffb7(0xd6)]['opacity']});else this['style']['arc']?this[_0x3cffb7(0x105)]&&_0x378ac5?(this[_0x3cffb7(_0xaf74c4._0x4f5b0a)]['uniforms'][_0x3cffb7(_0xaf74c4._0x1d9747)]=_0x506053,this['_graphic']['uniforms']['bumpMap']=this['_getArcHeatCanvas'](),this['_graphic2']&&(this['_graphic2'][_0x3cffb7(0xeb)][_0x3cffb7(0xde)]=_0x506053,this[_0x3cffb7(_0xaf74c4._0x1b6672)][_0x3cffb7(_0xaf74c4._0x3d3328)]['bumpMap']=this[_0x3cffb7(_0xaf74c4._0x577b76)]['uniforms'][_0x3cffb7(0x100)])):this['_createArcGraphic'](_0x506053):this['_graphic']&&_0x378ac5?this['_graphic']['uniforms']['image']=_0x506053:this[_0x3cffb7(_0xaf74c4._0x474027)](_0x506053);return this;}['_createGraphic'](_0x50c1af){const _0x139d69=_0x5776f6;this[_0x139d69(0xd7)](),this['_graphic']=new mars3d__namespace[(_0x139d69(0x124))]['RectanglePrimitive']({...this['options'],'rectangle':this['_rectangle'],'appearance':new Cesium['EllipsoidSurfaceAppearance']({'material':new Cesium['Material']({'fabric':{'uniforms':{'image':_0x50c1af},'source':HeatMaterial},'translucent':!![]}),'flat':!![]})}),this['_layer']['addGraphic'](this['_graphic']);}['_createArcGraphic'](_0x477030){const _0x421cd4={_0x55b018:0x118,_0x39e926:0x120,_0x248171:0xd6,_0x3da223:0xf1,_0x4cc35c:0xee,_0x8fd1e5:0x124},_0x469662=_0x5776f6;this['clear']();const _0x4a7ed1=Cesium['RenderState']['fromCache']({'cull':{'enabled':!![]},'depthTest':{'enabled':!![]},'stencilTest':{'enabled':!![],'frontFunction':Cesium['StencilFunction'][_0x469662(0xfc)],'frontOperation':{'fail':Cesium['StencilOperation']['KEEP'],'zFail':Cesium['StencilOperation']['KEEP'],'zPass':Cesium['StencilOperation']['REPLACE']},'backFunction':Cesium['StencilFunction']['ALWAYS'],'backOperation':{'fail':Cesium['StencilOperation']['KEEP'],'zFail':Cesium[_0x469662(0x118)]['KEEP'],'zPass':Cesium[_0x469662(_0x421cd4._0x55b018)]['REPLACE']},'reference':0x2,'mask':0x2},'blending':Cesium['BlendingState'][_0x469662(_0x421cd4._0x39e926)]}),_0xc3993=Math['floor'](this[_0x469662(0xd6)]['diffHeight']??this['_mBoundsMax']*0.02)+0.1;this[_0x469662(_0x421cd4._0x248171)]['diffHeight']&&delete this[_0x469662(0xd6)][_0x469662(_0x421cd4._0x3da223)];const _0x41d7ed=(this['style'][_0x469662(0x11f)],0x64);let _0x56f619=Math['max'](this['_rectangle']['height'],this[_0x469662(_0x421cd4._0x4cc35c)][_0x469662(0xd8)]);this['style']['granularity']=_0x56f619/=_0x41d7ed;const _0x3c94d0=new Cesium['Material']({'fabric':{'uniforms':{'image':_0x477030,'repeat':new Cesium['Cartesian2'](0x1,0x1),'color':new Cesium['Color'](0x1,0x1,0x1,0x0),'bumpMap':this['_getArcHeatCanvas']()},'source':HeatMaterial},'translucent':!![]}),_0x332393=this['style']['arcDirection']||0x1;this['_graphic']=new mars3d__namespace['graphic']['RectanglePrimitive']({...this['options'],'rectangle':this['_rectangle'],'appearance':new Cesium[(_0x469662(0xe2))]({'flat':!![],'aboveGround':!![],'renderState':_0x4a7ed1,'material':_0x3c94d0,'vertexShaderSource':getVertexShaderSource(_0xc3993*_0x332393)})}),this['_layer']['addGraphic'](this['_graphic']),this['style'][_0x469662(0xe5)]===0x0&&(this['_graphic2']=new mars3d__namespace[(_0x469662(_0x421cd4._0x8fd1e5))]['RectanglePrimitive']({...this['options'],'rectangle':this['_rectangle'],'appearance':new Cesium['EllipsoidSurfaceAppearance']({'flat':!![],'aboveGround':!![],'renderState':_0x4a7ed1,'material':_0x3c94d0,'vertexShaderSource':getVertexShaderSource(-_0xc3993)})}),this['_layer']['addGraphic'](this['_graphic2']));}['getRectangle'](_0x5d2922){const _0x1131eb={_0x55a8ab:0xee},_0x58dd5f=_0x5776f6;return _0x5d2922!==null&&_0x5d2922!==void 0x0&&_0x5d2922[_0x58dd5f(0xec)]&&this['_rectangle']?mars3d__namespace[_0x58dd5f(0x116)]['formatRectangle'](this['_rectangle']):this[_0x58dd5f(_0x1131eb._0x55a8ab)];}['_getHeatCanvas'](){const _0x337407={_0x56557d:0x126,_0x574438:0xf5,_0x394563:0x107,_0x45409b:0xfe,_0x42198f:0x108,_0x252442:0xf5,_0x12bd7b:0x10e,_0x4d408e:0x10b,_0x542236:0xfe,_0x4abba6:0xd6,_0x2b9551:0x10c,_0x38197d:0x122},_0xe3841d={_0x354f32:0x111},_0x2621bd={_0x2a6502:0x111,_0x3f8e00:0x119},_0x3520af=_0x5776f6,_0x46c609=this['_positions'],_0x34c94a=[];let _0x11d6da,_0x4f2486,_0x22a67a,_0x4637c4;_0x46c609['forEach'](_0x1162e1=>{const _0x223b7d=_0x1173,_0x31dfc8=mars3d__namespace['LngLatPoint'][_0x223b7d(0xfa)](_0x1162e1);if(!_0x31dfc8)return;_0x31dfc8[_0x223b7d(_0x2621bd._0x2a6502)]=_0x1162e1['value']||0x1,!this['options']['rectangle']&&(_0x11d6da===undefined?(_0x11d6da=_0x31dfc8['lng'],_0x4f2486=_0x31dfc8[_0x223b7d(0x119)],_0x22a67a=_0x31dfc8[_0x223b7d(0x106)],_0x4637c4=_0x31dfc8['lat']):(_0x11d6da=Math['min'](_0x11d6da,_0x31dfc8['lng']),_0x4f2486=Math[_0x223b7d(0xdd)](_0x4f2486,_0x31dfc8[_0x223b7d(_0x2621bd._0x3f8e00)]),_0x22a67a=Math['min'](_0x22a67a,_0x31dfc8['lat']),_0x4637c4=Math[_0x223b7d(0xdd)](_0x4637c4,_0x31dfc8[_0x223b7d(0x106)]))),_0x34c94a['push'](_0x31dfc8);});_0x11d6da===_0x4f2486&&(_0x11d6da-=0.000001,_0x4f2486+=0.000001);_0x22a67a===_0x4637c4&&(_0x22a67a-=0.000001,_0x4637c4+=0.000001);let _0x3b4b65=this[_0x3520af(_0x337407._0x56557d)]['rectangle']||{'xmin':_0x11d6da,'xmax':_0x4f2486,'ymin':_0x22a67a,'ymax':_0x4637c4};const _0x3ad1af=getMercatorBounds(_0x3b4b65),_0x4ed4a6=Math['abs'](_0x3ad1af['xmax']-_0x3ad1af['xmin']),_0x6d6a4e=Math['abs'](_0x3ad1af[_0x3520af(_0x337407._0x574438)]-_0x3ad1af['ymin']),_0x3ae750=Math['max'](_0x4ed4a6,_0x6d6a4e),_0x1fe8db=Math[_0x3520af(0x112)](_0x4ed4a6,_0x6d6a4e);this[_0x3520af(_0x337407._0x394563)]=_0x3ae750;let _0x3e93ab=0x1;if(_0x3ae750>this['options'][_0x3520af(0xef)])_0x3e93ab=_0x3ae750/this['options']['maxCanvasSize'],_0x1fe8db/_0x3e93ab<this['options'][_0x3520af(0xe0)]&&(_0x3e93ab=_0x1fe8db/this['options']['minCanvasSize']);else _0x1fe8db<this[_0x3520af(_0x337407._0x56557d)][_0x3520af(0xe0)]&&(_0x3e93ab=_0x1fe8db/this[_0x3520af(_0x337407._0x56557d)]['minCanvasSize'],_0x3ae750/_0x3e93ab>this['options']['maxCanvasSize']&&(_0x3e93ab=_0x3ae750/this[_0x3520af(0x126)]['maxCanvasSize']));const _0x1c3ce7=this['heatStyle']['radius']*1.5,_0x80885e=_0x4ed4a6/_0x3e93ab+_0x1c3ce7*0x2,_0x235ca1=_0x6d6a4e/_0x3e93ab+_0x1c3ce7*0x2,_0x2b3aac=_0x1c3ce7*_0x3e93ab;_0x3ad1af['xmin']-=_0x2b3aac,_0x3ad1af[_0x3520af(_0x337407._0x45409b)]-=_0x2b3aac,_0x3ad1af[_0x3520af(0xda)]+=_0x2b3aac,_0x3ad1af[_0x3520af(0xf5)]+=_0x2b3aac,this[_0x3520af(_0x337407._0x42198f)]=_0x3e93ab,_0x3b4b65=geLatLngBounds(_0x3ad1af),this[_0x3520af(0xee)]=Cesium['Rectangle']['fromDegrees'](_0x3b4b65['xmin'],_0x3b4b65['ymin'],_0x3b4b65['xmax'],_0x3b4b65[_0x3520af(_0x337407._0x252442)]);let _0x13484e=_0x34c94a[0x0]['value']??0x1,_0x366630=_0x34c94a[0x0]['value']??0x0;const _0x3a4788=[];_0x34c94a[_0x3520af(0xf3)](_0x51bcec=>{const _0x185ec2=_0x3520af,_0x3198f7=mars3d__namespace['PointTrans']['lonlat2mercator']([_0x51bcec['lng'],_0x51bcec['lat']]),_0xfc9040=_0x51bcec[_0x185ec2(_0xe3841d._0x354f32)]||0x1,_0x94937e=Math['round']((_0x3198f7[0x0]-_0x3ad1af['xmin'])/_0x3e93ab),_0x131970=Math['round']((_0x3ad1af['ymax']-_0x3198f7[0x1])/_0x3e93ab);_0x13484e=Math['max'](_0x13484e,_0xfc9040),_0x366630=Math['min'](_0x366630,_0xfc9040),_0x3a4788['push']({'x':_0x94937e,'y':_0x131970,'value':_0xfc9040});});const _0x5d090f={'min':this['options']['min']??_0x366630,'max':this['options']['max']??_0x13484e,'data':_0x3a4788};this['_last_heatData']=_0x5d090f;if(!this['_last_mBounds']||_0x3ad1af[_0x3520af(_0x337407._0x12bd7b)]!==this['_last_mBounds']['xmin']||_0x3ad1af['ymin']!==this[_0x3520af(_0x337407._0x4d408e)][_0x3520af(_0x337407._0x542236)]||_0x3ad1af[_0x3520af(0xda)]!==this['_last_mBounds']['xmax']||_0x3ad1af['ymax']!==this['_last_mBounds']['ymax']){this['_last_mBounds']=_0x3ad1af,this['_container'][_0x3520af(_0x337407._0x4abba6)][_0x3520af(_0x337407._0x2b9551)]='width:'+_0x80885e+'px;height:'+_0x235ca1+'px;';const _0x2c3a9c={...this['heatStyle'],'container':this['_container']};!this['_heat']?this['_heat']=h337__namespace['create'](_0x2c3a9c):this['_heat']['configure'](_0x2c3a9c);}this['_heat']['setData'](_0x5d090f);const _0x455930=mars3d__namespace['DomUtil'][_0x3520af(_0x337407._0x38197d)](this['_heat']['_renderer']['canvas']);return _0x455930;}['_getArcHeatCanvas'](){const _0xc5d09f={_0x59337d:0xdc,_0x5254f4:0x12a,_0x22edbe:0xfb},_0x497f52=_0x5776f6;this['_heat']['configure']({'radius':this[_0x497f52(0xf9)]['radius']*this['style']['arcRadiusScale'],'blur':this['heatStyle'][_0x497f52(_0xc5d09f._0x59337d)]*this['style'][_0x497f52(0xea)],'gradient':this[_0x497f52(0xf9)][_0x497f52(0x125)]||{0.25:'rgb(0,0,0)',0.55:'rgb(140,140,140)',0.85:'rgb(216,216,216)',0x1:_0x497f52(0xe1)}});const _0x1f256e=mars3d__namespace['DomUtil']['copyCanvas'](this[_0x497f52(_0xc5d09f._0x5254f4)][_0x497f52(_0xc5d09f._0x22edbe)][_0x497f52(0x102)]);return this[_0x497f52(0x12a)]['configure'](this['options']['heatStyle']),_0x1f256e;}['getPointData'](_0x58cd20){const _0x1bbd56={_0x40cf73:0x119,_0x353054:0x108,_0xe19e57:0xfb,_0x5ec9e2:0x10a},_0x35410c=_0x5776f6,_0x104880=mars3d__namespace['LngLatPoint']['parse'](_0x58cd20);if(!_0x104880)return{};const _0x3f968e=mars3d__namespace[_0x35410c(0xe8)]['lonlat2mercator']([_0x104880[_0x35410c(_0x1bbd56._0x40cf73)],_0x104880['lat']]),_0x11dc0d=this['_last_mBounds'],_0x30d667=Math['round']((_0x3f968e[0x0]-_0x11dc0d['xmin'])/this[_0x35410c(0x108)]),_0x286152=Math['round']((_0x11dc0d['ymax']-_0x3f968e[0x1])/this[_0x35410c(_0x1bbd56._0x353054)]),_0x3d0c46=this['_heat']['getValueAt']({'x':_0x30d667,'y':_0x286152}),_0x58f630=this['_heat'][_0x35410c(_0x1bbd56._0xe19e57)]['ctx']['getImageData'](_0x30d667-0x1,_0x286152-0x1,0x1,0x1)[_0x35410c(_0x1bbd56._0x5ec9e2)];return{'x':_0x30d667,'y':_0x286152,'value':_0x3d0c46,'color':_0x35410c(0xdb)+_0x58f630[0x0]+','+_0x58f630[0x1]+','+_0x58f630[0x2]+','+_0x58f630[0x3]+')'};}}mars3d__namespace['LayerUtil'][_0x5776f6(0x10d)](_0x5776f6(0x11e),HeatLayer),mars3d__namespace['layer'][_0x5776f6(0xf0)]=HeatLayer,mars3d__namespace[_0x5776f6(0x10f)]=h337__namespace;function getMercatorBounds(_0x4d3110){const _0x30b338={_0x4b4491:0xfe,_0xfb8e73:0xf5},_0x4d46be=_0x5776f6,_0x3fc792=mars3d__namespace['PointTrans']['lonlat2mercator']([_0x4d3110['xmin'],_0x4d3110[_0x4d46be(_0x30b338._0x4b4491)]]),_0x21b6e2=mars3d__namespace['PointTrans']['lonlat2mercator']([_0x4d3110['xmax'],_0x4d3110[_0x4d46be(_0x30b338._0xfb8e73)]]);return{'xmin':_0x3fc792[0x0],'ymin':_0x3fc792[0x1],'xmax':_0x21b6e2[0x0],'ymax':_0x21b6e2[0x1]};}function geLatLngBounds(_0x338208){const _0x4b93e2={_0xdfa998:0xfe},_0x12b8a9=_0x5776f6,_0x4067af=mars3d__namespace['PointTrans']['mercator2lonlat']([_0x338208['xmin'],_0x338208[_0x12b8a9(_0x4b93e2._0xdfa998)]]),_0x5e6053=mars3d__namespace['PointTrans']['mercator2lonlat']([_0x338208[_0x12b8a9(0xda)],_0x338208['ymax']]);return{'xmin':_0x4067af[0x0],'ymin':_0x4067af[0x1],'xmax':_0x5e6053[0x0],'ymax':_0x5e6053[0x1]};}function getVertexShaderSource(_0x320377){const _0xe45f47=_0x5776f6;return'in\x20vec3\x20position3DHigh;\x0a\x20\x20in\x20vec3\x20position3DLow;\x0a\x20\x20in\x20vec2\x20st;\x0a\x20\x20in\x20float\x20batchId;\x0a\x20\x20uniform\x20sampler2D\x20bumpMap_3;\x0a\x20\x20out\x20vec3\x20v_positionMC;\x0a\x20\x20out\x20vec3\x20v_positionEC;\x0a\x20\x20out\x20vec2\x20v_st;\x0a\x0a\x20\x20void\x20main()\x0a\x20\x20{\x0a\x20\x20\x20\x20vec4\x20p\x20=\x20czm_computePosition();\x0a\x20\x20\x20\x20v_positionMC\x20=\x20position3DHigh\x20+\x20position3DLow;\x0a\x20\x20\x20\x20v_positionEC\x20=\x20(czm_modelViewRelativeToEye\x20*\x20p).xyz;\x0a\x20\x20\x20\x20v_st\x20=\x20st;\x0a\x20\x20\x20\x20vec4\x20color\x20=\x20texture(bumpMap_3,\x20v_st);\x0a\x20\x20\x20\x20float\x20centerBump\x20=\x20distance(vec3(0.0),color.rgb);\x0a\x20\x20\x20\x20vec3\x20upDir\x20=\x20normalize(v_positionMC.xyz);\x0a\x20\x20\x20\x20vec3\x20disPos\x20=\x20upDir\x20*\x20centerBump\x20*\x20'+_0x320377+_0xe45f47(0xe6);}function _0x2743(){const _0x1722db=['min','rectangle','_createGraphic','default','PolyUtil','497LidOSG','StencilOperation','lng','positions','1317356AnemEb','1035252fKhCay','getOwnPropertyDescriptor','heat','splitNum','ALPHA_BLEND','layer','copyCanvas','1058150FoXEWT','graphic','gradientArc','options','Util','980290aeHyej','BaseLayer','_heat','style','clear','width','push','xmax','rgba(','blur','max','image','clientWidth','minCanvasSize','rgb(255,255,255)','EllipsoidSurfaceAppearance','_positions','_graphic2','arcDirection',';\x0a\x20\x20\x20\x20p\x20+=vec4(disPos,0.0);\x0a\x20\x20\x20\x20gl_Position\x20=\x20czm_modelViewProjectionRelativeToEye\x20*\x20p;\x0a\x20\x20}\x0a','238485OTDZkc','PointTrans','GraphicLayer','arcBlurScale','uniforms','isFormat','flyToByAnimationEnd','_rectangle','maxCanvasSize','HeatLayer','diffHeight','create','forEach','__esModule','ymax','_getHeatCanvas','_container','_layer','heatStyle','parse','_renderer','ALWAYS','15852936ZsUQzp','ymin','coordinates','bumpMap','40662lFIilu','canvas','_updatePositionsHook','remove','_graphic','lat','_mBoundsMax','_scale','mars3d-heatmap\x20mars3d-hideDiv','data','_last_mBounds','cssText','register','xmin','h337','get','value'];_0x2743=function(){return _0x1722db;};return _0x2743();}exports['HeatLayer']=HeatLayer,Object['defineProperty'](exports,_0x5776f6(0xf4),{'value':!![]});
14
+ 'use strict';const _0xa90bb2=_0x2d96;(function(_0x44fc1a,_0xe07e56){const _0x4aa78a={_0xdf6464:0x1b1,_0x51d48b:0x1d4,_0x354687:0x1da,_0x5ee9df:0x1a0,_0x509524:0x1f6,_0x3320a6:0x1fa,_0xbce000:0x1a3},_0x35150e=_0x2d96,_0x26e585=_0x44fc1a();while(!![]){try{const _0x1a73c3=parseInt(_0x35150e(0x1d0))/0x1*(-parseInt(_0x35150e(0x1b9))/0x2)+-parseInt(_0x35150e(_0x4aa78a._0xdf6464))/0x3*(parseInt(_0x35150e(_0x4aa78a._0x51d48b))/0x4)+parseInt(_0x35150e(0x1b0))/0x5*(-parseInt(_0x35150e(0x1c9))/0x6)+-parseInt(_0x35150e(0x1b2))/0x7*(parseInt(_0x35150e(_0x4aa78a._0x354687))/0x8)+parseInt(_0x35150e(0x1ec))/0x9+-parseInt(_0x35150e(_0x4aa78a._0x5ee9df))/0xa*(-parseInt(_0x35150e(_0x4aa78a._0x509524))/0xb)+parseInt(_0x35150e(_0x4aa78a._0x3320a6))/0xc*(parseInt(_0x35150e(_0x4aa78a._0xbce000))/0xd);if(_0x1a73c3===_0xe07e56)break;else _0x26e585['push'](_0x26e585['shift']());}catch(_0x52933f){_0x26e585['push'](_0x26e585['shift']());}}}(_0x1c8a,0xead6c));function _interopNamespace(_0x57b2bc){const _0x549260={_0x4103ff:0x1a4,_0x2c56cf:0x1ee},_0x2aff6e=_0x2d96;if(_0x57b2bc&&_0x57b2bc[_0x2aff6e(_0x549260._0x4103ff)])return _0x57b2bc;var _0x3351d0=Object[_0x2aff6e(0x1e4)](null);return _0x57b2bc&&Object[_0x2aff6e(_0x549260._0x2c56cf)](_0x57b2bc)['forEach'](function(_0x4bb79c){const _0x4f8147=_0x2aff6e;if(_0x4bb79c!==_0x4f8147(0x1cc)){var _0x4589bb=Object['getOwnPropertyDescriptor'](_0x57b2bc,_0x4bb79c);Object['defineProperty'](_0x3351d0,_0x4bb79c,_0x4589bb['get']?_0x4589bb:{'enumerable':!![],'get':function(){return _0x57b2bc[_0x4bb79c];}});}}),_0x3351d0['default']=_0x57b2bc,_0x3351d0;}var mars3d__namespace=_interopNamespace(mars3d),h337__namespace=_interopNamespace(h337),HeatMaterial='uniform\x20sampler2D\x20image;\x0a\x0aczm_material\x20czm_getMaterial(czm_materialInput\x20materialInput)\x20{\x0a\x20\x20czm_material\x20material\x20=\x20czm_getDefaultMaterial(materialInput);\x0a\x20\x20vec2\x20st\x20=\x20materialInput.st;\x0a\x20\x20vec4\x20colorImage\x20=\x20texture(image,\x20st);\x0a\x20\x20if(colorImage.rgb\x20==\x20vec3(1.0)\x20||\x20colorImage.rgb\x20==\x20vec3(0.0))\x20{\x0a\x20\x20\x20\x20discard;\x0a\x20\x20}\x0a\x20\x20material.diffuse\x20=\x20colorImage.rgb;\x0a\x20\x20material.alpha\x20=\x20colorImage.a;\x0a\x20\x20return\x20material;\x0a}\x0a';if(!h337__namespace['create'])throw new Error(_0xa90bb2(0x1ba));const Cesium=mars3d__namespace[_0xa90bb2(0x1c8)],BaseLayer=mars3d__namespace['layer'][_0xa90bb2(0x1fb)],DEF_HEATSTYLE={'maxOpacity':0.8,'minOpacity':0.1,'blur':0.85,'radius':0x19,'gradient':{0.4:_0xa90bb2(0x1c4),0.6:'green',0.8:'yellow',0.9:_0xa90bb2(0x1c6)}},DEF_STYLE={'arcRadiusScale':1.5,'arcBlurScale':1.5,'vertexFormat':Cesium['EllipsoidSurfaceAppearance'][_0xa90bb2(0x1e3)]};class HeatLayer extends BaseLayer{constructor(_0x3a7322={}){const _0x103db3={_0x3bc541:0x1b7,_0x2b058e:0x1de,_0xd864d2:0x1f3,_0x47277b:0x1f3,_0x5caf9e:0x1b5},_0x5274f0=_0xa90bb2;super(_0x3a7322),this['options'][_0x5274f0(0x1b7)]=this['options']['maxCanvasSize']??document['body']['clientWidth'],this['options'][_0x5274f0(_0x103db3._0x3bc541)]=Math[_0x5274f0(_0x103db3._0x2b058e)](this['options']['maxCanvasSize'],0x1388),this[_0x5274f0(0x1dc)]['minCanvasSize']=this['options'][_0x5274f0(_0x103db3._0xd864d2)]??document['body']['clientHeight'],this['options'][_0x5274f0(0x1f3)]=Math['max'](this['options'][_0x5274f0(_0x103db3._0x47277b)],0x2bc),this[_0x5274f0(0x1dc)]['heatStyle']={...DEF_HEATSTYLE,...this['options'][_0x5274f0(_0x103db3._0x5caf9e)]},this['options'][_0x5274f0(0x1fd)]={...DEF_STYLE,...this['options']['style']};}get['layer'](){const _0x2e636f=_0xa90bb2;return this[_0x2e636f(0x1f7)];}get[_0xa90bb2(0x1b5)](){const _0x216c66=_0xa90bb2;return this[_0x216c66(0x1dc)]['heatStyle'];}set['heatStyle'](_0x232a6f){const _0xe2fcfd={_0x268a59:0x1f0},_0x1f96c6=_0xa90bb2;this['options'][_0x1f96c6(0x1b5)]=mars3d__namespace[_0x1f96c6(0x1c7)][_0x1f96c6(0x1d7)](this['options'][_0x1f96c6(0x1b5)],_0x232a6f),this['_heat']&&(this[_0x1f96c6(_0xe2fcfd._0x268a59)]['configure'](this['options']['heatStyle']),this['_updatePositionsHook'](!![]));}get[_0xa90bb2(0x1fd)](){const _0x5e7e1d=_0xa90bb2;return this[_0x5e7e1d(0x1dc)]['style'];}set['style'](_0x4d8bb9){const _0x18d3a9={_0x5ee3ad:0x1c7},_0x43519d=_0xa90bb2;this[_0x43519d(0x1dc)]['style']=mars3d__namespace[_0x43519d(_0x18d3a9._0x5ee3ad)]['merge'](this['options'][_0x43519d(0x1fd)],_0x4d8bb9);}get['positions'](){return this['_positions'];}set['positions'](_0x447031){const _0x53f3bb={_0x10e10b:0x1c3},_0x4478a9=_0xa90bb2;this[_0x4478a9(_0x53f3bb._0x10e10b)](_0x447031);}get[_0xa90bb2(0x1ca)](){const _0x3be21b=[];return this['points']['forEach'](_0x2dabed=>{_0x3be21b['push'](_0x2dabed['toArray']());}),_0x3be21b;}get[_0xa90bb2(0x1bb)](){return this['_rectangle'];}['_setOptionsHook'](_0x399fc8,_0x1a572c){const _0x3fd0ea=_0xa90bb2;_0x399fc8[_0x3fd0ea(0x1c1)]&&(this['positions']=_0x399fc8['positions']);}['_mountedHook'](){const _0xdec11c={_0x40bda0:0x1fd,_0x3e324b:0x1f7,_0x2e88f3:0x1f7},_0x5873f4=_0xa90bb2;this[_0x5873f4(_0xdec11c._0x40bda0)]['type']==='image'?this[_0x5873f4(_0xdec11c._0x3e324b)]=new mars3d__namespace[(_0x5873f4(0x1dd))]['ImageLayer']({'crs':'EPSG:3857','private':!![]}):this[_0x5873f4(_0xdec11c._0x2e88f3)]=new mars3d__namespace['layer']['GraphicLayer']({'private':!![]});}[_0xa90bb2(0x1d9)](){const _0x38f413=_0xa90bb2;this[_0x38f413(0x1fc)]['addLayer'](this['_layer']),this['_container']=mars3d__namespace['DomUtil'][_0x38f413(0x1e4)]('div','mars3d-heatmap\x20mars3d-hideDiv',this['_map']['container']),this['options'][_0x38f413(0x1c1)]&&(this[_0x38f413(0x1c1)]=this['options']['positions']),this['options']['flyTo']&&this['flyToByAnimationEnd']();}['_removedHook'](){const _0x4dcaf4=_0xa90bb2;this['_container']&&(mars3d__namespace[_0x4dcaf4(0x1d6)]['remove'](this[_0x4dcaf4(0x1a1)]),delete this[_0x4dcaf4(0x1a1)]),this['clear'](),this[_0x4dcaf4(0x1fc)][_0x4dcaf4(0x1f2)](this['_layer']);}[_0xa90bb2(0x1c2)](_0x291ede,_0x8c39a2){const _0x4afa0b={_0xf64f6c:0x1d5},_0x3bb521=_0xa90bb2;this['_positions']=this['_positions']||[],this['_positions']['push'](_0x291ede),this[_0x3bb521(_0x4afa0b._0xf64f6c)](_0x8c39a2);}[_0xa90bb2(0x1c3)](_0x505c9f,_0x40dc9b){this['_positions']=_0x505c9f,this['_updatePositionsHook'](_0x40dc9b);}['clear'](){const _0x21f6d1=_0xa90bb2;this[_0x21f6d1(0x1af)]&&(this['_layer']['removeGraphic'](this['_graphic'],!![]),delete this['_graphic']),this['_graphic2']&&(this['_layer']['removeGraphic'](this['_graphic2'],!![]),delete this['_graphic2']);}['_updatePositionsHook'](_0x30c16e){const _0x450d25={_0x526016:0x1f9,_0x462623:0x1e6,_0x311135:0x1ff,_0x2b27af:0x1fd,_0x47bcc8:0x1bc,_0x314276:0x1e9},_0x1b705d=_0xa90bb2;if(!this[_0x1b705d(_0x450d25._0x526016)]||!this['_map']||!this['positions']||this['positions'][_0x1b705d(_0x450d25._0x462623)]===0x0)return this;const _0x5f0fc7=this['_getHeatCanvas']();if(this['style']['type']==='image')this['_layer']['setOptions']({'url':_0x5f0fc7['toDataURL']('image/png'),'rectangle':this[_0x1b705d(_0x450d25._0x311135)],'opacity':this['style']['opacity']});else this[_0x1b705d(_0x450d25._0x2b27af)]['arc']?this[_0x1b705d(0x1af)]&&_0x30c16e?(this[_0x1b705d(0x1af)][_0x1b705d(_0x450d25._0x47bcc8)]['image']=_0x5f0fc7,this[_0x1b705d(0x1af)]['uniforms']['bumpMap']=this[_0x1b705d(_0x450d25._0x314276)](),this['_graphic2']&&(this['_graphic2']['uniforms'][_0x1b705d(0x1b3)]=_0x5f0fc7,this['_graphic2'][_0x1b705d(_0x450d25._0x47bcc8)][_0x1b705d(0x1ef)]=this['_graphic']['uniforms']['bumpMap'])):this['_createArcGraphic'](_0x5f0fc7):this['_graphic']&&_0x30c16e?this['_graphic']['uniforms']['image']=_0x5f0fc7:this['_createGraphic'](_0x5f0fc7);return this;}['_createGraphic'](_0x1c84de){const _0x5d7e5d=_0xa90bb2;this[_0x5d7e5d(0x200)](),this['_graphic']=new mars3d__namespace['graphic'][(_0x5d7e5d(0x1e0))]({...this['options'],'rectangle':this['_rectangle'],'appearance':new Cesium[(_0x5d7e5d(0x1b8))]({'material':new Cesium['Material']({'fabric':{'uniforms':{'image':_0x1c84de},'source':HeatMaterial},'translucent':!![]}),'flat':!![]})}),this['_layer'][_0x5d7e5d(0x1db)](this['_graphic']);}['_createArcGraphic'](_0x4dce77){const _0x419039={_0x40143e:0x200,_0x513317:0x1f5,_0x2fc7be:0x1ae,_0x580b0f:0x1ae,_0x5a3582:0x1c5,_0x2db77e:0x1fd,_0x4df7c5:0x1e5,_0x6bd24b:0x1ac,_0x253874:0x1cd,_0x266f7f:0x1df,_0x5ad25b:0x1fd,_0x160acd:0x1e0,_0x2ec3a7:0x1b8,_0xe5ff81:0x1f7},_0xee915c=_0xa90bb2;this[_0xee915c(_0x419039._0x40143e)]();const _0x51ceea=Cesium['RenderState'][_0xee915c(_0x419039._0x513317)]({'cull':{'enabled':!![]},'depthTest':{'enabled':!![]},'stencilTest':{'enabled':!![],'frontFunction':Cesium['StencilFunction'][_0xee915c(0x1ab)],'frontOperation':{'fail':Cesium['StencilOperation']['KEEP'],'zFail':Cesium['StencilOperation']['KEEP'],'zPass':Cesium['StencilOperation']['REPLACE']},'backFunction':Cesium['StencilFunction']['ALWAYS'],'backOperation':{'fail':Cesium[_0xee915c(_0x419039._0x2fc7be)]['KEEP'],'zFail':Cesium[_0xee915c(_0x419039._0x580b0f)][_0xee915c(_0x419039._0x5a3582)],'zPass':Cesium['StencilOperation']['REPLACE']},'reference':0x2,'mask':0x2},'blending':Cesium['BlendingState']['ALPHA_BLEND']}),_0x386cd6=Math['floor'](this[_0xee915c(_0x419039._0x2db77e)][_0xee915c(0x1e5)]??this[_0xee915c(0x1bf)]*0.02)+0.1;this[_0xee915c(0x1fd)]['diffHeight']&&delete this['style'][_0xee915c(_0x419039._0x4df7c5)];const _0x264fc8=(this['style']['splitNum'],0x64);let _0x1669bb=Math[_0xee915c(_0x419039._0x6bd24b)](this['_rectangle']['height'],this['_rectangle'][_0xee915c(_0x419039._0x253874)]);this['style']['granularity']=_0x1669bb/=_0x264fc8;const _0xe6f5c6=new Cesium['Material']({'fabric':{'uniforms':{'image':_0x4dce77,'repeat':new Cesium[(_0xee915c(_0x419039._0x266f7f))](0x1,0x1),'color':new Cesium['Color'](0x1,0x1,0x1,0x0),'bumpMap':this['_getArcHeatCanvas']()},'source':HeatMaterial},'translucent':!![]}),_0x525e0c=this[_0xee915c(_0x419039._0x5ad25b)]['arcDirection']||0x1;this['_graphic']=new mars3d__namespace[(_0xee915c(0x1f4))][(_0xee915c(_0x419039._0x160acd))]({...this['options'],'rectangle':this[_0xee915c(0x1ff)],'appearance':new Cesium[(_0xee915c(_0x419039._0x2ec3a7))]({'flat':!![],'aboveGround':!![],'renderState':_0x51ceea,'material':_0xe6f5c6,'vertexShaderSource':getVertexShaderSource(_0x386cd6*_0x525e0c)})}),this[_0xee915c(_0x419039._0xe5ff81)]['addGraphic'](this['_graphic']),this['style']['arcDirection']===0x0&&(this['_graphic2']=new mars3d__namespace[(_0xee915c(0x1f4))]['RectanglePrimitive']({...this['options'],'rectangle':this['_rectangle'],'appearance':new Cesium['EllipsoidSurfaceAppearance']({'flat':!![],'aboveGround':!![],'renderState':_0x51ceea,'material':_0xe6f5c6,'vertexShaderSource':getVertexShaderSource(-_0x386cd6)})}),this['_layer']['addGraphic'](this['_graphic2']));}[_0xa90bb2(0x1f1)](_0x152300){const _0x322943={_0x5e3459:0x1b4,_0x3c232f:0x1a7},_0x291511=_0xa90bb2;return _0x152300!==null&&_0x152300!==void 0x0&&_0x152300[_0x291511(_0x322943._0x5e3459)]&&this['_rectangle']?mars3d__namespace[_0x291511(_0x322943._0x3c232f)]['formatRectangle'](this['_rectangle']):this['_rectangle'];}[_0xa90bb2(0x1bd)](){const _0x5de90c={_0x3b5ab2:0x1b7,_0x45993c:0x1f3,_0x13fbca:0x1f3,_0x3c7059:0x1b7,_0x3cf73e:0x1f8,_0x20ee6f:0x1a9,_0x2402ea:0x1de,_0x29153a:0x1ed,_0x84d2d4:0x1b5,_0x3d34ed:0x1a1,_0x373d99:0x1f0,_0x25a6e3:0x1f0},_0x1dea6a={_0x30d5a4:0x1e8},_0x52587c={_0x4fc149:0x1be,_0x4d88b3:0x1fe,_0x6c9b4d:0x1e1},_0x13d83b=_0xa90bb2,_0x32729c=this['_positions'],_0x4d9347=[];let _0x34bd45,_0x57f1a4,_0x266048,_0x447c9e;_0x32729c['forEach'](_0x144cf1=>{const _0x2a70ce=_0x2d96,_0x101fcb=mars3d__namespace['LngLatPoint'][_0x2a70ce(_0x52587c._0x4fc149)](_0x144cf1);if(!_0x101fcb)return;_0x101fcb[_0x2a70ce(_0x52587c._0x4d88b3)]=_0x144cf1['value']||0x1,!this['options']['rectangle']&&(_0x34bd45===undefined?(_0x34bd45=_0x101fcb['lng'],_0x57f1a4=_0x101fcb['lng'],_0x266048=_0x101fcb['lat'],_0x447c9e=_0x101fcb['lat']):(_0x34bd45=Math['min'](_0x34bd45,_0x101fcb[_0x2a70ce(_0x52587c._0x6c9b4d)]),_0x57f1a4=Math[_0x2a70ce(0x1ac)](_0x57f1a4,_0x101fcb['lng']),_0x266048=Math['min'](_0x266048,_0x101fcb['lat']),_0x447c9e=Math['max'](_0x447c9e,_0x101fcb['lat']))),_0x4d9347[_0x2a70ce(0x1b6)](_0x101fcb);});_0x34bd45===_0x57f1a4&&(_0x34bd45-=0.000001,_0x57f1a4+=0.000001);_0x266048===_0x447c9e&&(_0x266048-=0.000001,_0x447c9e+=0.000001);let _0x548e06=this['options'][_0x13d83b(0x1bb)]||{'xmin':_0x34bd45,'xmax':_0x57f1a4,'ymin':_0x266048,'ymax':_0x447c9e};const _0xbc5598=getMercatorBounds(_0x548e06),_0x315525=Math['abs'](_0xbc5598['xmax']-_0xbc5598['xmin']),_0x42af3d=Math['abs'](_0xbc5598['ymax']-_0xbc5598['ymin']),_0x51c6d5=Math['max'](_0x315525,_0x42af3d),_0x502cf8=Math['min'](_0x315525,_0x42af3d);this['_mBoundsMax']=_0x51c6d5;let _0x18af14=0x1;if(_0x51c6d5>this['options'][_0x13d83b(_0x5de90c._0x3b5ab2)])_0x18af14=_0x51c6d5/this['options']['maxCanvasSize'],_0x502cf8/_0x18af14<this[_0x13d83b(0x1dc)]['minCanvasSize']&&(_0x18af14=_0x502cf8/this['options'][_0x13d83b(_0x5de90c._0x45993c)]);else _0x502cf8<this['options']['minCanvasSize']&&(_0x18af14=_0x502cf8/this['options'][_0x13d83b(_0x5de90c._0x13fbca)],_0x51c6d5/_0x18af14>this['options'][_0x13d83b(0x1b7)]&&(_0x18af14=_0x51c6d5/this[_0x13d83b(0x1dc)][_0x13d83b(_0x5de90c._0x3c7059)]));const _0x3b0db0=this[_0x13d83b(0x1b5)]['radius']*1.5,_0x46ee33=_0x315525/_0x18af14+_0x3b0db0*0x2,_0x45042=_0x42af3d/_0x18af14+_0x3b0db0*0x2,_0x1fdb33=_0x3b0db0*_0x18af14;_0xbc5598['xmin']-=_0x1fdb33,_0xbc5598['ymin']-=_0x1fdb33,_0xbc5598[_0x13d83b(_0x5de90c._0x3cf73e)]+=_0x1fdb33,_0xbc5598['ymax']+=_0x1fdb33,this['_scale']=_0x18af14,_0x548e06=geLatLngBounds(_0xbc5598),this['_rectangle']=Cesium[_0x13d83b(_0x5de90c._0x20ee6f)]['fromDegrees'](_0x548e06['xmin'],_0x548e06['ymin'],_0x548e06['xmax'],_0x548e06['ymax']);let _0x1f5f7f=_0x4d9347[0x0]['value']??0x1,_0x1a5a4d=_0x4d9347[0x0]['value']??0x0;const _0x1e2838=[];_0x4d9347['forEach'](_0x24b9ff=>{const _0x1fa6f2=_0x13d83b,_0x3499af=mars3d__namespace['PointTrans']['lonlat2mercator']([_0x24b9ff['lng'],_0x24b9ff['lat']]),_0x452174=_0x24b9ff['value']||0x1,_0x39e3f4=Math['round']((_0x3499af[0x0]-_0xbc5598['xmin'])/_0x18af14),_0x4b2545=Math['round']((_0xbc5598[_0x1fa6f2(_0x1dea6a._0x30d5a4)]-_0x3499af[0x1])/_0x18af14);_0x1f5f7f=Math['max'](_0x1f5f7f,_0x452174),_0x1a5a4d=Math['min'](_0x1a5a4d,_0x452174),_0x1e2838['push']({'x':_0x39e3f4,'y':_0x4b2545,'value':_0x452174});});const _0x3fb193={'min':this['options'][_0x13d83b(_0x5de90c._0x2402ea)]??_0x1a5a4d,'max':this['options']['max']??_0x1f5f7f,'data':_0x1e2838};this['_last_heatData']=_0x3fb193;if(!this['_last_mBounds']||_0xbc5598[_0x13d83b(0x1ea)]!==this['_last_mBounds']['xmin']||_0xbc5598[_0x13d83b(0x1d2)]!==this['_last_mBounds']['ymin']||_0xbc5598[_0x13d83b(_0x5de90c._0x3cf73e)]!==this['_last_mBounds']['xmax']||_0xbc5598[_0x13d83b(0x1e8)]!==this['_last_mBounds']['ymax']){this['_last_mBounds']=_0xbc5598,this['_container']['style'][_0x13d83b(_0x5de90c._0x29153a)]='width:'+_0x46ee33+'px;height:'+_0x45042+_0x13d83b(0x1ce);const _0x2a2a10={...this[_0x13d83b(_0x5de90c._0x84d2d4)],'container':this[_0x13d83b(_0x5de90c._0x3d34ed)]};!this[_0x13d83b(_0x5de90c._0x373d99)]?this['_heat']=h337__namespace['create'](_0x2a2a10):this[_0x13d83b(_0x5de90c._0x25a6e3)]['configure'](_0x2a2a10);}this['_heat']['setData'](_0x3fb193);const _0x2c96e8=mars3d__namespace[_0x13d83b(0x1d6)][_0x13d83b(0x1ad)](this['_heat']['_renderer']['canvas']);return _0x2c96e8;}[_0xa90bb2(0x1e9)](){const _0x5e3fd4={_0x3c1f9b:0x1cb,_0x10089d:0x1d3,_0x1a7934:0x1a5,_0x56c5a5:0x1b5},_0x38bcaa=_0xa90bb2;this['_heat'][_0x38bcaa(0x1cf)]({'radius':this['heatStyle'][_0x38bcaa(_0x5e3fd4._0x3c1f9b)]*this['style']['arcRadiusScale'],'blur':this['heatStyle'][_0x38bcaa(_0x5e3fd4._0x10089d)]*this['style'][_0x38bcaa(_0x5e3fd4._0x1a7934)],'gradient':this[_0x38bcaa(_0x5e3fd4._0x56c5a5)]['gradientArc']||{0.25:_0x38bcaa(0x1aa),0.55:'rgb(140,140,140)',0.85:'rgb(216,216,216)',0x1:'rgb(255,255,255)'}});const _0xeae96c=mars3d__namespace['DomUtil']['copyCanvas'](this['_heat']['_renderer'][_0x38bcaa(0x1d8)]);return this['_heat']['configure'](this['options'][_0x38bcaa(0x1b5)]),_0xeae96c;}['getPointData'](_0x24ca1e){const _0xa62eee={_0x2a144b:0x1c0},_0xbffe2=_0xa90bb2,_0x2adc9a=mars3d__namespace['LngLatPoint']['parse'](_0x24ca1e);if(!_0x2adc9a)return{};const _0x27b12e=mars3d__namespace['PointTrans']['lonlat2mercator']([_0x2adc9a['lng'],_0x2adc9a['lat']]),_0x548831=this['_last_mBounds'],_0x52f694=Math['round']((_0x27b12e[0x0]-_0x548831['xmin'])/this['_scale']),_0x456c20=Math[_0xbffe2(0x1eb)]((_0x548831[_0xbffe2(0x1e8)]-_0x27b12e[0x1])/this['_scale']),_0x3aa4cd=this['_heat']['getValueAt']({'x':_0x52f694,'y':_0x456c20}),_0x30eea5=this[_0xbffe2(0x1f0)][_0xbffe2(0x1e7)]['ctx'][_0xbffe2(_0xa62eee._0x2a144b)](_0x52f694-0x1,_0x456c20-0x1,0x1,0x1)['data'];return{'x':_0x52f694,'y':_0x456c20,'value':_0x3aa4cd,'color':'rgba('+_0x30eea5[0x0]+','+_0x30eea5[0x1]+','+_0x30eea5[0x2]+','+_0x30eea5[0x3]+')'};}}function _0x2d96(_0x119e63,_0x197c22){const _0x1c8aed=_0x1c8a();return _0x2d96=function(_0x2d96d7,_0x526d5e){_0x2d96d7=_0x2d96d7-0x1a0;let _0x164a73=_0x1c8aed[_0x2d96d7];return _0x164a73;},_0x2d96(_0x119e63,_0x197c22);}function _0x1c8a(){const _0x3d377e=['22179036NCUWek','BaseLayer','_map','style','value','_rectangle','clear','100BzbhuN','_container','PointTrans','13oleLsv','__esModule','arcBlurScale','LayerUtil','PolyUtil','defineProperty','Rectangle','rgb(0,0,0)','ALWAYS','max','copyCanvas','StencilOperation','_graphic','2209540wBLNQm','62013riegTf','92904tPMBEM','image','isFormat','heatStyle','push','maxCanvasSize','EllipsoidSurfaceAppearance','2UpAqJq','请引入\x20heatmap.js\x20库\x20','rectangle','uniforms','_getHeatCanvas','parse','_mBoundsMax','getImageData','positions','addPosition','setPositions','blue','KEEP','red','Util','Cesium','6wsNQSL','coordinates','radius','default','width','px;','configure','1892166Uezees','mercator2lonlat','ymin','blur','140kjeBuQ','_updatePositionsHook','DomUtil','merge','canvas','_addedHook','136mWOsns','addGraphic','options','layer','min','Cartesian2','RectanglePrimitive','lng','lonlat2mercator','VERTEX_FORMAT','create','diffHeight','length','_renderer','ymax','_getArcHeatCanvas','xmin','round','7107750hmwRay','cssText','keys','bumpMap','_heat','getRectangle','removeLayer','minCanvasSize','graphic','fromCache','1767788HiZKAV','_layer','xmax','show'];_0x1c8a=function(){return _0x3d377e;};return _0x1c8a();}mars3d__namespace[_0xa90bb2(0x1a6)]['register']('heat',HeatLayer),mars3d__namespace['layer']['HeatLayer']=HeatLayer,mars3d__namespace['h337']=h337__namespace;function getMercatorBounds(_0x25e910){const _0x565bef={_0x54dc76:0x1d2},_0x591e9a=_0xa90bb2,_0x5ebeaa=mars3d__namespace['PointTrans'][_0x591e9a(0x1e2)]([_0x25e910['xmin'],_0x25e910[_0x591e9a(_0x565bef._0x54dc76)]]),_0xa416fe=mars3d__namespace['PointTrans']['lonlat2mercator']([_0x25e910[_0x591e9a(0x1f8)],_0x25e910['ymax']]);return{'xmin':_0x5ebeaa[0x0],'ymin':_0x5ebeaa[0x1],'xmax':_0xa416fe[0x0],'ymax':_0xa416fe[0x1]};}function geLatLngBounds(_0x31bf13){const _0x19c932={_0x4fa056:0x1d1,_0x5f04ed:0x1a2},_0x2ebdc6=_0xa90bb2,_0x28a790=mars3d__namespace['PointTrans'][_0x2ebdc6(_0x19c932._0x4fa056)]([_0x31bf13['xmin'],_0x31bf13['ymin']]),_0x4270ab=mars3d__namespace[_0x2ebdc6(_0x19c932._0x5f04ed)]['mercator2lonlat']([_0x31bf13['xmax'],_0x31bf13['ymax']]);return{'xmin':_0x28a790[0x0],'ymin':_0x28a790[0x1],'xmax':_0x4270ab[0x0],'ymax':_0x4270ab[0x1]};}function getVertexShaderSource(_0x32b008){return'in\x20vec3\x20position3DHigh;\x0a\x20\x20in\x20vec3\x20position3DLow;\x0a\x20\x20in\x20vec2\x20st;\x0a\x20\x20in\x20float\x20batchId;\x0a\x20\x20uniform\x20sampler2D\x20bumpMap_3;\x0a\x20\x20out\x20vec3\x20v_positionMC;\x0a\x20\x20out\x20vec3\x20v_positionEC;\x0a\x20\x20out\x20vec2\x20v_st;\x0a\x0a\x20\x20void\x20main()\x0a\x20\x20{\x0a\x20\x20\x20\x20vec4\x20p\x20=\x20czm_computePosition();\x0a\x20\x20\x20\x20v_positionMC\x20=\x20position3DHigh\x20+\x20position3DLow;\x0a\x20\x20\x20\x20v_positionEC\x20=\x20(czm_modelViewRelativeToEye\x20*\x20p).xyz;\x0a\x20\x20\x20\x20v_st\x20=\x20st;\x0a\x20\x20\x20\x20vec4\x20color\x20=\x20texture(bumpMap_3,\x20v_st);\x0a\x20\x20\x20\x20float\x20centerBump\x20=\x20distance(vec3(0.0),color.rgb);\x0a\x20\x20\x20\x20vec3\x20upDir\x20=\x20normalize(v_positionMC.xyz);\x0a\x20\x20\x20\x20vec3\x20disPos\x20=\x20upDir\x20*\x20centerBump\x20*\x20'+_0x32b008+';\x0a\x20\x20\x20\x20p\x20+=vec4(disPos,0.0);\x0a\x20\x20\x20\x20gl_Position\x20=\x20czm_modelViewProjectionRelativeToEye\x20*\x20p;\x0a\x20\x20}\x0a';}exports['HeatLayer']=HeatLayer,Object[_0xa90bb2(0x1a8)](exports,'__esModule',{'value':!![]});
15
15
  }));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mars3d-heatmap",
3
- "version": "3.6.2",
3
+ "version": "3.6.4",
4
4
  "description": "Mars3D平台插件,结合heatmap可视化功能插件",
5
5
  "main": "dist/mars3d-heatmap.js",
6
6
  "files": [
@@ -10,7 +10,7 @@
10
10
  "@mars3d/heatmap.js": "^2.0.6"
11
11
  },
12
12
  "devDependencies": {
13
- "mars3d": "~3.6.2"
13
+ "mars3d": "~3.6.4"
14
14
  },
15
15
  "scripts": {
16
16
  "lint": "eslint ./src/**/*.{js,ts} --fix"