mars3d-mapv 3.7.3 → 3.7.5
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.
- package/dist/mars3d-mapv.js +3 -3
- package/package.json +2 -2
package/dist/mars3d-mapv.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Mars3D平台插件,结合mapv可视化功能插件 mars3d-mapv
|
|
3
3
|
*
|
|
4
|
-
* 版本信息:v3.7.
|
|
5
|
-
* 编译日期:2024-
|
|
4
|
+
* 版本信息:v3.7.5
|
|
5
|
+
* 编译日期:2024-03-05 18:11:40
|
|
6
6
|
* 版权所有:Copyright by 火星科技 http://mars3d.cn
|
|
7
7
|
* 使用单位:免费公开版 ,2024-01-15
|
|
8
8
|
*/
|
|
@@ -11,5 +11,5 @@
|
|
|
11
11
|
typeof define === 'function' && define.amd ? define(['exports', 'mapv', 'mars3d'], factory) :
|
|
12
12
|
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["mars3d-mapv"] = {}, global.mapv, global.mars3d));
|
|
13
13
|
})(this, (function (exports, mapv, mars3d) {
|
|
14
|
-
'use strict';const _0x5d17ab=_0xdc8d;function _0x5b3c(){const _0x162394=['canvas','transferCoordinate','restore','mousemoveEvent','Cesium','forEach','destroy','steps','filter','isPointVisible','Util','click','update','_data','width','12RIvMjv','6430801vszedY','auto','methods','8pVCDGd','mouseMove','fromDegrees','set','mars3d-mapv','block','__esModule','absolute','trails','308ydJZqF','top','fillStyle','558KlMGZm','removeData','map','canvasLayer','EventType','2499519tJxnrp','updateData','push','addData','geometry','dataSet','DomUtil','0px','function','mousemove','Cartesian3','_onMapClick','_size','Point','pointerEvents','length','camera','register','off','cartesianToCanvasCoordinates','mapvDepthTest','COLOR_BUFFER_BIT','cameraMoveEnd','_mapVRenderer','_onMapMouseMove','MultiPolygon','bind','init','defineProperty','Rectangle','mapvFixedHeight','_map','positionWC','context','none','isEnabledTime','535266dxKcVX','argCheck','48lugmPj','xmax','animator','mapv','_pointerEvents','MapVLayer','50YsbOBZ','getContext','getData','_reset','style','51252JSoTlx','_removedHook','211910ZAwoVt','unbindEvent','2559382xiuSIB','3516MCIClX','animatorMoveendEvent','_setOptionsHook','hasOwnProperty','clickEvent','animation','height','options','create','get','_canvasUpdate','clearRect','animatorMovestartEvent','display','initDataRange','_onMoveEndEvent','DataSet'];_0x5b3c=function(){return _0x162394;};return _0x5b3c();}(function(_0x148770,_0x3339ae){const _0x1fecc0={_0x235446:0x1a2,_0x1215b3:0x19d,_0x4d11dc:0x19f,_0x5e8016:0x192,_0x464e45:0x15b,_0x47bcf2:0x190,_0x491e63:0x198},_0x241ce9=_0xdc8d,_0x5472bd=_0x148770();while(!![]){try{const _0x5023cb=-parseInt(_0x241ce9(0x167))/0x1*(parseInt(_0x241ce9(_0x1fecc0._0x235446))/0x2)+-parseInt(_0x241ce9(_0x1fecc0._0x1215b3))/0x3*(-parseInt(_0x241ce9(0x164))/0x4)+-parseInt(_0x241ce9(_0x1fecc0._0x4d11dc))/0x5*(-parseInt(_0x241ce9(_0x1fecc0._0x5e8016))/0x6)+parseInt(_0x241ce9(0x1a1))/0x7*(-parseInt(_0x241ce9(_0x1fecc0._0x464e45))/0x8)+-parseInt(_0x241ce9(_0x1fecc0._0x47bcf2))/0x9*(parseInt(_0x241ce9(_0x1fecc0._0x491e63))/0xa)+parseInt(_0x241ce9(0x16c))/0xb+-parseInt(_0x241ce9(0x1c2))/0xc*(-parseInt(_0x241ce9(0x1c3))/0xd);if(_0x5023cb===_0x3339ae)break;else _0x5472bd['push'](_0x5472bd['shift']());}catch(_0x40313d){_0x5472bd['push'](_0x5472bd['shift']());}}}(_0x5b3c,0xb2d36));function _interopNamespace(_0x26ac0d){const _0x35b8b6={_0x47038f:0x161},_0x20d6c2={_0x4ff5d2:0x188},_0x248c76=_0xdc8d;if(_0x26ac0d&&_0x26ac0d[_0x248c76(_0x35b8b6._0x47038f)])return _0x26ac0d;var _0x5ac382=Object['create'](null);return _0x26ac0d&&Object['keys'](_0x26ac0d)['forEach'](function(_0x127c54){const _0x4b0889=_0x248c76;if(_0x127c54!=='default'){var _0x5b3019=Object['getOwnPropertyDescriptor'](_0x26ac0d,_0x127c54);Object[_0x4b0889(_0x20d6c2._0x4ff5d2)](_0x5ac382,_0x127c54,_0x5b3019['get']?_0x5b3019:{'enumerable':!![],'get':function(){return _0x26ac0d[_0x127c54];}});}}),_0x5ac382['default']=_0x26ac0d,_0x5ac382;}var mapv__namespace=_interopNamespace(mapv),mars3d__namespace=_interopNamespace(mars3d);const Cesium$1=mars3d__namespace[_0x5d17ab(0x1b7)],baiduMapLayer=mapv__namespace?mapv__namespace['baiduMapLayer']:null,BaseLayer$1=baiduMapLayer?baiduMapLayer['__proto__']:Function;class MapVRenderer extends BaseLayer$1{constructor(_0x5e03ae,_0x1516c7,_0x3e6182,_0x1b13d4){const _0x262fe8={_0x1fc1a0:0x191,_0x315928:0x1a7},_0x45c781=_0x5d17ab;super(_0x5e03ae,_0x1516c7,_0x3e6182);if(!BaseLayer$1)return;this[_0x45c781(0x169)]=_0x5e03ae,this['scene']=_0x5e03ae['scene'],this['dataSet']=_0x1516c7,_0x3e6182=_0x3e6182||{},this['init'](_0x3e6182),this[_0x45c781(_0x262fe8._0x1fc1a0)](_0x3e6182),this['initDevicePixelRatio'](),this['canvasLayer']=_0x1b13d4,this['stopAniamation']=!0x1,this[_0x45c781(_0x262fe8._0x315928)]=_0x3e6182['animation'];}['initDevicePixelRatio'](){this['devicePixelRatio']=window['devicePixelRatio']||0x1;}['addAnimatorEvent'](){}['animatorMovestartEvent'](){const _0x59a9ea=_0x5d17ab,_0x47590f=this['options']['animation'];this['isEnabledTime']()&&this[_0x59a9ea(0x194)]&&(this[_0x59a9ea(0x1ba)]['step']=_0x47590f['stepsRange']['start']);}[_0x5d17ab(0x1a3)](){const _0x165d1b=_0x5d17ab;this[_0x165d1b(0x18f)]()&&this[_0x165d1b(0x194)];}['getContext'](){const _0x3efa7d=_0x5d17ab;return this[_0x3efa7d(0x16a)]['canvas']['getContext'](this['context']);}[_0x5d17ab(0x187)](_0x139ed3){const _0x2855d4=_0x5d17ab;this['options']=_0x139ed3,this[_0x2855d4(0x1b0)](_0x139ed3),this['context']=this['options']['context']||'2d',Cesium$1['defined'](this['options']['zIndex'])&&this['canvasLayer']&&this['canvasLayer']['setZIndex']&&this['canvasLayer']['setZIndex'](this['options']['zIndex']),this['initAnimator']();}[_0x5d17ab(0x1ac)](_0x34b28f){const _0x252889={_0x4ea08f:0x199,_0x21ea89:0x1b5,_0x12c7f:0x178},_0x40c878={_0x2366af:0x18a,_0x21f231:0x176,_0x51d1e0:0x17f},_0x219af5=_0x5d17ab,_0x585156=this['scene'];if(this['canvasLayer']&&!this['stopAniamation']){const _0x161cfd=this[_0x219af5(0x1a9)]['animation'],_0x539f09=this[_0x219af5(_0x252889._0x4ea08f)]();if(this['isEnabledTime']()){if(void 0x0===_0x34b28f)return void this['clear'](_0x539f09);this['context']==='2d'&&(_0x539f09['save'](),_0x539f09['globalCompositeOperation']='destination-out',_0x539f09[_0x219af5(0x166)]='rgba(0,\x200,\x200,\x20.1)',_0x539f09['fillRect'](0x0,0x0,_0x539f09['canvas']['width'],_0x539f09['canvas']['height']),_0x539f09[_0x219af5(_0x252889._0x21ea89)]());}else this['clear'](_0x539f09);if(this['context']==='2d')for(const _0x54421f in this['options']){_0x539f09[_0x54421f]=this[_0x219af5(0x1a9)][_0x54421f];}else _0x539f09['clear'](_0x539f09[_0x219af5(0x181)]);const _0xac00b5={'transferCoordinate':function(_0x528504){const _0x51d99b=_0x219af5,_0x102647=null;let _0x24dbfb=_0x585156[_0x51d99b(_0x40c878._0x2366af)];_0x585156['mapvAutoHeight']&&(_0x24dbfb=_0x585156['getHeight'](Cesium$1['Cartographic'][_0x51d99b(0x15d)](_0x528504[0x0],_0x528504[0x1])));const _0x55424a=Cesium$1[_0x51d99b(_0x40c878._0x21f231)]['fromDegrees'](_0x528504[0x0],_0x528504[0x1],_0x24dbfb);if(!_0x55424a)return _0x102647;const _0x22f85a=_0x585156[_0x51d99b(_0x40c878._0x51d1e0)](_0x55424a);if(!_0x22f85a)return _0x102647;if(_0x585156['mapvDepthTest']&&_0x585156['mode']===Cesium$1['SceneMode']['SCENE3D']){const _0x9c4005=new Cesium$1['EllipsoidalOccluder'](_0x585156['globe']['ellipsoid'],_0x585156[_0x51d99b(0x17c)][_0x51d99b(0x18c)]),_0xdc3597=_0x9c4005[_0x51d99b(0x1bc)](_0x55424a);if(!_0xdc3597)return _0x102647;}return[_0x22f85a['x'],_0x22f85a['y']];}};void 0x0!==_0x34b28f&&(_0xac00b5[_0x219af5(0x1bb)]=function(_0x1682ca){const _0x2f4da0=_0x219af5,_0x2b8599=_0x161cfd[_0x2f4da0(0x163)]||0xa;return!!(_0x34b28f&&_0x1682ca['time']>_0x34b28f-_0x2b8599&&_0x1682ca['time']<_0x34b28f);});const _0x4e099e=this['dataSet']['get'](_0xac00b5);this['processData'](_0x4e099e),this['options']['unit']==='m'&&this['options']['size'],this['options'][_0x219af5(_0x252889._0x12c7f)]=this['options']['size'];const _0x28dfba=_0x585156['cartesianToCanvasCoordinates'](Cesium$1['Cartesian3']['fromDegrees'](0x0,0x0));if(!_0x28dfba)return;this['drawContext'](_0x539f09,new mapv__namespace['DataSet'](_0x4e099e),this['options'],_0x28dfba),this['options']['updateCallback']&&this[_0x219af5(0x1a9)]['updateCallback'](_0x34b28f);}}['updateData'](_0xd2e4f7,_0x5acd3d){const _0x452e15=_0x5d17ab;let _0x2c45b6=_0xd2e4f7;_0x2c45b6&&_0x2c45b6['get']&&(_0x2c45b6=_0x2c45b6['get']()),void 0x0!==_0x2c45b6&&this[_0x452e15(0x171)]['set'](_0x2c45b6),super['update']({'options':_0x5acd3d});}['addData'](_0x149c09,_0x12ee7a){const _0x4f754c={_0x3d7409:0x1bf},_0x22c006=_0x5d17ab;let _0x126f7a=_0x149c09;_0x149c09&&_0x149c09[_0x22c006(0x1ab)]&&(_0x126f7a=_0x149c09['get']()),this['dataSet']['add'](_0x126f7a),this[_0x22c006(_0x4f754c._0x3d7409)]({'options':_0x12ee7a});}['getData'](){return this['dataSet'];}['removeData'](_0x5e948d){const _0x145a4c=_0x5d17ab;if(this['dataSet']){const _0x266d09=this[_0x145a4c(0x171)]['get']({'filter':function(_0x28655f){const _0x347f02=_0x145a4c;return _0x5e948d==null||typeof _0x5e948d!==_0x347f02(0x174)||!_0x5e948d(_0x28655f);}});this['dataSet'][_0x145a4c(0x15e)](_0x266d09),this['update']({'options':null});}}['clearData'](){const _0xcd0815=_0x5d17ab;this['dataSet']&&this[_0xcd0815(0x171)]['clear'](),this['update']({'options':null});}['draw'](){this['canvasLayer']['draw']();}['clear'](_0x45d828){const _0x4e85ae={_0xea3333:0x1ad},_0x26c94c=_0x5d17ab;_0x45d828&&_0x45d828[_0x26c94c(_0x4e85ae._0xea3333)]&&_0x45d828[_0x26c94c(0x1ad)](0x0,0x0,_0x45d828['canvas'][_0x26c94c(0x1c1)],_0x45d828['canvas'][_0x26c94c(0x1a8)]);}['destroy'](){const _0x489243={_0x387267:0x194},_0xae023a=_0x5d17ab;this['clear'](this['getContext']()),this['clearData'](),this['animator']&&this['animator']['stop'](),this[_0xae023a(_0x489243._0x387267)]=null,this[_0xae023a(0x16a)]=null;}}if(mapv__namespace!==null&&mapv__namespace!==void 0x0&&mapv__namespace['DataSet'])mapv__namespace['DataSet']['prototype'][_0x5d17ab(0x1b4)]=function(_0x11e8f5,_0x252402,_0x69489e,_0x479cc1){const _0x3d56a9={_0x9c4c11:0x170,_0x27baaf:0x179,_0x52aa63:0x16e},_0x3ecca2={_0x53866d:0x16e},_0x36fb87=_0x5d17ab;_0x479cc1=_0x479cc1||'_coordinates',_0x69489e=_0x69489e||'coordinates';for(let _0x304c43=0x0;_0x304c43<_0x11e8f5['length'];_0x304c43++){const _0x43121c=_0x11e8f5[_0x304c43][_0x36fb87(_0x3d56a9._0x9c4c11)],_0x101f84=_0x43121c[_0x69489e];switch(_0x43121c['type']){case _0x36fb87(_0x3d56a9._0x27baaf):{const _0x41263b=_0x252402(_0x101f84);_0x41263b?_0x43121c[_0x479cc1]=_0x41263b:_0x43121c[_0x479cc1]=[-0x3e7,-0x3e7];}break;case'LineString':{const _0x34a24c=[];for(let _0x4338f1=0x0;_0x4338f1<_0x101f84['length'];_0x4338f1++){const _0x2d986b=_0x252402(_0x101f84[_0x4338f1]);_0x2d986b&&_0x34a24c[_0x36fb87(0x16e)](_0x2d986b);}_0x43121c[_0x479cc1]=_0x34a24c;}break;case'MultiLineString':case'Polygon':{const _0x2d0142=_0x493e4a(_0x101f84);_0x43121c[_0x479cc1]=_0x2d0142;}break;case _0x36fb87(0x185):{const _0x176c3a=[];for(let _0x2c4df0=0x0;_0x2c4df0<_0x101f84[_0x36fb87(0x17b)];_0x2c4df0++){const _0x40f012=_0x493e4a(_0x101f84[_0x2c4df0]);_0x40f012['length']>0x0&&_0x176c3a[_0x36fb87(_0x3d56a9._0x52aa63)](_0x40f012);}_0x43121c[_0x479cc1]=_0x176c3a;}break;}}function _0x493e4a(_0x1db71c){const _0x18e617=_0x36fb87,_0x1d7046=[];for(let _0xcd7c66=0x0;_0xcd7c66<_0x1db71c[_0x18e617(0x17b)];_0xcd7c66++){const _0x4e2c98=_0x1db71c[_0xcd7c66],_0x2f5605=[];for(let _0x24e11d=0x0;_0x24e11d<_0x4e2c98[_0x18e617(0x17b)];_0x24e11d++){const _0x45ee61=_0x252402(_0x4e2c98[_0x24e11d]);_0x45ee61&&_0x2f5605[_0x18e617(_0x3ecca2._0x53866d)](_0x45ee61);}_0x2f5605[_0x18e617(0x17b)]>0x0&&_0x1d7046['push'](_0x2f5605);}return _0x1d7046;}return _0x11e8f5;};else throw new Error('请引入\x20mapv\x20库\x20');function _0xdc8d(_0x173e89,_0x1a2816){const _0x5b3ca3=_0x5b3c();return _0xdc8d=function(_0xdc8d86,_0x84cb7e){_0xdc8d86=_0xdc8d86-0x159;let _0x461d24=_0x5b3ca3[_0xdc8d86];return _0x461d24;},_0xdc8d(_0x173e89,_0x1a2816);}const Cesium=mars3d__namespace['Cesium'],BaseLayer=mars3d__namespace['layer']['BaseLayer'];class MapVLayer extends BaseLayer{constructor(_0x2497e3,_0x187e2c){const _0x2309f8=_0x5d17ab;super(_0x2497e3),this[_0x2309f8(0x196)]=this['options']['pointerEvents'],this['dataSet']=_0x187e2c||new mapv__namespace[(_0x2309f8(0x1b2))](_0x2497e3['data']),this['canvas']=null;}get[_0x5d17ab(0x17a)](){return this['_pointerEvents'];}set[_0x5d17ab(0x17a)](_0x4ab1df){const _0x55dfae={_0x5c9cfa:0x17a},_0x1cf990=_0x5d17ab;this['_pointerEvents']=_0x4ab1df,this[_0x1cf990(0x1b3)]&&(_0x4ab1df?this['canvas']['style']['pointerEvents']='all':this['canvas']['style'][_0x1cf990(_0x55dfae._0x5c9cfa)]=_0x1cf990(0x18e));}['_showHook'](_0x1111cc){const _0x4e49c1={_0x4214fb:0x160,_0x14d2d2:0x1b3},_0x159721=_0x5d17ab;_0x1111cc?this[_0x159721(0x1b3)]['style']['display']=_0x159721(_0x4e49c1._0x4214fb):this[_0x159721(_0x4e49c1._0x14d2d2)]['style'][_0x159721(0x1af)]='none';}['_mountedHook'](){const _0x181fd7=_0x5d17ab;this['_map']['scene'][_0x181fd7(0x180)]=this['options']['depthTest']??!![],this[_0x181fd7(0x18b)]['scene']['mapvAutoHeight']=this['options']['clampToGround']??![],this['_map']['scene'][_0x181fd7(0x18a)]=this['options']['fixedHeight']??0x0;}['_addedHook'](){const _0x2ec8f9={_0x1f867c:0x1c0,_0xc68135:0x1a9},_0x4f3034=_0x5d17ab;this['dataSet']&&(!this['dataSet']['_data']||this['dataSet'][_0x4f3034(_0x2ec8f9._0x1f867c)]['length']===0x0)&&(this['dataSet']['_data']=[]['concat'](this['dataSet']['_dataCache'])),this['_mapVRenderer']=new MapVRenderer(this['_map'],this['dataSet'],this[_0x4f3034(_0x2ec8f9._0xc68135)],this),this['initDevicePixelRatio'](),this['canvas']=this['_createCanvas'](),this['render']=this['render'][_0x4f3034(0x186)](this),this['bindEvent'](),this['_reset']();}[_0x5d17ab(0x19e)](){this['unbindEvent'](),this['_mapVRenderer']&&(this['_mapVRenderer']['destroy'](),this['_mapVRenderer']=null),this['canvas']['parentElement']['removeChild'](this['canvas']);}['initDevicePixelRatio'](){this['devicePixelRatio']=window['devicePixelRatio']||0x1;}['bindEvent'](){const _0x179663={_0x23bbaf:0x1a9,_0x27257e:0x1be,_0x265e66:0x15a,_0x32ea84:0x16b,_0x59ff23:0x184},_0xd97bff=_0x5d17ab;var _0x3b339b,_0xce0569;this['_map']['on'](mars3d__namespace['EventType']['mouseDown'],this['_onMoveStartEvent'],this),this['_map']['on'](mars3d__namespace['EventType']['cameraMoveStart'],this['_onMoveStartEvent'],this),this['_map']['on'](mars3d__namespace['EventType'][_0xd97bff(0x182)],this['_onMoveEndEvent'],this),(_0x3b339b=this[_0xd97bff(_0x179663._0x23bbaf)])!==null&&_0x3b339b!==void 0x0&&(_0x3b339b=_0x3b339b['methods'])!==null&&_0x3b339b!==void 0x0&&_0x3b339b[_0xd97bff(_0x179663._0x27257e)]&&this['_map']['on'](mars3d__namespace['EventType']['click'],this['_onMapClick'],this),(_0xce0569=this['options'])!==null&&_0xce0569!==void 0x0&&(_0xce0569=_0xce0569[_0xd97bff(_0x179663._0x265e66)])!==null&&_0xce0569!==void 0x0&&_0xce0569['mousemove']&&this['_map']['on'](mars3d__namespace[_0xd97bff(_0x179663._0x32ea84)]['mouseMove'],this[_0xd97bff(_0x179663._0x59ff23)],this);}[_0x5d17ab(0x1a0)](){const _0x22f7bf={_0x26cbad:0x18b,_0x21c52d:0x18b,_0x1149cf:0x17e,_0x53025c:0x16b,_0x527ae9:0x19b,_0x5cbee3:0x175},_0x2f2ec6=_0x5d17ab;var _0x2af4a6,_0x2763e5;this['_map']['off'](mars3d__namespace['EventType']['mouseDown'],this['_onMoveStartEvent'],this),this[_0x2f2ec6(_0x22f7bf._0x26cbad)]['off'](mars3d__namespace[_0x2f2ec6(0x16b)]['cameraMoveStart'],this['_onMoveStartEvent'],this),this[_0x2f2ec6(_0x22f7bf._0x21c52d)][_0x2f2ec6(_0x22f7bf._0x1149cf)](mars3d__namespace['EventType']['cameraMoveEnd'],this[_0x2f2ec6(0x1b1)],this),this['_map'][_0x2f2ec6(0x17e)](mars3d__namespace[_0x2f2ec6(_0x22f7bf._0x53025c)]['postRender'],this[_0x2f2ec6(_0x22f7bf._0x527ae9)],this),(_0x2af4a6=this['options'])!==null&&_0x2af4a6!==void 0x0&&(_0x2af4a6=_0x2af4a6[_0x2f2ec6(0x15a)])!==null&&_0x2af4a6!==void 0x0&&_0x2af4a6['click']&&this['_map']['off'](mars3d__namespace['EventType']['click'],this[_0x2f2ec6(0x177)],this),(_0x2763e5=this['options'])!==null&&_0x2763e5!==void 0x0&&(_0x2763e5=_0x2763e5['methods'])!==null&&_0x2763e5!==void 0x0&&_0x2763e5[_0x2f2ec6(_0x22f7bf._0x5cbee3)]&&this['_map'][_0x2f2ec6(0x17e)](mars3d__namespace[_0x2f2ec6(_0x22f7bf._0x53025c)]['mouseMove'],this['_onMapMouseMove'],this);}['_onMoveStartEvent'](){const _0x245e8f={_0x43cb12:0x1ae,_0x5b8ce9:0x19b},_0x500851=_0x5d17ab;this['_mapVRenderer']&&(this[_0x500851(0x183)][_0x500851(_0x245e8f._0x43cb12)](),this['_map']['off'](mars3d__namespace[_0x500851(0x16b)]['postRender'],this[_0x500851(_0x245e8f._0x5b8ce9)],this),this['_map']['on'](mars3d__namespace['EventType']['postRender'],this[_0x500851(_0x245e8f._0x5b8ce9)],this));}[_0x5d17ab(0x1b1)](){const _0xdc5668={_0x51a9ad:0x16b},_0xc0937d=_0x5d17ab;this['_mapVRenderer']&&(this[_0xc0937d(0x18b)]['off'](mars3d__namespace[_0xc0937d(_0xdc5668._0x51a9ad)]['postRender'],this['_reset'],this),this[_0xc0937d(0x183)][_0xc0937d(0x1a3)](),this['_reset']());}[_0x5d17ab(0x1a4)](_0x474ddb,_0x56073a){this['_removedHook'](),this['_addedHook']();}[_0x5d17ab(0x16f)](_0x2ea9ff){this['_mapVRenderer']&&this['_mapVRenderer']['addData'](_0x2ea9ff,this['options']);}[_0x5d17ab(0x16d)](_0x26b047){const _0x128fe7={_0x29e098:0x183},_0x3e5d0b=_0x5d17ab;this['_mapVRenderer']&&this[_0x3e5d0b(_0x128fe7._0x29e098)]['updateData'](_0x26b047,this[_0x3e5d0b(0x1a9)]);}[_0x5d17ab(0x19a)](){const _0x581d3c={_0x2382c9:0x171},_0x3665ac=_0x5d17ab;return this['_mapVRenderer']&&(this[_0x3665ac(_0x581d3c._0x2382c9)]=this['_mapVRenderer']['getData']()),this['dataSet'];}[_0x5d17ab(0x168)](_0x4e6dff){const _0xe8a244=_0x5d17ab;this[_0xe8a244(0x183)]&&this['_mapVRenderer']['removeData'](_0x4e6dff);}['removeAllData'](){const _0x3f9fea={_0x25bf98:0x183},_0x228a10=_0x5d17ab;this['_mapVRenderer']&&this[_0x228a10(_0x3f9fea._0x25bf98)]['clearData']();}['_createCanvas'](){const _0x236b53={_0x439212:0x172,_0x18bf48:0x15f,_0x355320:0x162,_0x3620ae:0x19c,_0x4de46d:0x173,_0x477480:0x19c,_0x256d5b:0x18b,_0x4a51a5:0x1a8,_0x262e3c:0x159,_0x2bc23e:0x18d},_0x3f862d=_0x5d17ab,_0x358f42=mars3d__namespace[_0x3f862d(_0x236b53._0x439212)][_0x3f862d(0x1aa)]('canvas',_0x3f862d(_0x236b53._0x18bf48),this['_map']['container']);_0x358f42['id']=this['id'],_0x358f42['style']['position']=_0x3f862d(_0x236b53._0x355320),_0x358f42[_0x3f862d(_0x236b53._0x3620ae)][_0x3f862d(0x165)]='0px',_0x358f42['style']['left']=_0x3f862d(_0x236b53._0x4de46d),_0x358f42['width']=parseInt(this['_map']['canvas']['width']),_0x358f42['height']=parseInt(this['_map']['canvas']['height']),_0x358f42[_0x3f862d(_0x236b53._0x477480)]['width']=this[_0x3f862d(_0x236b53._0x256d5b)]['canvas']['style'][_0x3f862d(0x1c1)],_0x358f42['style']['height']=this[_0x3f862d(_0x236b53._0x256d5b)]['canvas']['style'][_0x3f862d(_0x236b53._0x4a51a5)],_0x358f42['style'][_0x3f862d(0x17a)]=this['_pointerEvents']?_0x3f862d(_0x236b53._0x262e3c):'none',_0x358f42['style']['zIndex']=this['options']['zIndex']??0x9;if(this['options'][_0x3f862d(_0x236b53._0x2bc23e)]==='2d'){const _0x51f4e1=this['devicePixelRatio'];_0x358f42['getContext'](this['options'][_0x3f862d(0x18d)])['scale'](_0x51f4e1,_0x51f4e1);}return _0x358f42;}['_reset'](){this['resize'](),this['render']();}['draw'](){this['_reset']();}['remove'](){const _0x365726={_0x59a0e1:0x183},_0x1c58eb=_0x5d17ab;this['_mapVRenderer']&&(this[_0x1c58eb(_0x365726._0x59a0e1)][_0x1c58eb(0x1b9)](),this['_mapVRenderer']=null),this['canvas']['parentElement']['removeChild'](this['canvas']);}['render'](){const _0x5613e1=_0x5d17ab;this[_0x5613e1(0x183)]['_canvasUpdate']();}['resize'](){const _0x532e93={_0x54bb19:0x165,_0x2c2406:0x1b3},_0x34925e=_0x5d17ab;if(this['canvas']){const _0x95bfb=this['canvas'];_0x95bfb[_0x34925e(0x19c)]['position']=_0x34925e(0x162),_0x95bfb[_0x34925e(0x19c)][_0x34925e(_0x532e93._0x54bb19)]='0px',_0x95bfb[_0x34925e(0x19c)]['left']='0px',_0x95bfb['width']=parseInt(this['_map']['canvas']['width']),_0x95bfb['height']=parseInt(this['_map']['canvas']['height']),_0x95bfb['style'][_0x34925e(0x1c1)]=this['_map'][_0x34925e(0x1b3)]['style']['width'],_0x95bfb['style']['height']=this['_map'][_0x34925e(_0x532e93._0x2c2406)]['style']['height'];}}['getRectangle'](_0xa46d29){const _0x10b689={_0x28ef07:0x171},_0x52b1f2=_0x5d17ab;if(!this['dataSet']||!this[_0x52b1f2(_0x10b689._0x28ef07)]['_data'])return;const _0x1b4be0=mars3d__namespace[_0x52b1f2(0x1bd)]['getExtentByGeoJSON']({'type':'FeatureCollection','features':this['dataSet']['_data']});if(!_0x1b4be0)return;return _0xa46d29!==null&&_0xa46d29!==void 0x0&&_0xa46d29['isFormat']?_0x1b4be0:Cesium[_0x52b1f2(0x189)]['fromDegrees'](_0x1b4be0['xmin'],_0x1b4be0['ymin'],_0x1b4be0[_0x52b1f2(0x193)],_0x1b4be0['ymax']);}[_0x5d17ab(0x177)](_0x1fd6fd){const _0x188e87=_0x5d17ab;this['_cache_event']=_0x1fd6fd,this[_0x188e87(0x183)]&&this['_mapVRenderer'][_0x188e87(0x1a6)](_0x1fd6fd['windowPosition'],_0x1fd6fd);}['_onMapMouseMove'](_0x5947ad){const _0x22f1b9={_0x10625e:0x183},_0x2c57bc=_0x5d17ab;this['_cache_event']=_0x5947ad,this[_0x2c57bc(_0x22f1b9._0x10625e)]&&this['_mapVRenderer'][_0x2c57bc(0x1b6)](_0x5947ad['windowPosition'],_0x5947ad);}['on'](_0x319abf,_0x23d1a8,_0xa60788){const _0x2786ac={_0x3b8575:0x1a9,_0x1ec59e:0x1be,_0x5663af:0x15a,_0x46b194:0x16b},_0x12eed5=_0x5d17ab;this['options']['methods']=this[_0x12eed5(_0x2786ac._0x3b8575)][_0x12eed5(0x15a)]||{};if(_0x319abf===mars3d__namespace['EventType'][_0x12eed5(_0x2786ac._0x1ec59e)])this['options'][_0x12eed5(_0x2786ac._0x5663af)]['click']=_0x2c8153=>{_0x2c8153&&_0x23d1a8['bind'](_0xa60788)({...this['_cache_event'],'layer':this,'data':_0x2c8153});},this['_map']['on'](mars3d__namespace[_0x12eed5(_0x2786ac._0x46b194)]['click'],this['_onMapClick'],this);else _0x319abf===mars3d__namespace['EventType']['mouseMove']&&(this['options'][_0x12eed5(_0x2786ac._0x5663af)]['mousemove']=_0x1616f7=>{_0x1616f7&&_0x23d1a8['bind'](_0xa60788)({...this['_cache_event'],'layer':this,'data':_0x1616f7});},this['_map']['on'](mars3d__namespace['EventType'][_0x12eed5(0x15c)],this['_onMapMouseMove'],this));return this;}['off'](_0x618d6,_0x1b2bb1){const _0x3f34ae={_0xcf7b06:0x1be,_0x5839cd:0x15c},_0x53aae5=_0x5d17ab;if(_0x618d6==='click'){var _0x360a48;this['_map']['off'](_0x618d6,this['_onMapClick'],this),(_0x360a48=this['options']['methods'])!==null&&_0x360a48!==void 0x0&&_0x360a48['mousemove']&&delete this[_0x53aae5(0x1a9)]['methods'][_0x53aae5(_0x3f34ae._0xcf7b06)];}else{if(_0x618d6===_0x53aae5(_0x3f34ae._0x5839cd)){var _0x500ffc;this['_map']['off'](_0x618d6,this[_0x53aae5(0x184)],this),(_0x500ffc=this['options']['methods'])!==null&&_0x500ffc!==void 0x0&&_0x500ffc['mousemove']&&delete this['options']['methods']['mousemove'];}}return this;}}mars3d__namespace['LayerUtil'][_0x5d17ab(0x17d)](_0x5d17ab(0x195),MapVLayer),mars3d__namespace['layer']['MapVLayer']=MapVLayer,mars3d__namespace['mapv']=mapv__namespace,exports[_0x5d17ab(0x197)]=MapVLayer,Object['keys'](mapv)[_0x5d17ab(0x1b8)](function(_0x5e4a49){const _0x162a89={_0x4076c7:0x1a5,_0x9d05e:0x188},_0x52833c=_0x5d17ab;if(_0x5e4a49!=='default'&&!exports[_0x52833c(_0x162a89._0x4076c7)](_0x5e4a49))Object[_0x52833c(_0x162a89._0x9d05e)](exports,_0x5e4a49,{'enumerable':!![],'get':function(){return mapv[_0x5e4a49];}});}),Object['defineProperty'](exports,'__esModule',{'value':!![]});
|
|
14
|
+
'use strict';const _0x17fe2d=_0xca22;(function(_0x3b6e79,_0x384c61){const _0x4a3e57={_0x3ca348:0x1e6,_0x3eef9e:0x1df,_0xdebeef:0x1e5,_0x18951d:0x1bc,_0x1c94a7:0x1b9},_0x5802e1=_0xca22,_0xe34ed2=_0x3b6e79();while(!![]){try{const _0xa092cf=parseInt(_0x5802e1(_0x4a3e57._0x3ca348))/0x1*(parseInt(_0x5802e1(0x1c6))/0x2)+parseInt(_0x5802e1(_0x4a3e57._0x3eef9e))/0x3*(-parseInt(_0x5802e1(0x1e2))/0x4)+-parseInt(_0x5802e1(0x19d))/0x5+parseInt(_0x5802e1(0x1bf))/0x6+parseInt(_0x5802e1(_0x4a3e57._0xdebeef))/0x7*(-parseInt(_0x5802e1(0x19a))/0x8)+parseInt(_0x5802e1(_0x4a3e57._0x18951d))/0x9*(-parseInt(_0x5802e1(_0x4a3e57._0x1c94a7))/0xa)+parseInt(_0x5802e1(0x19e))/0xb;if(_0xa092cf===_0x384c61)break;else _0xe34ed2['push'](_0xe34ed2['shift']());}catch(_0x6e0ccc){_0xe34ed2['push'](_0xe34ed2['shift']());}}}(_0x28b4,0xc044b));function _interopNamespace(_0xbedbf6){const _0x2c0c40={_0x5d0671:0x1eb},_0x28880d=_0xca22;if(_0xbedbf6&&_0xbedbf6['__esModule'])return _0xbedbf6;var _0x54d60b=Object['create'](null);return _0xbedbf6&&Object['keys'](_0xbedbf6)['forEach'](function(_0xd00404){const _0x1b1008=_0xca22;if(_0xd00404!==_0x1b1008(0x1eb)){var _0x1389fd=Object['getOwnPropertyDescriptor'](_0xbedbf6,_0xd00404);Object['defineProperty'](_0x54d60b,_0xd00404,_0x1389fd[_0x1b1008(0x1d1)]?_0x1389fd:{'enumerable':!![],'get':function(){return _0xbedbf6[_0xd00404];}});}}),_0x54d60b[_0x28880d(_0x2c0c40._0x5d0671)]=_0xbedbf6,_0x54d60b;}var mapv__namespace=_interopNamespace(mapv),mars3d__namespace=_interopNamespace(mars3d);const Cesium$1=mars3d__namespace['Cesium'],baiduMapLayer=mapv__namespace?mapv__namespace['baiduMapLayer']:null,BaseLayer$1=baiduMapLayer?baiduMapLayer['__proto__']:Function;class MapVRenderer extends BaseLayer$1{constructor(_0x244c7a,_0x185fae,_0x49b3e1,_0x365a02){const _0x2b88b2={_0x25a26b:0x1cf},_0x2b35b5=_0xca22;super(_0x244c7a,_0x185fae,_0x49b3e1);if(!BaseLayer$1)return;this[_0x2b35b5(0x1de)]=_0x244c7a,this['scene']=_0x244c7a[_0x2b35b5(0x1dc)],this['dataSet']=_0x185fae,_0x49b3e1=_0x49b3e1||{},this['init'](_0x49b3e1),this['argCheck'](_0x49b3e1),this['initDevicePixelRatio'](),this['canvasLayer']=_0x365a02,this['stopAniamation']=!0x1,this[_0x2b35b5(_0x2b88b2._0x25a26b)]=_0x49b3e1[_0x2b35b5(_0x2b88b2._0x25a26b)];}['initDevicePixelRatio'](){const _0x3b2efa=_0xca22;this[_0x3b2efa(0x197)]=window['devicePixelRatio']||0x1;}['addAnimatorEvent'](){}[_0x17fe2d(0x1be)](){const _0x206e18={_0x2f51e1:0x1c2,_0x230995:0x19b},_0x9ef1df=_0x17fe2d,_0x3b1531=this['options']['animation'];this['isEnabledTime']()&&this[_0x9ef1df(_0x206e18._0x2f51e1)]&&(this['steps'][_0x9ef1df(_0x206e18._0x230995)]=_0x3b1531[_0x9ef1df(0x1ec)]['start']);}[_0x17fe2d(0x191)](){const _0x18d0e6={_0x8c5168:0x1c2},_0x374b39=_0x17fe2d;this['isEnabledTime']()&&this[_0x374b39(_0x18d0e6._0x8c5168)];}[_0x17fe2d(0x1af)](){const _0x153493=_0x17fe2d;return this['canvasLayer']['canvas'][_0x153493(0x1af)](this['context']);}['init'](_0x1d940d){const _0x3c28c6={_0x1f9ba9:0x1b3,_0x49b282:0x1ea,_0x3e4d52:0x1d4,_0x498694:0x1cd,_0x1d43ee:0x1ef,_0x545be6:0x1ef},_0x15bfde=_0x17fe2d;this[_0x15bfde(_0x3c28c6._0x1f9ba9)]=_0x1d940d,this[_0x15bfde(_0x3c28c6._0x49b282)](_0x1d940d),this['context']=this[_0x15bfde(_0x3c28c6._0x1f9ba9)][_0x15bfde(_0x3c28c6._0x3e4d52)]||'2d',Cesium$1[_0x15bfde(0x1b1)](this['options'][_0x15bfde(0x1a3)])&&this[_0x15bfde(_0x3c28c6._0x498694)]&&this['canvasLayer'][_0x15bfde(_0x3c28c6._0x1d43ee)]&&this[_0x15bfde(0x1cd)][_0x15bfde(_0x3c28c6._0x545be6)](this['options']['zIndex']),this['initAnimator']();}[_0x17fe2d(0x1d2)](_0x3ba37f){const _0x1c06ca={_0x2c7de5:0x1cd,_0x24c1f5:0x1af,_0x5cdb4e:0x190,_0x456638:0x1e4,_0x4e2265:0x194,_0x3da82a:0x1d4,_0x500f65:0x18f,_0x4abc23:0x1b3,_0x1c45c1:0x1a7,_0x2aff0f:0x1b5},_0xdc4071={_0xcfc0e1:0x1ab,_0x4ec5a0:0x1d0},_0x27efe7=_0x17fe2d,_0x12face=this['scene'];if(this[_0x27efe7(_0x1c06ca._0x2c7de5)]&&!this[_0x27efe7(0x1c4)]){const _0x486a95=this['options']['animation'],_0x1a6f5b=this[_0x27efe7(_0x1c06ca._0x24c1f5)]();if(this['isEnabledTime']()){if(void 0x0===_0x3ba37f)return void this['clear'](_0x1a6f5b);this['context']==='2d'&&(_0x1a6f5b['save'](),_0x1a6f5b['globalCompositeOperation']=_0x27efe7(_0x1c06ca._0x5cdb4e),_0x1a6f5b[_0x27efe7(_0x1c06ca._0x456638)]='rgba(0,\x200,\x200,\x20.1)',_0x1a6f5b['fillRect'](0x0,0x0,_0x1a6f5b[_0x27efe7(0x194)]['width'],_0x1a6f5b[_0x27efe7(_0x1c06ca._0x4e2265)]['height']),_0x1a6f5b['restore']());}else this['clear'](_0x1a6f5b);if(this[_0x27efe7(_0x1c06ca._0x3da82a)]==='2d')for(const _0x5df9d7 in this['options']){_0x1a6f5b[_0x5df9d7]=this['options'][_0x5df9d7];}else _0x1a6f5b['clear'](_0x1a6f5b['COLOR_BUFFER_BIT']);const _0x433917={'transferCoordinate':function(_0x318f66){const _0x4ef0eb=_0x27efe7,_0x5d55a9=null;let _0x5415b6=_0x12face[_0x4ef0eb(_0xdc4071._0xcfc0e1)];_0x12face['mapvAutoHeight']&&(_0x5415b6=_0x12face['getHeight'](Cesium$1['Cartographic'][_0x4ef0eb(_0xdc4071._0x4ec5a0)](_0x318f66[0x0],_0x318f66[0x1])));const _0x93d1fa=Cesium$1['Cartesian3'][_0x4ef0eb(_0xdc4071._0x4ec5a0)](_0x318f66[0x0],_0x318f66[0x1],_0x5415b6);if(!_0x93d1fa)return _0x5d55a9;const _0x57a8a2=_0x12face['cartesianToCanvasCoordinates'](_0x93d1fa);if(!_0x57a8a2)return _0x5d55a9;if(_0x12face[_0x4ef0eb(0x1d3)]&&_0x12face['mode']===Cesium$1[_0x4ef0eb(0x1e0)]['SCENE3D']){const _0x448fc7=new Cesium$1['EllipsoidalOccluder'](_0x12face['globe']['ellipsoid'],_0x12face[_0x4ef0eb(0x1a0)]['positionWC']),_0x44498a=_0x448fc7['isPointVisible'](_0x93d1fa);if(!_0x44498a)return _0x5d55a9;}return[_0x57a8a2['x'],_0x57a8a2['y']];}};void 0x0!==_0x3ba37f&&(_0x433917[_0x27efe7(_0x1c06ca._0x500f65)]=function(_0x1c704b){const _0x37e04a=_0x486a95['trails']||0xa;return!!(_0x3ba37f&&_0x1c704b['time']>_0x3ba37f-_0x37e04a&&_0x1c704b['time']<_0x3ba37f);});const _0x448235=this['dataSet']['get'](_0x433917);this['processData'](_0x448235),this['options']['unit']==='m'&&this[_0x27efe7(_0x1c06ca._0x4abc23)]['size'],this['options']['_size']=this['options']['size'];const _0x5db98f=_0x12face['cartesianToCanvasCoordinates'](Cesium$1['Cartesian3']['fromDegrees'](0x0,0x0));if(!_0x5db98f)return;this['drawContext'](_0x1a6f5b,new mapv__namespace[(_0x27efe7(_0x1c06ca._0x1c45c1))](_0x448235),this['options'],_0x5db98f),this[_0x27efe7(0x1b3)][_0x27efe7(0x1b5)]&&this['options'][_0x27efe7(_0x1c06ca._0x2aff0f)](_0x3ba37f);}}[_0x17fe2d(0x1c7)](_0x3e2fed,_0x2b0b73){let _0x32afe8=_0x3e2fed;_0x32afe8&&_0x32afe8['get']&&(_0x32afe8=_0x32afe8['get']()),void 0x0!==_0x32afe8&&this['dataSet']['set'](_0x32afe8),super['update']({'options':_0x2b0b73});}['addData'](_0x1d264d,_0x4698aa){const _0x4e9f55={_0x2ba95c:0x1c5,_0x4a4bf8:0x18e},_0x2bfb0b=_0x17fe2d;let _0x4dc268=_0x1d264d;_0x1d264d&&_0x1d264d['get']&&(_0x4dc268=_0x1d264d[_0x2bfb0b(0x1d1)]()),this[_0x2bfb0b(0x1e7)][_0x2bfb0b(_0x4e9f55._0x2ba95c)](_0x4dc268),this[_0x2bfb0b(_0x4e9f55._0x4a4bf8)]({'options':_0x4698aa});}[_0x17fe2d(0x19c)](){return this['dataSet'];}['removeData'](_0x3702b9){const _0x4b5778={_0x36aac9:0x1e7},_0xb66293=_0x17fe2d;if(this['dataSet']){const _0x599797=this[_0xb66293(_0x4b5778._0x36aac9)]['get']({'filter':function(_0x35cee2){return _0x3702b9==null||typeof _0x3702b9!=='function'||!_0x3702b9(_0x35cee2);}});this['dataSet']['set'](_0x599797),this['update']({'options':null});}}['clearData'](){this['dataSet']&&this['dataSet']['clear'](),this['update']({'options':null});}['draw'](){const _0x3dd7b9={_0x3d9a7a:0x1cd},_0x1e9ddf=_0x17fe2d;this[_0x1e9ddf(_0x3dd7b9._0x3d9a7a)][_0x1e9ddf(0x1b0)]();}['clear'](_0x2a52e4){const _0x3df669={_0x40538b:0x1db},_0x54c23a=_0x17fe2d;_0x2a52e4&&_0x2a52e4[_0x54c23a(0x1e1)]&&_0x2a52e4['clearRect'](0x0,0x0,_0x2a52e4['canvas'][_0x54c23a(_0x3df669._0x40538b)],_0x2a52e4['canvas']['height']);}['destroy'](){const _0x1e42ab={_0x5f2777:0x1c2},_0x1c0e63=_0x17fe2d;this['clear'](this['getContext']()),this['clearData'](),this[_0x1c0e63(_0x1e42ab._0x5f2777)]&&this[_0x1c0e63(_0x1e42ab._0x5f2777)]['stop'](),this['animator']=null,this['canvasLayer']=null;}}function _0xca22(_0x335d99,_0x48e4b1){const _0x28b40d=_0x28b4();return _0xca22=function(_0xca221f,_0x11fb85){_0xca221f=_0xca221f-0x18c;let _0x1cd9bd=_0x28b40d[_0xca221f];return _0x1cd9bd;},_0xca22(_0x335d99,_0x48e4b1);}if(mapv__namespace!==null&&mapv__namespace!==void 0x0&&mapv__namespace['DataSet'])mapv__namespace['DataSet'][_0x17fe2d(0x1f2)]['transferCoordinate']=function(_0x2bb2b2,_0x34ff68,_0x49745d,_0x1db36f){const _0x5ead4f={_0x4be4d8:0x1f0,_0x4bac16:0x1c9},_0x49249b={_0x5956df:0x1e9},_0x10a2fa=_0x17fe2d;_0x1db36f=_0x1db36f||'_coordinates',_0x49745d=_0x49745d||'coordinates';for(let _0x345913=0x0;_0x345913<_0x2bb2b2[_0x10a2fa(0x1e9)];_0x345913++){const _0x38281e=_0x2bb2b2[_0x345913]['geometry'],_0x20d34c=_0x38281e[_0x49745d];switch(_0x38281e['type']){case'Point':{const _0x496cfb=_0x34ff68(_0x20d34c);_0x496cfb?_0x38281e[_0x1db36f]=_0x496cfb:_0x38281e[_0x1db36f]=[-0x3e7,-0x3e7];}break;case'LineString':{const _0x35f8b5=[];for(let _0x38824e=0x0;_0x38824e<_0x20d34c['length'];_0x38824e++){const _0x2bbe0e=_0x34ff68(_0x20d34c[_0x38824e]);_0x2bbe0e&&_0x35f8b5['push'](_0x2bbe0e);}_0x38281e[_0x1db36f]=_0x35f8b5;}break;case _0x10a2fa(_0x5ead4f._0x4be4d8):case'Polygon':{const _0x2605ac=_0x6ff858(_0x20d34c);_0x38281e[_0x1db36f]=_0x2605ac;}break;case _0x10a2fa(0x193):{const _0x4ea035=[];for(let _0x183f5d=0x0;_0x183f5d<_0x20d34c['length'];_0x183f5d++){const _0xcf3f15=_0x6ff858(_0x20d34c[_0x183f5d]);_0xcf3f15[_0x10a2fa(0x1e9)]>0x0&&_0x4ea035[_0x10a2fa(_0x5ead4f._0x4bac16)](_0xcf3f15);}_0x38281e[_0x1db36f]=_0x4ea035;}break;}}function _0x6ff858(_0x5a9038){const _0x57b792=_0x10a2fa,_0x4d72d3=[];for(let _0x3910fd=0x0;_0x3910fd<_0x5a9038['length'];_0x3910fd++){const _0x214ff6=_0x5a9038[_0x3910fd],_0x36f644=[];for(let _0x4e9b73=0x0;_0x4e9b73<_0x214ff6[_0x57b792(_0x49249b._0x5956df)];_0x4e9b73++){const _0x1cbb40=_0x34ff68(_0x214ff6[_0x4e9b73]);_0x1cbb40&&_0x36f644[_0x57b792(0x1c9)](_0x1cbb40);}_0x36f644['length']>0x0&&_0x4d72d3['push'](_0x36f644);}return _0x4d72d3;}return _0x2bb2b2;};else throw new Error('请引入\x20mapv\x20库\x20');const Cesium=mars3d__namespace[_0x17fe2d(0x1a8)],BaseLayer=mars3d__namespace['layer'][_0x17fe2d(0x1bb)];function _0x28b4(){const _0xaa598a=['height','fillStyle','344337DniJCc','5578LFRXpe','dataSet','Rectangle','length','initDataRange','default','stepsRange','methods','DomUtil','setZIndex','MultiLineString','postRender','prototype','parentElement','_mountedHook','update','filter','destination-out','animatorMoveendEvent','Util','MultiPolygon','canvas','_addedHook','unbindEvent','devicePixelRatio','container','forEach','8FNJXvp','step','getData','6239795TNzzNN','18511911pNIqYt','_reset','camera','_onMoveStartEvent','_map','zIndex','mapvAutoHeight','initDevicePixelRatio','_createCanvas','DataSet','Cesium','_setOptionsHook','LayerUtil','mapvFixedHeight','top','windowPosition','clearData','getContext','draw','defined','pointerEvents','options','off','updateCallback','render','cameraMoveEnd','remove','28170bKqwWT','_dataCache','BaseLayer','3141jKRbGw','defineProperty','animatorMovestartEvent','7348158hnoLcy','getExtentByGeoJSON','_onMapClick','animator','resize','stopAniamation','add','118aiUXeV','updateData','_onMoveEndEvent','push','_onMapMouseMove','style','_mapVRenderer','canvasLayer','bind','animation','fromDegrees','get','_canvasUpdate','mapvDepthTest','context','click','EventType','mapv','MapVLayer','mousemove','0px','width','scene','display','map','21MZfNLx','SceneMode','clearRect','96504dzodhQ'];_0x28b4=function(){return _0xaa598a;};return _0x28b4();}class MapVLayer extends BaseLayer{constructor(_0x136ed4,_0x50bc5d){const _0x1ee640={_0x49d29a:0x1a7},_0x5c1317=_0x17fe2d;super(_0x136ed4),this['_pointerEvents']=this[_0x5c1317(0x1b3)][_0x5c1317(0x1b2)],this['dataSet']=_0x50bc5d||new mapv__namespace[(_0x5c1317(_0x1ee640._0x49d29a))](_0x136ed4['data']),this['canvas']=null;}get[_0x17fe2d(0x1b2)](){return this['_pointerEvents'];}set['pointerEvents'](_0x5b5c12){const _0x150cfe={_0x50ef2c:0x194},_0x56a8df=_0x17fe2d;this['_pointerEvents']=_0x5b5c12,this[_0x56a8df(_0x150cfe._0x50ef2c)]&&(_0x5b5c12?this['canvas']['style']['pointerEvents']='all':this['canvas']['style']['pointerEvents']='none');}['_showHook'](_0x4919d5){const _0xbba9ec={_0x27997d:0x1dd},_0x338757=_0x17fe2d;_0x4919d5?this['canvas']['style'][_0x338757(_0xbba9ec._0x27997d)]='block':this['canvas']['style']['display']='none';}[_0x17fe2d(0x18d)](){const _0x534322={_0x4394bc:0x1d3,_0x369d4e:0x1b3,_0x187c7f:0x1ab},_0x5e0ad9=_0x17fe2d;this['_map']['scene'][_0x5e0ad9(_0x534322._0x4394bc)]=this[_0x5e0ad9(_0x534322._0x369d4e)]['depthTest']??!![],this['_map']['scene'][_0x5e0ad9(0x1a4)]=this['options']['clampToGround']??![],this['_map'][_0x5e0ad9(0x1dc)][_0x5e0ad9(_0x534322._0x187c7f)]=this['options']['fixedHeight']??0x0;}['_addedHook'](){const _0x273fda={_0x25364e:0x1e7,_0xde98f8:0x1e9,_0x25fc13:0x1ba,_0x1457ac:0x1b3},_0x5cc822=_0x17fe2d;this[_0x5cc822(_0x273fda._0x25364e)]&&(!this['dataSet']['_data']||this[_0x5cc822(_0x273fda._0x25364e)]['_data'][_0x5cc822(_0x273fda._0xde98f8)]===0x0)&&(this['dataSet']['_data']=[]['concat'](this['dataSet'][_0x5cc822(_0x273fda._0x25fc13)])),this['_mapVRenderer']=new MapVRenderer(this[_0x5cc822(0x1a2)],this['dataSet'],this[_0x5cc822(_0x273fda._0x1457ac)],this),this['initDevicePixelRatio'](),this['canvas']=this['_createCanvas'](),this[_0x5cc822(0x1b6)]=this['render'][_0x5cc822(0x1ce)](this),this['bindEvent'](),this['_reset']();}['_removedHook'](){const _0x3edd18={_0x515b4b:0x196,_0x2824b9:0x1cc},_0x5397db=_0x17fe2d;this[_0x5397db(_0x3edd18._0x515b4b)](),this['_mapVRenderer']&&(this['_mapVRenderer']['destroy'](),this[_0x5397db(_0x3edd18._0x2824b9)]=null),this[_0x5397db(0x194)][_0x5397db(0x18c)]['removeChild'](this[_0x5397db(0x194)]);}[_0x17fe2d(0x1a5)](){const _0x1c1f7d={_0x43e27f:0x197},_0x927dc1=_0x17fe2d;this[_0x927dc1(_0x1c1f7d._0x43e27f)]=window['devicePixelRatio']||0x1;}['bindEvent'](){const _0x141f14={_0x2511b1:0x1a2,_0x3ad47d:0x1d5},_0x5f38d=_0x17fe2d;var _0x47e3b9,_0x502f47;this['_map']['on'](mars3d__namespace['EventType']['mouseDown'],this['_onMoveStartEvent'],this),this[_0x5f38d(_0x141f14._0x2511b1)]['on'](mars3d__namespace['EventType']['cameraMoveStart'],this['_onMoveStartEvent'],this),this[_0x5f38d(0x1a2)]['on'](mars3d__namespace['EventType']['cameraMoveEnd'],this[_0x5f38d(0x1c8)],this),(_0x47e3b9=this['options'])!==null&&_0x47e3b9!==void 0x0&&(_0x47e3b9=_0x47e3b9['methods'])!==null&&_0x47e3b9!==void 0x0&&_0x47e3b9['click']&&this['_map']['on'](mars3d__namespace['EventType'][_0x5f38d(_0x141f14._0x3ad47d)],this[_0x5f38d(0x1c1)],this),(_0x502f47=this['options'])!==null&&_0x502f47!==void 0x0&&(_0x502f47=_0x502f47['methods'])!==null&&_0x502f47!==void 0x0&&_0x502f47['mousemove']&&this['_map']['on'](mars3d__namespace['EventType']['mouseMove'],this['_onMapMouseMove'],this);}[_0x17fe2d(0x196)](){const _0x593d72={_0x184bd3:0x1b7,_0x514263:0x1c8,_0x36ba83:0x1f1,_0x4de2d3:0x1a2},_0x354ef9=_0x17fe2d;var _0x448d00,_0x4938ab;this['_map']['off'](mars3d__namespace['EventType']['mouseDown'],this['_onMoveStartEvent'],this),this['_map'][_0x354ef9(0x1b4)](mars3d__namespace['EventType']['cameraMoveStart'],this[_0x354ef9(0x1a1)],this),this['_map']['off'](mars3d__namespace['EventType'][_0x354ef9(_0x593d72._0x184bd3)],this[_0x354ef9(_0x593d72._0x514263)],this),this['_map']['off'](mars3d__namespace['EventType'][_0x354ef9(_0x593d72._0x36ba83)],this['_reset'],this),(_0x448d00=this[_0x354ef9(0x1b3)])!==null&&_0x448d00!==void 0x0&&(_0x448d00=_0x448d00['methods'])!==null&&_0x448d00!==void 0x0&&_0x448d00['click']&&this[_0x354ef9(0x1a2)]['off'](mars3d__namespace[_0x354ef9(0x1d6)][_0x354ef9(0x1d5)],this[_0x354ef9(0x1c1)],this),(_0x4938ab=this['options'])!==null&&_0x4938ab!==void 0x0&&(_0x4938ab=_0x4938ab[_0x354ef9(0x1ed)])!==null&&_0x4938ab!==void 0x0&&_0x4938ab['mousemove']&&this[_0x354ef9(_0x593d72._0x4de2d3)]['off'](mars3d__namespace['EventType']['mouseMove'],this['_onMapMouseMove'],this);}['_onMoveStartEvent'](){const _0x5f122c={_0x53dad7:0x1cc,_0x19e58e:0x1d6},_0x5dd36f=_0x17fe2d;this[_0x5dd36f(_0x5f122c._0x53dad7)]&&(this['_mapVRenderer']['animatorMovestartEvent'](),this['_map']['off'](mars3d__namespace[_0x5dd36f(_0x5f122c._0x19e58e)]['postRender'],this['_reset'],this),this['_map']['on'](mars3d__namespace['EventType']['postRender'],this[_0x5dd36f(0x19f)],this));}['_onMoveEndEvent'](){const _0x442ab8={_0x59dd8e:0x1a2,_0x104082:0x1d6,_0xe1b73:0x19f},_0x52608b=_0x17fe2d;this['_mapVRenderer']&&(this[_0x52608b(_0x442ab8._0x59dd8e)]['off'](mars3d__namespace[_0x52608b(_0x442ab8._0x104082)]['postRender'],this[_0x52608b(_0x442ab8._0xe1b73)],this),this['_mapVRenderer']['animatorMoveendEvent'](),this[_0x52608b(0x19f)]());}[_0x17fe2d(0x1a9)](_0x511ac4,_0x54f765){const _0x2e586f={_0x475546:0x195},_0x2596c4=_0x17fe2d;this['_removedHook'](),this[_0x2596c4(_0x2e586f._0x475546)]();}['addData'](_0x2b8508){const _0x341053=_0x17fe2d;this['_mapVRenderer']&&this[_0x341053(0x1cc)]['addData'](_0x2b8508,this[_0x341053(0x1b3)]);}['updateData'](_0x311f98){const _0x118587=_0x17fe2d;this['_mapVRenderer']&&this[_0x118587(0x1cc)]['updateData'](_0x311f98,this[_0x118587(0x1b3)]);}['getData'](){const _0x34f627=_0x17fe2d;return this['_mapVRenderer']&&(this['dataSet']=this['_mapVRenderer']['getData']()),this[_0x34f627(0x1e7)];}['removeData'](_0x4785b9){this['_mapVRenderer']&&this['_mapVRenderer']['removeData'](_0x4785b9);}['removeAllData'](){const _0x375e6b=_0x17fe2d;this['_mapVRenderer']&&this['_mapVRenderer'][_0x375e6b(0x1ae)]();}[_0x17fe2d(0x1a6)](){const _0xfd88f9={_0x3b1315:0x198,_0x2227a2:0x1ac,_0x58a5c3:0x194,_0x57a70f:0x1e3},_0x1240f1=_0x17fe2d,_0xa35d3f=mars3d__namespace[_0x1240f1(0x1ee)]['create']('canvas','mars3d-mapv',this['_map'][_0x1240f1(_0xfd88f9._0x3b1315)]);_0xa35d3f['id']=this['id'],_0xa35d3f['style']['position']='absolute',_0xa35d3f['style'][_0x1240f1(_0xfd88f9._0x2227a2)]='0px',_0xa35d3f['style']['left']='0px',_0xa35d3f['width']=parseInt(this['_map']['canvas']['width']),_0xa35d3f[_0x1240f1(0x1e3)]=parseInt(this['_map']['canvas']['height']),_0xa35d3f['style']['width']=this['_map'][_0x1240f1(_0xfd88f9._0x58a5c3)]['style']['width'],_0xa35d3f['style'][_0x1240f1(_0xfd88f9._0x57a70f)]=this['_map']['canvas']['style']['height'],_0xa35d3f[_0x1240f1(0x1cb)]['pointerEvents']=this['_pointerEvents']?'auto':'none',_0xa35d3f['style']['zIndex']=this['options']['zIndex']??0x9;if(this['options']['context']==='2d'){const _0x4ed137=this['devicePixelRatio'];_0xa35d3f['getContext'](this['options']['context'])['scale'](_0x4ed137,_0x4ed137);}return _0xa35d3f;}[_0x17fe2d(0x19f)](){this['resize'](),this['render']();}['draw'](){this['_reset']();}[_0x17fe2d(0x1b8)](){const _0x46fb7d=_0x17fe2d;this['_mapVRenderer']&&(this[_0x46fb7d(0x1cc)]['destroy'](),this['_mapVRenderer']=null),this['canvas']['parentElement']['removeChild'](this[_0x46fb7d(0x194)]);}['render'](){const _0xe079d0={_0x48eed5:0x1cc},_0x16c16f=_0x17fe2d;this[_0x16c16f(_0xe079d0._0x48eed5)]['_canvasUpdate']();}[_0x17fe2d(0x1c3)](){const _0x502eda={_0x12f628:0x1da,_0x4f4fd9:0x194,_0x215f53:0x1cb,_0x34f99f:0x1e3},_0xbfe63f=_0x17fe2d;if(this['canvas']){const _0x48ab8c=this['canvas'];_0x48ab8c['style']['position']='absolute',_0x48ab8c['style']['top']='0px',_0x48ab8c['style']['left']=_0xbfe63f(_0x502eda._0x12f628),_0x48ab8c[_0xbfe63f(0x1db)]=parseInt(this['_map']['canvas'][_0xbfe63f(0x1db)]),_0x48ab8c['height']=parseInt(this[_0xbfe63f(0x1a2)]['canvas']['height']),_0x48ab8c['style']['width']=this['_map'][_0xbfe63f(_0x502eda._0x4f4fd9)][_0xbfe63f(0x1cb)]['width'],_0x48ab8c[_0xbfe63f(_0x502eda._0x215f53)]['height']=this[_0xbfe63f(0x1a2)]['canvas']['style'][_0xbfe63f(_0x502eda._0x34f99f)];}}['getRectangle'](_0x20c324){const _0x344087={_0x3f1a8e:0x1c0},_0x20ee15=_0x17fe2d;if(!this[_0x20ee15(0x1e7)]||!this['dataSet']['_data'])return;const _0x3122e6=mars3d__namespace[_0x20ee15(0x192)][_0x20ee15(_0x344087._0x3f1a8e)]({'type':'FeatureCollection','features':this['dataSet']['_data']});if(!_0x3122e6)return;return _0x20c324!==null&&_0x20c324!==void 0x0&&_0x20c324['isFormat']?_0x3122e6:Cesium[_0x20ee15(0x1e8)]['fromDegrees'](_0x3122e6['xmin'],_0x3122e6['ymin'],_0x3122e6['xmax'],_0x3122e6['ymax']);}[_0x17fe2d(0x1c1)](_0x2b8018){const _0x54f94f={_0x3025f6:0x1cc},_0x4f27b9=_0x17fe2d;this['_cache_event']=_0x2b8018,this[_0x4f27b9(0x1cc)]&&this[_0x4f27b9(_0x54f94f._0x3025f6)]['clickEvent'](_0x2b8018['windowPosition'],_0x2b8018);}[_0x17fe2d(0x1ca)](_0x2d3bec){const _0x470ccb={_0x2cdf7d:0x1ad},_0x2b4299=_0x17fe2d;this['_cache_event']=_0x2d3bec,this['_mapVRenderer']&&this['_mapVRenderer']['mousemoveEvent'](_0x2d3bec[_0x2b4299(_0x470ccb._0x2cdf7d)],_0x2d3bec);}['on'](_0xd267ad,_0x119924,_0x38e690){const _0x19dea2={_0x190890:0x1d5,_0x5b6714:0x1b3},_0x40402b=_0x17fe2d;this[_0x40402b(0x1b3)]['methods']=this['options']['methods']||{};if(_0xd267ad===mars3d__namespace['EventType'][_0x40402b(_0x19dea2._0x190890)])this['options']['methods']['click']=_0x53c231=>{const _0x39caaa=_0x40402b;_0x53c231&&_0x119924[_0x39caaa(0x1ce)](_0x38e690)({...this['_cache_event'],'layer':this,'data':_0x53c231});},this['_map']['on'](mars3d__namespace['EventType']['click'],this['_onMapClick'],this);else _0xd267ad===mars3d__namespace['EventType']['mouseMove']&&(this[_0x40402b(_0x19dea2._0x5b6714)]['methods'][_0x40402b(0x1d9)]=_0x1d74eb=>{_0x1d74eb&&_0x119924['bind'](_0x38e690)({...this['_cache_event'],'layer':this,'data':_0x1d74eb});},this[_0x40402b(0x1a2)]['on'](mars3d__namespace[_0x40402b(0x1d6)]['mouseMove'],this['_onMapMouseMove'],this));return this;}['off'](_0x4249ac,_0x13a75a){const _0x2fa915=_0x17fe2d;if(_0x4249ac==='click'){var _0x51e661;this['_map']['off'](_0x4249ac,this['_onMapClick'],this),(_0x51e661=this['options']['methods'])!==null&&_0x51e661!==void 0x0&&_0x51e661['mousemove']&&delete this['options']['methods']['click'];}else{if(_0x4249ac==='mouseMove'){var _0x446b49;this['_map']['off'](_0x4249ac,this['_onMapMouseMove'],this),(_0x446b49=this['options'][_0x2fa915(0x1ed)])!==null&&_0x446b49!==void 0x0&&_0x446b49['mousemove']&&delete this[_0x2fa915(0x1b3)][_0x2fa915(0x1ed)]['mousemove'];}}return this;}}mars3d__namespace[_0x17fe2d(0x1aa)]['register'](_0x17fe2d(0x1d7),MapVLayer),mars3d__namespace['layer'][_0x17fe2d(0x1d8)]=MapVLayer,mars3d__namespace[_0x17fe2d(0x1d7)]=mapv__namespace,exports['MapVLayer']=MapVLayer,Object['keys'](mapv)[_0x17fe2d(0x199)](function(_0x32e02a){if(_0x32e02a!=='default'&&!exports['hasOwnProperty'](_0x32e02a))Object['defineProperty'](exports,_0x32e02a,{'enumerable':!![],'get':function(){return mapv[_0x32e02a];}});}),Object[_0x17fe2d(0x1bd)](exports,'__esModule',{'value':!![]});
|
|
15
15
|
}));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mars3d-mapv",
|
|
3
|
-
"version": "3.7.
|
|
3
|
+
"version": "3.7.5",
|
|
4
4
|
"description": "Mars3D平台插件,结合mapv可视化功能插件",
|
|
5
5
|
"main": "dist/mars3d-mapv.js",
|
|
6
6
|
"files": [
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"mapv": "^2.0.62"
|
|
11
11
|
},
|
|
12
12
|
"devDependencies": {
|
|
13
|
-
"mars3d": "~3.7.
|
|
13
|
+
"mars3d": "~3.7.5"
|
|
14
14
|
},
|
|
15
15
|
"scripts": {
|
|
16
16
|
"lint": "eslint ./src/**/*.{js,ts} --fix"
|