mars3d-echarts
Advanced tools
Comparing version 3.7.2 to 3.7.3
/** | ||
* Mars3D平台插件,结合echarts可视化功能插件 mars3d-echarts | ||
* | ||
* 版本信息:v3.7.2 | ||
* 编译日期:2024-01-29 17:17:24 | ||
* 版本信息:v3.7.3 | ||
* 编译日期:2024-02-05 15:49:49 | ||
* 版权所有:Copyright by 火星科技 http://mars3d.cn | ||
@@ -14,3 +14,3 @@ * 使用单位:免费公开版 ,2024-01-15 | ||
})(this, (function (exports, echarts, mars3d) { | ||
'use strict';const _0x19a9fe=_0x4f1a;(function(_0x46e226,_0x5c5e49){const _0xc55335={_0x3f2a88:0x1f6,_0x29fa8e:0x202,_0x385b33:0x211,_0x32c52a:0x1f9},_0xf78f57=_0x4f1a,_0x53d09d=_0x46e226();while(!![]){try{const _0x1464f9=parseInt(_0xf78f57(0x1ee))/0x1*(parseInt(_0xf78f57(0x212))/0x2)+-parseInt(_0xf78f57(0x1f3))/0x3*(parseInt(_0xf78f57(_0xc55335._0x3f2a88))/0x4)+-parseInt(_0xf78f57(_0xc55335._0x29fa8e))/0x5*(parseInt(_0xf78f57(_0xc55335._0x385b33))/0x6)+-parseInt(_0xf78f57(0x215))/0x7+-parseInt(_0xf78f57(_0xc55335._0x32c52a))/0x8+-parseInt(_0xf78f57(0x1ea))/0x9*(-parseInt(_0xf78f57(0x20f))/0xa)+parseInt(_0xf78f57(0x21a))/0xb;if(_0x1464f9===_0x5c5e49)break;else _0x53d09d['push'](_0x53d09d['shift']());}catch(_0x53c7fb){_0x53d09d['push'](_0x53d09d['shift']());}}}(_0x11aa,0xbb4ee));function _interopNamespace(_0x280f29){const _0x5ed4d6={_0xaa691f:0x220},_0x5915a6=_0x4f1a;if(_0x280f29&&_0x280f29['__esModule'])return _0x280f29;var _0x59d7d0=Object['create'](null);return _0x280f29&&Object['keys'](_0x280f29)[_0x5915a6(0x228)](function(_0x2b115b){const _0x1b2691=_0x5915a6;if(_0x2b115b!==_0x1b2691(0x225)){var _0x252430=Object['getOwnPropertyDescriptor'](_0x280f29,_0x2b115b);Object['defineProperty'](_0x59d7d0,_0x2b115b,_0x252430[_0x1b2691(_0x5ed4d6._0xaa691f)]?_0x252430:{'enumerable':!![],'get':function(){return _0x280f29[_0x2b115b];}});}}),_0x59d7d0['default']=_0x280f29,_0x59d7d0;}var echarts__namespace=_interopNamespace(echarts),mars3d__namespace=_interopNamespace(mars3d);const Cesium$1=mars3d__namespace[_0x19a9fe(0x1ff)];class CompositeCoordinateSystem{constructor(_0x4edfb7,_0xe975cf){const _0x107f25={_0x36f33e:0x1eb,_0x3d42f1:0x20a},_0x12ba3c=_0x19a9fe;this['_mars3d_scene']=_0x4edfb7,this['dimensions']=['lng',_0x12ba3c(_0x107f25._0x36f33e)],this[_0x12ba3c(_0x107f25._0x3d42f1)]=[0x0,0x0],this['_api']=_0xe975cf;}[_0x19a9fe(0x223)](_0x4e6567){this['_mapOffset']=_0x4e6567;}['getBMap'](){return this['_mars3d_scene'];}['dataToPoint'](_0x39e3cb){const _0x2fa2b0={_0x726daf:0x1fe,_0x584e4c:0x21c,_0x276889:0x20a},_0x38465b=_0x19a9fe,_0x1e55c4=this['_mars3d_scene'],_0xf76e93=[NaN,NaN];let _0x48bcb4=_0x1e55c4['echartsFixedHeight'];_0x1e55c4['echartsAutoHeight']&&(_0x48bcb4=_0x1e55c4['globe']['getHeight'](Cesium$1['Cartographic']['fromDegrees'](_0x39e3cb[0x0],_0x39e3cb[0x1])));const _0x2293ba=Cesium$1[_0x38465b(_0x2fa2b0._0x726daf)]['fromDegrees'](_0x39e3cb[0x0],_0x39e3cb[0x1],_0x48bcb4);if(!_0x2293ba)return _0xf76e93;const _0x1be56e=Cesium$1['SceneTransforms']['wgs84ToWindowCoordinates'](_0x1e55c4,_0x2293ba);if(!_0x1be56e)return _0xf76e93;if(_0x1e55c4[_0x38465b(0x20c)]&&_0x1e55c4['mode']===Cesium$1['SceneMode']['SCENE3D']){const _0x2cb3c8=new Cesium$1['EllipsoidalOccluder'](_0x1e55c4['globe'][_0x38465b(_0x2fa2b0._0x584e4c)],_0x1e55c4['camera']['positionWC']),_0x497536=_0x2cb3c8['isPointVisible'](_0x2293ba);if(!_0x497536)return _0xf76e93;}return[_0x1be56e['x']-this['_mapOffset'][0x0],_0x1be56e['y']-this[_0x38465b(_0x2fa2b0._0x276889)][0x1]];}['getViewRect'](){const _0x38ebfe={_0x5688df:0x216},_0x18a634=_0x19a9fe,_0x41f9cc=this['_api'];return new echarts__namespace['graphic']['BoundingRect'](0x0,0x0,_0x41f9cc[_0x18a634(_0x38ebfe._0x5688df)](),_0x41f9cc['getHeight']());}['getRoamTransform'](){return echarts__namespace['matrix']['create']();}}function _0x4f1a(_0x249d4d,_0x11035c){const _0x11aa2a=_0x11aa();return _0x4f1a=function(_0x4f1a5e,_0x275e13){_0x4f1a5e=_0x4f1a5e-0x1e8;let _0x330705=_0x11aa2a[_0x4f1a5e];return _0x330705;},_0x4f1a(_0x249d4d,_0x11035c);}CompositeCoordinateSystem['dimensions']=[_0x19a9fe(0x224),_0x19a9fe(0x1eb)],CompositeCoordinateSystem['create']=function(_0x1c8138,_0xeca1a1){const _0x2858be={_0x15ab56:0x1fb},_0x44930f={_0x193cba:0x20b},_0x19b714={_0x3b4ae8:0x1e8},_0xdd9280=_0x19a9fe;let _0x4d5a16;const _0x20b745=_0x1c8138['scheduler'][_0xdd9280(0x1fa)]['_mars3d_scene'];_0x1c8138['eachComponent'](_0xdd9280(_0x2858be._0x15ab56),function(_0xaab140){const _0x46b4b5=_0xdd9280,_0x29b9b9=_0xeca1a1['getZr']()[_0x46b4b5(0x21e)];if(!_0x29b9b9)return;!_0x4d5a16&&(_0x4d5a16=new CompositeCoordinateSystem(_0x20b745,_0xeca1a1)),_0xaab140['coordinateSystem']=_0x4d5a16,_0x4d5a16['setMapOffset'](_0xaab140[_0x46b4b5(_0x19b714._0x3b4ae8)]||[0x0,0x0]);}),_0x1c8138['eachSeries'](function(_0x2bfef0){const _0x6845c9=_0xdd9280;_0x2bfef0['get'](_0x6845c9(_0x44930f._0x193cba))==='mars3dMap'&&(!_0x4d5a16&&(_0x4d5a16=new CompositeCoordinateSystem(_0x20b745,_0xeca1a1)),_0x2bfef0['coordinateSystem']=_0x4d5a16);});};if(echarts__namespace!==null&&echarts__namespace!==void 0x0&&echarts__namespace['init'])echarts__namespace[_0x19a9fe(0x201)]('mars3dMap',CompositeCoordinateSystem),echarts__namespace[_0x19a9fe(0x218)]({'type':'mars3dMapRoam','event':_0x19a9fe(0x21f),'update':'updateLayout'},function(_0x46a831,_0x55ec06){}),echarts__namespace[_0x19a9fe(0x20e)]({'type':_0x19a9fe(0x1fb),'getBMap':function(){const _0x50be9a={_0x54e2a0:0x1f5},_0x4c9547=_0x19a9fe;return this[_0x4c9547(_0x50be9a._0x54e2a0)];},'defaultOption':{'roam':![]}}),echarts__namespace['extendComponentView']({'type':'mars3dMap','init':function(_0x5b7964,_0x38d9fb){const _0x33f9b8={_0x6546e1:0x213,_0x4ead93:0x1f4},_0x19a89=_0x19a9fe;this['api']=_0x38d9fb,this[_0x19a89(_0x33f9b8._0x6546e1)]=_0x5b7964['scheduler']['ecInstance']['_mars3d_scene'],this[_0x19a89(0x213)][_0x19a89(_0x33f9b8._0x4ead93)]['addEventListener'](this['moveHandler'],this);},'moveHandler':function(_0xc6a5bb,_0x1439ca){const _0x54c92c={_0x49197d:0x214},_0xdd56f0=_0x19a9fe;this[_0xdd56f0(_0x54c92c._0x49197d)][_0xdd56f0(0x204)]({'type':'mars3dMapRoam'});},'render':function(_0x3f84bb,_0x3e4112,_0x2109d8){},'dispose':function(_0x5f0e4e){this['scene']['postRender']['removeEventListener'](this['moveHandler'],this);}});else throw new Error(_0x19a9fe(0x1f1));function _0x11aa(){const _0xb24ce4=['onByQuery','style','_createChartOverlay','_mapOffset','coordinateSystem','echartsDepthTest','visible','extendComponentModel','20FXSpzw','_showHook','72OmCDjJ','2290034UEMpsq','scene','api','5450970hSkuIt','getWidth','fromDegrees','registerAction','visibility','4378429eTuuQu','setOption','ellipsoid','options','painter','mars3dMapRoam','get','pointerEvents','echartsFixedHeight','setMapOffset','lng','default','_echartsInstance','_setOptionsHook','forEach','__mapOffset','resize','5278032mucDyD','lat','max','_removedHook','1rnWNxh','clientWidth','_pointerEvents','请引入\x20echarts\x20库\x20','echartsAutoHeight','246NzYNYG','postRender','_mars3d_scene','34384uojIir','_echartsContainer','_map','601536NFwbOH','ecInstance','mars3dMap','none','value','Cartesian3','Cesium','zIndex','registerCoordinateSystem','162485MSImxY','isFormat','dispatchAction','setEchartsOption','Util'];_0x11aa=function(){return _0xb24ce4;};return _0x11aa();}const Cesium=mars3d__namespace[_0x19a9fe(0x1ff)],BaseLayer=mars3d__namespace['layer']['BaseLayer'];class EchartsLayer extends BaseLayer{constructor(_0x18bc95={}){const _0x557a5c={_0x1dcc14:0x21d},_0x36ccfe=_0x19a9fe;super(_0x18bc95),this[_0x36ccfe(0x1f0)]=this[_0x36ccfe(_0x557a5c._0x1dcc14)]['pointerEvents'];}get['layer'](){return this['_echartsInstance'];}get['pointerEvents'](){const _0x579a4d={_0x505446:0x1f0},_0x370bb3=_0x19a9fe;return this[_0x370bb3(_0x579a4d._0x505446)];}set[_0x19a9fe(0x221)](_0x127183){const _0x583934={_0x22ba87:0x1f7,_0x487a8c:0x1fc},_0x4a9b26=_0x19a9fe;this['_pointerEvents']=_0x127183,this[_0x4a9b26(0x1f7)]&&(_0x127183?this['_echartsContainer']['style']['pointerEvents']='all':this[_0x4a9b26(_0x583934._0x22ba87)]['style']['pointerEvents']=_0x4a9b26(_0x583934._0x487a8c));}[_0x19a9fe(0x227)](_0x174b6c,_0x286b03){const _0x3dd22a={_0x290c44:0x205},_0x18de6b=_0x19a9fe;this[_0x18de6b(_0x3dd22a._0x290c44)](_0x174b6c);}[_0x19a9fe(0x210)](_0x1bf8ca){const _0xa4d3f0=_0x19a9fe;_0x1bf8ca?this[_0xa4d3f0(0x1f7)]['style'][_0xa4d3f0(0x219)]=_0xa4d3f0(0x20d):this['_echartsContainer']['style']['visibility']='hidden';}['_mountedHook'](){const _0x195659={_0x45115f:0x213,_0x4ba0c0:0x21d},_0x33effb=_0x19a9fe;this['_map']['scene'][_0x33effb(0x20c)]=this['options']['depthTest']??!![],this['_map'][_0x33effb(_0x195659._0x45115f)][_0x33effb(0x1f2)]=this[_0x33effb(_0x195659._0x4ba0c0)]['clampToGround']??![],this['_map']['scene'][_0x33effb(0x222)]=this['options']['fixedHeight']??0x0;}['_addedHook'](){const _0x51054b={_0x28764d:0x209,_0x23834c:0x1f8},_0x4d242c=_0x19a9fe;this['_echartsContainer']=this[_0x4d242c(_0x51054b._0x28764d)](),this['_echartsInstance']=echarts__namespace['init'](this['_echartsContainer']),this[_0x4d242c(0x226)]['_mars3d_scene']=this[_0x4d242c(_0x51054b._0x23834c)]['scene'],this['setEchartsOption'](this[_0x4d242c(0x21d)]);}[_0x19a9fe(0x1ed)](){const _0x4b0564={_0x14cbde:0x226},_0x5d237a=_0x19a9fe;this['_echartsInstance']&&(this[_0x5d237a(_0x4b0564._0x14cbde)]['clear'](),this['_echartsInstance']['dispose'](),delete this[_0x5d237a(0x226)]),this['_echartsContainer']&&(this[_0x5d237a(0x1f8)]['container']['removeChild'](this['_echartsContainer']),delete this['_echartsContainer']);}['_createChartOverlay'](){const _0x29e44c={_0x156c7f:0x1f8,_0x4a6968:0x1fc,_0x1fbec5:0x200},_0x2751e6=_0x19a9fe,_0x21998b=mars3d__namespace['DomUtil']['create']('div','mars3d-echarts',this[_0x2751e6(_0x29e44c._0x156c7f)]['container']);return _0x21998b['id']=this['id'],_0x21998b['style']['position']='absolute',_0x21998b['style']['top']='0px',_0x21998b['style']['left']='0px',_0x21998b[_0x2751e6(0x208)]['width']=this['_map']['scene']['canvas']['clientWidth']+'px',_0x21998b['style']['height']=this['_map']['scene']['canvas']['clientHeight']+'px',_0x21998b['style']['pointerEvents']=this[_0x2751e6(0x1f0)]?'all':_0x2751e6(_0x29e44c._0x4a6968),_0x21998b['style'][_0x2751e6(_0x29e44c._0x1fbec5)]=this['options']['zIndex']??0x9,_0x21998b;}[_0x19a9fe(0x1e9)](){const _0x1d24a8={_0x2340bd:0x1f7,_0x4bd996:0x1ef},_0x2173f7=_0x19a9fe;if(!this[_0x2173f7(0x226)])return;this[_0x2173f7(_0x1d24a8._0x2340bd)]['style']['width']=this['_map']['scene']['canvas'][_0x2173f7(_0x1d24a8._0x4bd996)]+'px',this['_echartsContainer']['style']['height']=this['_map']['scene']['canvas']['clientHeight']+'px',this['_echartsInstance']['resize']();}['setEchartsOption'](_0x40ebf3,_0x28736b,_0x5b9ae1){const _0x7e66ec={_0x3dd4dd:0x21b},_0x30a851=_0x19a9fe;this['_echartsInstance']&&(_0x40ebf3={'mars3dMap':{},...mars3d__namespace[_0x30a851(0x206)]['getAttrVal'](_0x40ebf3,{'onlySimpleType':!![]})},delete _0x40ebf3['eventParent'],this['_echartsInstance'][_0x30a851(_0x7e66ec._0x3dd4dd)](_0x40ebf3,_0x28736b,_0x5b9ae1));}['getRectangle'](_0x570021){const _0x4c0153={_0x224866:0x21d},_0x26c89a={_0x14f05a:0x1ec},_0x1afa04=_0x19a9fe;let _0x1530f2,_0x18cc38,_0x2f5e75,_0x450b70;function _0xa0b933(_0x10da0a){const _0x302a52=_0x4f1a;if(!Array['isArray'](_0x10da0a))return;const _0x270c7=_0x10da0a[0x0]||0x0,_0x2ff19f=_0x10da0a[0x1]||0x0;_0x270c7!==0x0&&_0x2ff19f!==0x0&&(_0x1530f2===undefined?(_0x1530f2=_0x270c7,_0x18cc38=_0x270c7,_0x2f5e75=_0x2ff19f,_0x450b70=_0x2ff19f):(_0x1530f2=Math['min'](_0x1530f2,_0x270c7),_0x18cc38=Math['max'](_0x18cc38,_0x270c7),_0x2f5e75=Math['min'](_0x2f5e75,_0x2ff19f),_0x450b70=Math[_0x302a52(_0x26c89a._0x14f05a)](_0x450b70,_0x2ff19f)));}const _0x28fc0a=this[_0x1afa04(_0x4c0153._0x224866)]['series'];_0x28fc0a&&_0x28fc0a['forEach'](_0x51b935=>{const _0x4f8305={_0x2bf35c:0x1fd};_0x51b935['data']&&_0x51b935['data']['forEach'](_0x63e344=>{const _0x50dbdd=_0x4f1a;if(_0x63e344[_0x50dbdd(_0x4f8305._0x2bf35c)])_0xa0b933(_0x63e344[_0x50dbdd(0x1fd)]);else _0x63e344['coords']&&_0x63e344['coords']['forEach'](_0x11c8c5=>{_0xa0b933(_0x11c8c5);});});});if(_0x1530f2===0x0&&_0x2f5e75===0x0&&_0x18cc38===0x0&&_0x450b70===0x0)return null;return _0x570021!==null&&_0x570021!==void 0x0&&_0x570021[_0x1afa04(0x203)]?{'xmin':_0x1530f2,'xmax':_0x18cc38,'ymin':_0x2f5e75,'ymax':_0x450b70}:Cesium['Rectangle'][_0x1afa04(0x217)](_0x1530f2,_0x2f5e75,_0x18cc38,_0x450b70);}['on'](_0x730362,_0x57b1df,_0x44ea87){return this['_echartsInstance']['on'](_0x730362,_0x57b1df,_0x44ea87||this),this;}[_0x19a9fe(0x207)](_0x4875ad,_0x45aee8,_0x215181,_0x58a994){return this['_echartsInstance']['on'](_0x4875ad,_0x45aee8,_0x215181,_0x58a994||this),this;}['off'](_0x10472d,_0x4022b3,_0x50f611){const _0x3344c5=_0x19a9fe;return this[_0x3344c5(0x226)]['off'](_0x10472d,_0x4022b3,_0x50f611||this),this;}}mars3d__namespace['LayerUtil']['register']('echarts',EchartsLayer),mars3d__namespace['layer']['EchartsLayer']=EchartsLayer,mars3d__namespace['echarts']=echarts__namespace,exports['EchartsLayer']=EchartsLayer,Object['keys'](echarts)['forEach'](function(_0xa0181e){if(_0xa0181e!=='default'&&!exports['hasOwnProperty'](_0xa0181e))Object['defineProperty'](exports,_0xa0181e,{'enumerable':!![],'get':function(){return echarts[_0xa0181e];}});}),Object['defineProperty'](exports,'__esModule',{'value':!![]}); | ||
'use strict';const _0x96f486=_0x3a42;function _0x3af4(){const _0x180916=['canvas','api','min','removeChild','fixedHeight','_api','setEchartsOption','_echartsContainer','height','div','Util','options','_map','forEach','38548wzYyBu','7099mgqEin','value','off','clear','Cartesian3','create','positionWC','get','clientWidth','eachSeries','postRender','fromDegrees','eventParent','2202752jFUwlD','SCENE3D','register','dimensions','style','getViewRect','3038046JxpWes','_mapOffset','hasOwnProperty','SceneTransforms','0px','_echartsInstance','59178bszoGV','lat','isArray','scene','58iindTB','EchartsLayer','_removedHook','48339TYogdD','_pointerEvents','462Jrxexr','190hMOAeL','getWidth','LayerUtil','clampToGround','max','370UJnBAe','mars3dMapRoam','_mars3d_scene','defineProperty','16085201kfPmTE','mars3dMap'];_0x3af4=function(){return _0x180916;};return _0x3af4();}(function(_0x69f2da,_0x16867a){const _0x7fd15f={_0x5c886c:0x1ac,_0x44c40c:0x1bf,_0x55cada:0x1ab,_0x279059:0x18f,_0x4747d7:0x192},_0x4ed8e0=_0x3a42,_0x950441=_0x69f2da();while(!![]){try{const _0x24ded5=parseInt(_0x4ed8e0(_0x7fd15f._0x5c886c))/0x1*(parseInt(_0x4ed8e0(0x1c9))/0x2)+-parseInt(_0x4ed8e0(_0x7fd15f._0x44c40c))/0x3+-parseInt(_0x4ed8e0(_0x7fd15f._0x55cada))/0x4*(-parseInt(_0x4ed8e0(0x197))/0x5)+-parseInt(_0x4ed8e0(0x1c5))/0x6*(parseInt(_0x4ed8e0(0x191))/0x7)+-parseInt(_0x4ed8e0(0x1b9))/0x8+-parseInt(_0x4ed8e0(_0x7fd15f._0x279059))/0x9*(-parseInt(_0x4ed8e0(_0x7fd15f._0x4747d7))/0xa)+parseInt(_0x4ed8e0(0x19b))/0xb;if(_0x24ded5===_0x16867a)break;else _0x950441['push'](_0x950441['shift']());}catch(_0x192f37){_0x950441['push'](_0x950441['shift']());}}}(_0x3af4,0x84e6d));function _interopNamespace(_0x5581ef){const _0x2ebf86={_0x175011:0x1b1},_0x4a7c68={_0x3f0b0:0x19a},_0x5559b7=_0x3a42;if(_0x5581ef&&_0x5581ef['__esModule'])return _0x5581ef;var _0x4120ad=Object[_0x5559b7(_0x2ebf86._0x175011)](null);return _0x5581ef&&Object['keys'](_0x5581ef)['forEach'](function(_0x517b30){const _0x1c5d10=_0x5559b7;if(_0x517b30!=='default'){var _0x304f15=Object['getOwnPropertyDescriptor'](_0x5581ef,_0x517b30);Object[_0x1c5d10(_0x4a7c68._0x3f0b0)](_0x4120ad,_0x517b30,_0x304f15['get']?_0x304f15:{'enumerable':!![],'get':function(){return _0x5581ef[_0x517b30];}});}}),_0x4120ad['default']=_0x5581ef,_0x4120ad;}var echarts__namespace=_interopNamespace(echarts),mars3d__namespace=_interopNamespace(mars3d);const Cesium$1=mars3d__namespace['Cesium'];class CompositeCoordinateSystem{constructor(_0x4f91f2,_0x2cfab8){const _0x3c8d63={_0xa999e5:0x1c6},_0x3215d3=_0x3a42;this['_mars3d_scene']=_0x4f91f2,this[_0x3215d3(0x1bc)]=['lng',_0x3215d3(_0x3c8d63._0xa999e5)],this['_mapOffset']=[0x0,0x0],this['_api']=_0x2cfab8;}['setMapOffset'](_0xbfcf9f){this['_mapOffset']=_0xbfcf9f;}['getBMap'](){return this['_mars3d_scene'];}['dataToPoint'](_0x26aa4d){const _0x33a2a2={_0x421ebe:0x1b7,_0x3a3959:0x1b7,_0x58c532:0x1ba,_0x140683:0x1b2,_0x23b7f5:0x1c0},_0x50cbe4=_0x3a42,_0x209549=this['_mars3d_scene'],_0x84b865=[NaN,NaN];let _0x44a263=_0x209549['echartsFixedHeight'];_0x209549['echartsAutoHeight']&&(_0x44a263=_0x209549['getHeight'](Cesium$1['Cartographic'][_0x50cbe4(_0x33a2a2._0x421ebe)](_0x26aa4d[0x0],_0x26aa4d[0x1])));const _0x50247f=Cesium$1[_0x50cbe4(0x1b0)][_0x50cbe4(_0x33a2a2._0x3a3959)](_0x26aa4d[0x0],_0x26aa4d[0x1],_0x44a263);if(!_0x50247f)return _0x84b865;const _0x3de1ed=Cesium$1[_0x50cbe4(0x1c2)]['wgs84ToWindowCoordinates'](_0x209549,_0x50247f);if(!_0x3de1ed)return _0x84b865;if(_0x209549['echartsDepthTest']&&_0x209549['mode']===Cesium$1['SceneMode'][_0x50cbe4(_0x33a2a2._0x58c532)]){const _0x4ff2d7=new Cesium$1['EllipsoidalOccluder'](_0x209549['globe']['ellipsoid'],_0x209549['camera'][_0x50cbe4(_0x33a2a2._0x140683)]),_0xbf62e3=_0x4ff2d7['isPointVisible'](_0x50247f);if(!_0xbf62e3)return _0x84b865;}return[_0x3de1ed['x']-this['_mapOffset'][0x0],_0x3de1ed['y']-this[_0x50cbe4(_0x33a2a2._0x23b7f5)][0x1]];}[_0x96f486(0x1be)](){const _0x1e2915={_0x35bb3c:0x193},_0x2d34c4=_0x96f486,_0x4d965c=this[_0x2d34c4(0x1a2)];return new echarts__namespace['graphic']['BoundingRect'](0x0,0x0,_0x4d965c[_0x2d34c4(_0x1e2915._0x35bb3c)](),_0x4d965c['getHeight']());}['getRoamTransform'](){return echarts__namespace['matrix']['create']();}}CompositeCoordinateSystem['dimensions']=['lng','lat'],CompositeCoordinateSystem['create']=function(_0x3aef5d,_0x310cc5){const _0xa532b5={_0x209d8d:0x1b3},_0x11b19e=_0x96f486;let _0x58b116;const _0x109879=_0x3aef5d['scheduler']['ecInstance']['_mars3d_scene'];_0x3aef5d['eachComponent']('mars3dMap',function(_0x2c6e5b){const _0x1b07a7=_0x310cc5['getZr']()['painter'];if(!_0x1b07a7)return;!_0x58b116&&(_0x58b116=new CompositeCoordinateSystem(_0x109879,_0x310cc5)),_0x2c6e5b['coordinateSystem']=_0x58b116,_0x58b116['setMapOffset'](_0x2c6e5b['__mapOffset']||[0x0,0x0]);}),_0x3aef5d[_0x11b19e(0x1b5)](function(_0x5dcf2d){const _0x33da87=_0x11b19e;_0x5dcf2d[_0x33da87(_0xa532b5._0x209d8d)]('coordinateSystem')==='mars3dMap'&&(!_0x58b116&&(_0x58b116=new CompositeCoordinateSystem(_0x109879,_0x310cc5)),_0x5dcf2d['coordinateSystem']=_0x58b116);});};function _0x3a42(_0x5accc8,_0x15281d){const _0x3af4ab=_0x3af4();return _0x3a42=function(_0x3a4230,_0x1267fa){_0x3a4230=_0x3a4230-0x18f;let _0x2655e3=_0x3af4ab[_0x3a4230];return _0x2655e3;},_0x3a42(_0x5accc8,_0x15281d);}if(echarts__namespace!==null&&echarts__namespace!==void 0x0&&echarts__namespace['init'])echarts__namespace['registerCoordinateSystem']('mars3dMap',CompositeCoordinateSystem),echarts__namespace['registerAction']({'type':_0x96f486(0x198),'event':'mars3dMapRoam','update':'updateLayout'},function(_0x482591,_0x597823){}),echarts__namespace['extendComponentModel']({'type':_0x96f486(0x19c),'getBMap':function(){const _0x1857b0={_0x220c9e:0x199},_0x1f2720=_0x96f486;return this[_0x1f2720(_0x1857b0._0x220c9e)];},'defaultOption':{'roam':![]}}),echarts__namespace['extendComponentView']({'type':_0x96f486(0x19c),'init':function(_0x22dff7,_0x4a6254){const _0x28dd68=_0x96f486;this['api']=_0x4a6254,this['scene']=_0x22dff7['scheduler']['ecInstance']['_mars3d_scene'],this['scene'][_0x28dd68(0x1b6)]['addEventListener'](this['moveHandler'],this);},'moveHandler':function(_0x5291e5,_0x3731ee){const _0x5a5045=_0x96f486;this[_0x5a5045(0x19e)]['dispatchAction']({'type':'mars3dMapRoam'});},'render':function(_0x4a2168,_0x1283ee,_0x2da53d){},'dispose':function(_0xf115c){this['scene']['postRender']['removeEventListener'](this['moveHandler'],this);}});else throw new Error('请引入\x20echarts\x20库\x20');const Cesium=mars3d__namespace['Cesium'],BaseLayer=mars3d__namespace['layer']['BaseLayer'];class EchartsLayer extends BaseLayer{constructor(_0x2a7e6f={}){super(_0x2a7e6f),this['_pointerEvents']=this['options']['pointerEvents'];}get['layer'](){return this['_echartsInstance'];}get['pointerEvents'](){return this['_pointerEvents'];}set['pointerEvents'](_0x139610){const _0x2fc6d6={_0x304912:0x190},_0x483cb0=_0x96f486;this[_0x483cb0(_0x2fc6d6._0x304912)]=_0x139610,this[_0x483cb0(0x1a4)]&&(_0x139610?this[_0x483cb0(0x1a4)]['style']['pointerEvents']='all':this[_0x483cb0(0x1a4)]['style']['pointerEvents']='none');}['_setOptionsHook'](_0x257cca,_0x4e5a87){this['setEchartsOption'](_0x257cca);}['_showHook'](_0xe3e62b){const _0x507559=_0x96f486;_0xe3e62b?this['_echartsContainer'][_0x507559(0x1bd)]['visibility']='visible':this[_0x507559(0x1a4)][_0x507559(0x1bd)]['visibility']='hidden';}['_mountedHook'](){const _0x5e7135={_0x51c78b:0x1a8,_0x5e0a93:0x1a9,_0x59643c:0x1c8},_0x5aa45b=_0x96f486;this['_map']['scene']['echartsDepthTest']=this[_0x5aa45b(_0x5e7135._0x51c78b)]['depthTest']??!![],this[_0x5aa45b(_0x5e7135._0x5e0a93)][_0x5aa45b(_0x5e7135._0x59643c)]['echartsAutoHeight']=this[_0x5aa45b(_0x5e7135._0x51c78b)][_0x5aa45b(0x195)]??![],this['_map']['scene']['echartsFixedHeight']=this['options'][_0x5aa45b(0x1a1)]??0x0;}['_addedHook'](){const _0x1ece25={_0x2b074a:0x1a3},_0x42e92b=_0x96f486;this['_echartsContainer']=this['_createChartOverlay'](),this['_echartsInstance']=echarts__namespace['init'](this['_echartsContainer']),this['_echartsInstance']['_mars3d_scene']=this['_map']['scene'],this[_0x42e92b(_0x1ece25._0x2b074a)](this['options']);}[_0x96f486(0x1cb)](){const _0x3627b6={_0x2f8a39:0x1af,_0x477dad:0x1c4},_0x4c973c=_0x96f486;this['_echartsInstance']&&(this['_echartsInstance'][_0x4c973c(_0x3627b6._0x2f8a39)](),this[_0x4c973c(_0x3627b6._0x477dad)]['dispose'](),delete this[_0x4c973c(0x1c4)]),this['_echartsContainer']&&(this['_map']['container'][_0x4c973c(0x1a0)](this['_echartsContainer']),delete this['_echartsContainer']);}['_createChartOverlay'](){const _0xf2afbf={_0x31feb7:0x1a9,_0x35d149:0x1bd,_0x556b63:0x1b4,_0x79c61a:0x1a5},_0x3404e6=_0x96f486,_0x292676=mars3d__namespace['DomUtil']['create'](_0x3404e6(0x1a6),'mars3d-echarts',this[_0x3404e6(_0xf2afbf._0x31feb7)]['container']);return _0x292676['id']=this['id'],_0x292676[_0x3404e6(_0xf2afbf._0x35d149)]['position']='absolute',_0x292676['style']['top']=_0x3404e6(0x1c3),_0x292676[_0x3404e6(0x1bd)]['left']='0px',_0x292676['style']['width']=this[_0x3404e6(0x1a9)][_0x3404e6(0x1c8)]['canvas'][_0x3404e6(_0xf2afbf._0x556b63)]+'px',_0x292676[_0x3404e6(_0xf2afbf._0x35d149)][_0x3404e6(_0xf2afbf._0x79c61a)]=this['_map']['scene'][_0x3404e6(0x19d)]['clientHeight']+'px',_0x292676[_0x3404e6(_0xf2afbf._0x35d149)]['pointerEvents']=this['_pointerEvents']?'all':'none',_0x292676[_0x3404e6(_0xf2afbf._0x35d149)]['zIndex']=this[_0x3404e6(0x1a8)]['zIndex']??0x9,_0x292676;}['resize'](){const _0x1b41a0={_0xeeb59c:0x19d,_0xa942dd:0x1c8},_0x57e2a1=_0x96f486;if(!this['_echartsInstance'])return;this['_echartsContainer']['style']['width']=this['_map']['scene'][_0x57e2a1(_0x1b41a0._0xeeb59c)]['clientWidth']+'px',this['_echartsContainer'][_0x57e2a1(0x1bd)]['height']=this['_map'][_0x57e2a1(_0x1b41a0._0xa942dd)]['canvas']['clientHeight']+'px',this[_0x57e2a1(0x1c4)]['resize']();}['setEchartsOption'](_0x39ba64,_0x5be96c,_0x303fad){const _0x592c46={_0x344b32:0x1b8},_0x442639=_0x96f486;this['_echartsInstance']&&(_0x39ba64={'mars3dMap':{},...mars3d__namespace[_0x442639(0x1a7)]['getAttrVal'](_0x39ba64,{'onlySimpleType':!![]})},delete _0x39ba64[_0x442639(_0x592c46._0x344b32)],this['_echartsInstance']['setOption'](_0x39ba64,_0x5be96c,_0x303fad));}['getRectangle'](_0x47a71a){const _0x2fb295={_0x26416b:0x196},_0x5eac2a=_0x96f486;let _0x1ca4fd,_0x140aab,_0x178ac7,_0x58c3eb;function _0xf1caca(_0x6e851f){const _0x3d6c05=_0x3a42;if(!Array[_0x3d6c05(0x1c7)](_0x6e851f))return;const _0x4d9d3c=_0x6e851f[0x0]||0x0,_0x5b1048=_0x6e851f[0x1]||0x0;_0x4d9d3c!==0x0&&_0x5b1048!==0x0&&(_0x1ca4fd===undefined?(_0x1ca4fd=_0x4d9d3c,_0x140aab=_0x4d9d3c,_0x178ac7=_0x5b1048,_0x58c3eb=_0x5b1048):(_0x1ca4fd=Math[_0x3d6c05(0x19f)](_0x1ca4fd,_0x4d9d3c),_0x140aab=Math[_0x3d6c05(_0x2fb295._0x26416b)](_0x140aab,_0x4d9d3c),_0x178ac7=Math['min'](_0x178ac7,_0x5b1048),_0x58c3eb=Math['max'](_0x58c3eb,_0x5b1048)));}const _0x1ce0f1=this['options']['series'];_0x1ce0f1&&_0x1ce0f1[_0x5eac2a(0x1aa)](_0x5af1d0=>{_0x5af1d0['data']&&_0x5af1d0['data']['forEach'](_0x34fade=>{const _0x1d6493=_0x3a42;if(_0x34fade[_0x1d6493(0x1ad)])_0xf1caca(_0x34fade['value']);else _0x34fade['coords']&&_0x34fade['coords']['forEach'](_0x243115=>{_0xf1caca(_0x243115);});});});if(_0x1ca4fd===0x0&&_0x178ac7===0x0&&_0x140aab===0x0&&_0x58c3eb===0x0)return null;return _0x47a71a!==null&&_0x47a71a!==void 0x0&&_0x47a71a['isFormat']?{'xmin':_0x1ca4fd,'xmax':_0x140aab,'ymin':_0x178ac7,'ymax':_0x58c3eb}:Cesium['Rectangle']['fromDegrees'](_0x1ca4fd,_0x178ac7,_0x140aab,_0x58c3eb);}['on'](_0x5e7ce7,_0x4dce9d,_0x4b1979){return this['_echartsInstance']['on'](_0x5e7ce7,_0x4dce9d,_0x4b1979||this),this;}['onByQuery'](_0x1b1530,_0x9124a8,_0xef83cf,_0x535902){return this['_echartsInstance']['on'](_0x1b1530,_0x9124a8,_0xef83cf,_0x535902||this),this;}[_0x96f486(0x1ae)](_0x222591,_0x2893fb,_0x2aae44){return this['_echartsInstance']['off'](_0x222591,_0x2893fb,_0x2aae44||this),this;}}mars3d__namespace[_0x96f486(0x194)][_0x96f486(0x1bb)]('echarts',EchartsLayer),mars3d__namespace['layer'][_0x96f486(0x1ca)]=EchartsLayer,mars3d__namespace['echarts']=echarts__namespace,exports[_0x96f486(0x1ca)]=EchartsLayer,Object['keys'](echarts)['forEach'](function(_0xeb7340){const _0x12dd9a=_0x96f486;if(_0xeb7340!=='default'&&!exports[_0x12dd9a(0x1c1)](_0xeb7340))Object['defineProperty'](exports,_0xeb7340,{'enumerable':!![],'get':function(){return echarts[_0xeb7340];}});}),Object[_0x96f486(0x19a)](exports,'__esModule',{'value':!![]}); | ||
})); |
{ | ||
"name": "mars3d-echarts", | ||
"version": "3.7.2", | ||
"version": "3.7.3", | ||
"description": "Mars3D平台插件,结合echarts可视化功能插件", | ||
@@ -13,3 +13,3 @@ "main": "dist/mars3d-echarts.js", | ||
"devDependencies": { | ||
"mars3d": "~3.7.2" | ||
"mars3d": "~3.7.3" | ||
}, | ||
@@ -16,0 +16,0 @@ "scripts": { |
16694
62