mars3d-wind 3.6.16 → 3.6.18

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平台插件,支持气象 风向图 功能插件 mars3d-wind
3
3
  *
4
- * 版本信息:v3.6.16
5
- * 编译日期:2023-12-12 14:26:55
4
+ * 版本信息:v3.6.18
5
+ * 编译日期:2023-12-31 22:36:42
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'], factory) :
12
12
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["mars3d-wind"] = {}, global.mars3d));
13
13
  })(this, (function (exports, mars3d) {
14
- 'use strict';const _0x5abd34=_0x411b;(function(_0x1a60fb,_0x18408f){const _0xf06133=_0x411b,_0x51ca88=_0x1a60fb();while(!![]){try{const _0x32b27c=-parseInt(_0xf06133(0x1c5))/0x1+-parseInt(_0xf06133(0x2a6))/0x2+parseInt(_0xf06133(0x225))/0x3+-parseInt(_0xf06133(0x2ac))/0x4*(parseInt(_0xf06133(0x294))/0x5)+-parseInt(_0xf06133(0x1e6))/0x6*(-parseInt(_0xf06133(0x235))/0x7)+parseInt(_0xf06133(0x1f0))/0x8*(parseInt(_0xf06133(0x291))/0x9)+parseInt(_0xf06133(0x1e5))/0xa*(parseInt(_0xf06133(0x1d3))/0xb);if(_0x32b27c===_0x18408f)break;else _0x51ca88['push'](_0x51ca88['shift']());}catch(_0x8e00d8){_0x51ca88['push'](_0x51ca88['shift']());}}}(_0x1b0e,0x8695e));function _interopNamespace(_0x41d2b2){const _0x357bfc=_0x411b;if(_0x41d2b2&&_0x41d2b2['__esModule'])return _0x41d2b2;var _0x1ba9e2=Object['create'](null);return _0x41d2b2&&Object[_0x357bfc(0x238)](_0x41d2b2)['forEach'](function(_0x37ce0f){if(_0x37ce0f!=='default'){var _0x215176=Object['getOwnPropertyDescriptor'](_0x41d2b2,_0x37ce0f);Object['defineProperty'](_0x1ba9e2,_0x37ce0f,_0x215176['get']?_0x215176:{'enumerable':!![],'get':function(){return _0x41d2b2[_0x37ce0f];}});}}),_0x1ba9e2['default']=_0x41d2b2,_0x1ba9e2;}var mars3d__namespace=_interopNamespace(mars3d);function _0x1b0e(){const _0x222133=['EventType','lineTo','fromGeometry','canvasHeight','off','width','addEventListener','lev','_calcUV','lineWidth','resize','dropRate','Compute','ComputeCommand','postProcessingSpeed','16464610GLegFV','26304nlSqpL','toDegrees','_onMouseUpEvent','postMessage','fillRect','SceneTransforms','fixedHeight','Draw','viewerParameters','postProcessingPosition','232myAPTc','xmin','_maxAge','fadeOpacity','LINEAR','ShaderSource','getOptions','mouse_down','_tomap','shaderProgram','getUVByPoint','forEach','arrayBufferView','WindUtil','strokeStyle','TRIANGLES','ClearCommand','Cartesian3','steps','createParticlesTextures','latRange','removeAll','particlesTextures','_drawLines','preExecute','context','style','segments','framebuffers','Math','_removedHook','options','particlesRendering','length','createSegmentsGeometry','PI_OVER_TWO','clear','clearCommand','lat','NEAREST','Geometry','Cesium','getParticles','SceneMode','setDate','nextParticlesSpeed','lonRange','windTextures','random','min','sqrt','viewRectangleToLonLatRange','register','58842fwbjoD','colors','bindEvent','createRenderingPrimitives','outputTexture','FLOAT','primitiveType','_data','_onMouseDownEvent','_map','age','_createCanvas','fragmentShaderSource','canvasContext','mouseHidden','cols','427wMXGjf','setGeometry','camera','keys','BaseLayer','uniform\x20sampler2D\x20trailsColorTexture;\x0auniform\x20sampler2D\x20trailsDepthTexture;\x0a\x0ain\x20vec2\x20textureCoordinate;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec4\x20trailsColor\x20=\x20texture(trailsColorTexture,\x20textureCoordinate);\x0a\x20\x20\x20\x20float\x20trailsDepth\x20=\x20texture(trailsDepthTexture,\x20textureCoordinate).r;\x0a\x20\x20\x20\x20float\x20globeDepth\x20=\x20czm_unpackDepth(texture(czm_globeDepthTexture,\x20textureCoordinate));\x0a\x0a\x20\x20\x20\x20if\x20(trailsDepth\x20<\x20globeDepth)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20trailsColor;\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20}\x0a}\x0a','cancelAnimationFrame','speedRate','ymin','commandToExecute','speedFactor','particleSystem','umax','setOptions','ellipsoid','preRender','_randomParticle','lng','particlesWind','pow','tlat','Cartesian2','Framebuffer','worker','now','createTexture','west','particlesComputing','ceil','mars3d-canvasWind','BoundingSphere','_updateIng','mouse_move','createComputingPrimitives','ALWAYS','Color','OPAQUE','max','getRandomLatLng','currentTrails','getWind','setData','create','udata','umin','rows','uniform\x20sampler2D\x20currentParticlesSpeed;\x20//\x20(u,\x20v,\x20w,\x20normalization)\x0auniform\x20sampler2D\x20particlesWind;\x0a\x0a//\x20used\x20to\x20calculate\x20the\x20wind\x20norm\x0auniform\x20vec2\x20uSpeedRange;\x20//\x20(min,\x20max);\x0auniform\x20vec2\x20vSpeedRange;\x0auniform\x20float\x20pixelSize;\x0auniform\x20float\x20speedFactor;\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0afloat\x20calculateWindNorm(vec3\x20speed)\x20{\x0a\x20\x20\x20\x20vec3\x20percent\x20=\x20vec3(0.0);\x0a\x20\x20\x20\x20percent.x\x20=\x20(speed.x\x20-\x20uSpeedRange.x)\x20/\x20(uSpeedRange.y\x20-\x20uSpeedRange.x);\x0a\x20\x20\x20\x20percent.y\x20=\x20(speed.y\x20-\x20vSpeedRange.x)\x20/\x20(vSpeedRange.y\x20-\x20vSpeedRange.x);\x0a\x20\x20\x20\x20float\x20normalization\x20=\x20length(percent);\x0a\x0a\x20\x20\x20\x20return\x20normalization;\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20//\x20texture\x20coordinate\x20must\x20be\x20normalized\x0a\x20\x20\x20\x20//\x20vec3\x20currentSpeed\x20=\x20texture(currentParticlesSpeed,\x20v_textureCoordinates).rgb;\x0a\x20\x20\x20\x20vec3\x20windVector\x20=\x20texture(particlesWind,\x20v_textureCoordinates).rgb;\x0a\x0a\x20\x20\x20\x20vec4\x20nextSpeed\x20=\x20vec4(speedFactor\x20*\x20pixelSize\x20*\x20windVector,\x20calculateWindNorm(windVector));\x0a\x20\x20\x20\x20out_FragColor\x20=\x20nextSpeed;\x0a}\x0a','ymax','windField','destroyParticlesTextures','createCommand','height','currentParticlesSpeed','dropRateBump','PixelFormat','_setOptionsHook','lon','autoClear','getUVByXY','DISABLE_LOG_DEPTH_FRAGMENT_WRITE','tlng','clientHeight','scene','_onMouseMoveEvent','framebuffer','Rectangle','east','canvas','data','color','primitives','TextureMinificationFilter','layer','vmax','CanvasWindField','_calc_speedRate','_addedHook','add','visibility','PrimitiveType','updateViewerParameters','windData','maxParticles','colorTable','computeViewRectangle','mod','vertexArray','ComponentDatatype','initWorker','__esModule','reverse','fromCache','185427yKAJYk','clientWidth','currentTrailsColor','275oEZjwr','SCENE3D','unbindEvent','clearFramebuffers','refreshTimer','destroyObject','updatePosition','in\x20vec2\x20st;\x0a//\x20it\x20is\x20not\x20normal\x20itself,\x20but\x20used\x20to\x20control\x20normal\x0ain\x20vec3\x20normal;\x20//\x20(point\x20to\x20use,\x20offset\x20sign,\x20not\x20used\x20component)\x0a\x0auniform\x20sampler2D\x20currentParticlesPosition;\x0auniform\x20sampler2D\x20postProcessingPosition;\x0auniform\x20sampler2D\x20postProcessingSpeed;\x0a\x0auniform\x20float\x20particleHeight;\x0a\x0auniform\x20float\x20aspect;\x0auniform\x20float\x20pixelSize;\x0auniform\x20float\x20lineWidth;\x0a\x0aout\x20float\x20speedNormalization;\x0a\x0avec3\x20convertCoordinate(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20WGS84\x20(lon,\x20lat,\x20lev)\x20->\x20ECEF\x20(x,\x20y,\x20z)\x0a\x20\x20\x20\x20//\x20see\x20https://en.wikipedia.org/wiki/Geographic_coordinate_conversion#From_geodetic_to_ECEF_coordinates\x20for\x20detail\x0a\x0a\x20\x20\x20\x20//\x20WGS\x2084\x20geometric\x20constants\x0a\x20\x20\x20\x20float\x20a\x20=\x206378137.0;\x20//\x20Semi-major\x20axis\x0a\x20\x20\x20\x20float\x20b\x20=\x206356752.3142;\x20//\x20Semi-minor\x20axis\x0a\x20\x20\x20\x20float\x20e2\x20=\x206.69437999014e-3;\x20//\x20First\x20eccentricity\x20squared\x0a\x0a\x20\x20\x20\x20float\x20latitude\x20=\x20radians(lonLatLev.y);\x0a\x20\x20\x20\x20float\x20longitude\x20=\x20radians(lonLatLev.x);\x0a\x0a\x20\x20\x20\x20float\x20cosLat\x20=\x20cos(latitude);\x0a\x20\x20\x20\x20float\x20sinLat\x20=\x20sin(latitude);\x0a\x20\x20\x20\x20float\x20cosLon\x20=\x20cos(longitude);\x0a\x20\x20\x20\x20float\x20sinLon\x20=\x20sin(longitude);\x0a\x0a\x20\x20\x20\x20float\x20N_Phi\x20=\x20a\x20/\x20sqrt(1.0\x20-\x20e2\x20*\x20sinLat\x20*\x20sinLat);\x0a\x20\x20\x20\x20float\x20h\x20=\x20particleHeight;\x20//\x20it\x20should\x20be\x20high\x20enough\x20otherwise\x20the\x20particle\x20may\x20not\x20pass\x20the\x20terrain\x20depth\x20test\x0a\x0a\x20\x20\x20\x20vec3\x20cartesian\x20=\x20vec3(0.0);\x0a\x20\x20\x20\x20cartesian.x\x20=\x20(N_Phi\x20+\x20h)\x20*\x20cosLat\x20*\x20cosLon;\x0a\x20\x20\x20\x20cartesian.y\x20=\x20(N_Phi\x20+\x20h)\x20*\x20cosLat\x20*\x20sinLon;\x0a\x20\x20\x20\x20cartesian.z\x20=\x20((b\x20*\x20b)\x20/\x20(a\x20*\x20a)\x20*\x20N_Phi\x20+\x20h)\x20*\x20sinLat;\x0a\x20\x20\x20\x20return\x20cartesian;\x0a}\x0a\x0avec4\x20calcProjectedCoordinate(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20the\x20range\x20of\x20longitude\x20in\x20Cesium\x20is\x20[-180,\x20180]\x20but\x20the\x20range\x20of\x20longitude\x20in\x20the\x20NetCDF\x20file\x20is\x20[0,\x20360]\x0a\x20\x20\x20\x20//\x20[0,\x20180]\x20is\x20corresponding\x20to\x20[0,\x20180]\x20and\x20[180,\x20360]\x20is\x20corresponding\x20to\x20[-180,\x200]\x0a\x20\x20\x20\x20lonLatLev.x\x20=\x20mod(lonLatLev.x\x20+\x20180.0,\x20360.0)\x20-\x20180.0;\x0a\x20\x20\x20\x20vec3\x20particlePosition\x20=\x20convertCoordinate(lonLatLev);\x0a\x20\x20\x20\x20vec4\x20projectedCoordinate\x20=\x20czm_modelViewProjection\x20*\x20vec4(particlePosition,\x201.0);\x0a\x20\x20\x20\x20return\x20projectedCoordinate;\x0a}\x0a\x0avec4\x20calcOffset(vec4\x20currentProjectedCoordinate,\x20vec4\x20nextProjectedCoordinate,\x20float\x20offsetSign)\x20{\x0a\x20\x20\x20\x20vec2\x20aspectVec2\x20=\x20vec2(aspect,\x201.0);\x0a\x20\x20\x20\x20vec2\x20currentXY\x20=\x20(currentProjectedCoordinate.xy\x20/\x20currentProjectedCoordinate.w)\x20*\x20aspectVec2;\x0a\x20\x20\x20\x20vec2\x20nextXY\x20=\x20(nextProjectedCoordinate.xy\x20/\x20nextProjectedCoordinate.w)\x20*\x20aspectVec2;\x0a\x0a\x20\x20\x20\x20float\x20offsetLength\x20=\x20lineWidth\x20/\x202.0;\x0a\x20\x20\x20\x20vec2\x20direction\x20=\x20normalize(nextXY\x20-\x20currentXY);\x0a\x20\x20\x20\x20vec2\x20normalVector\x20=\x20vec2(-direction.y,\x20direction.x);\x0a\x20\x20\x20\x20normalVector.x\x20=\x20normalVector.x\x20/\x20aspect;\x0a\x20\x20\x20\x20normalVector\x20=\x20offsetLength\x20*\x20normalVector;\x0a\x0a\x20\x20\x20\x20vec4\x20offset\x20=\x20vec4(offsetSign\x20*\x20normalVector,\x200.0,\x200.0);\x0a\x20\x20\x20\x20return\x20offset;\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec2\x20particleIndex\x20=\x20st;\x0a\x0a\x20\x20\x20\x20vec3\x20currentPosition\x20=\x20texture(currentParticlesPosition,\x20particleIndex).rgb;\x0a\x20\x20\x20\x20vec4\x20nextPosition\x20=\x20texture(postProcessingPosition,\x20particleIndex);\x0a\x0a\x20\x20\x20\x20vec4\x20currentProjectedCoordinate\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20vec4\x20nextProjectedCoordinate\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20if\x20(nextPosition.w\x20>\x200.0)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20currentProjectedCoordinate\x20=\x20calcProjectedCoordinate(currentPosition);\x0a\x20\x20\x20\x20\x20\x20\x20\x20nextProjectedCoordinate\x20=\x20calcProjectedCoordinate(currentPosition);\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20currentProjectedCoordinate\x20=\x20calcProjectedCoordinate(currentPosition);\x0a\x20\x20\x20\x20\x20\x20\x20\x20nextProjectedCoordinate\x20=\x20calcProjectedCoordinate(nextPosition.xyz);\x0a\x20\x20\x20\x20}\x0a\x0a\x20\x20\x20\x20float\x20pointToUse\x20=\x20normal.x;\x20//\x20-1\x20is\x20currentProjectedCoordinate\x20and\x20+1\x20is\x20nextProjectedCoordinate\x0a\x20\x20\x20\x20float\x20offsetSign\x20=\x20normal.y;\x0a\x0a\x20\x20\x20\x20vec4\x20offset\x20=\x20pixelSize\x20*\x20calcOffset(currentProjectedCoordinate,\x20nextProjectedCoordinate,\x20offsetSign);\x0a\x20\x20\x20\x20if\x20(pointToUse\x20<\x200.0)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20gl_Position\x20=\x20currentProjectedCoordinate\x20+\x20offset;\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20gl_Position\x20=\x20nextProjectedCoordinate\x20+\x20offset;\x0a\x20\x20\x20\x20}\x0a\x0a\x20\x20\x20\x20speedNormalization\x20=\x20texture(postProcessingSpeed,\x20particleIndex).a;\x0a}\x0a','grid','defined','wheel','TextureMagnificationFilter','UNSIGNED_INT','currentParticlesPosition','addPrimitives','globeBoundingSphere','uniformMap','beginPath','1232452kptYVC','isInExtent','levmax','getDefaultRenderState','Sampler','redraw','75404cYKNct','particles','reverseY','randomizeParticles','_canrefresh','south','speed','GeometryAttribute','particlesTextureSize','update','DepthFunction','randomBetween','updateSpeed','createRenderingTextures','DrawCommand','326693siFtGT','canvasResize','canvasWidth','attributeLocations','xmax','particlesNumber','nextTrails','toRadians','_onMapWhellEvent','maxAge','push','mouseDown','destroy','textures','11sbhTLe','dimensions','show'];_0x1b0e=function(){return _0x222133;};return _0x1b0e();}const Cesium$7=mars3d__namespace[_0x5abd34(0x219)];function getU(_0x12a79b,_0x389912){const _0x4f2ce7=_0x5abd34,_0x420561=_0x12a79b*Math['cos'](Cesium$7[_0x4f2ce7(0x20d)][_0x4f2ce7(0x1cc)](_0x389912));return _0x420561;}function getV(_0x4f0087,_0xb64ad2){const _0x1e11c0=_0x4f0087*Math['sin'](Cesium$7['Math']['toRadians'](_0xb64ad2));return _0x1e11c0;}function getSpeed(_0x42aecc,_0xec05ef){const _0x125cc4=_0x5abd34,_0x56ada9=Math['sqrt'](Math[_0x125cc4(0x248)](_0x42aecc,0x2)+Math[_0x125cc4(0x248)](_0xec05ef,0x2));return _0x56ada9;}function getDirection(_0x1923eb,_0x5814d6){const _0x3757c8=_0x5abd34;let _0x4e66c8=Cesium$7['Math'][_0x3757c8(0x1e7)](Math['atan2'](_0x5814d6,_0x1923eb));return _0x4e66c8+=_0x4e66c8<0x0?0x168:0x0,_0x4e66c8;}var WindUtil={'__proto__':null,'getU':getU,'getV':getV,'getSpeed':getSpeed,'getDirection':getDirection};const Cesium$6=mars3d__namespace['Cesium'];class CustomPrimitive{constructor(_0x4adcda){const _0x47bd0b=_0x5abd34;this['commandType']=_0x4adcda['commandType'],this['geometry']=_0x4adcda['geometry'],this[_0x47bd0b(0x1c8)]=_0x4adcda[_0x47bd0b(0x1c8)],this['primitiveType']=_0x4adcda[_0x47bd0b(0x22b)],this['uniformMap']=_0x4adcda['uniformMap'],this['vertexShaderSource']=_0x4adcda['vertexShaderSource'],this['fragmentShaderSource']=_0x4adcda[_0x47bd0b(0x231)],this['rawRenderState']=_0x4adcda['rawRenderState'],this['framebuffer']=_0x4adcda[_0x47bd0b(0x275)],this['outputTexture']=_0x4adcda['outputTexture'],this['autoClear']=_0x4adcda[_0x47bd0b(0x26e)]??![],this['preExecute']=_0x4adcda['preExecute'],this[_0x47bd0b(0x1d5)]=!![],this['commandToExecute']=undefined,this['clearCommand']=undefined,this['autoClear']&&(this['clearCommand']=new Cesium$6['ClearCommand']({'color':new Cesium$6[(_0x47bd0b(0x258))](0x0,0x0,0x0,0x0),'depth':0x1,'framebuffer':this[_0x47bd0b(0x275)],'pass':Cesium$6['Pass']['OPAQUE']}));}[_0x5abd34(0x267)](_0x28fd70){const _0x1a40a5=_0x5abd34;switch(this['commandType']){case'Draw':{const _0x430b56=Cesium$6['VertexArray']['fromGeometry']({'context':_0x28fd70,'geometry':this['geometry'],'attributeLocations':this[_0x1a40a5(0x1c8)],'bufferUsage':Cesium$6['BufferUsage']['STATIC_DRAW']}),_0x32af61=Cesium$6['ShaderProgram']['fromCache']({'context':_0x28fd70,'attributeLocations':this['attributeLocations'],'vertexShaderSource':this['vertexShaderSource'],'fragmentShaderSource':this['fragmentShaderSource']}),_0x2e85f5=Cesium$6['RenderState'][_0x1a40a5(0x290)](this['rawRenderState']);return new Cesium$6[(_0x1a40a5(0x1c4))]({'primitiveType':this['primitiveType'],'shaderProgram':_0x32af61,'vertexArray':_0x430b56,'modelMatrix':Cesium$6['Matrix4']['IDENTITY'],'renderState':_0x2e85f5,'uniformMap':this['uniformMap'],'castShadows':![],'receiveShadows':![],'framebuffer':this['framebuffer'],'pass':Cesium$6['Pass'][_0x1a40a5(0x259)],'pickOnly':!![],'owner':this});}case'Compute':{return new Cesium$6[(_0x1a40a5(0x1e3))]({'owner':this,'fragmentShaderSource':this[_0x1a40a5(0x231)],'uniformMap':this[_0x1a40a5(0x2a4)],'outputTexture':this['outputTexture'],'persists':!![]});}}}[_0x5abd34(0x236)](_0x5a8eb4,_0x2aec02){const _0x26468b=_0x5abd34;this['geometry']=_0x2aec02;const _0x45ce39=Cesium$6['VertexArray'][_0x26468b(0x1d8)]({'context':_0x5a8eb4,'geometry':this['geometry'],'attributeLocations':this['attributeLocations'],'bufferUsage':Cesium$6['BufferUsage']['STATIC_DRAW']});this['commandToExecute'][_0x26468b(0x28b)]=_0x45ce39;}['update'](_0x1aab1e){const _0x338906=_0x5abd34;if(!this['show'])return;if(_0x1aab1e['mode']!==Cesium$6['SceneMode'][_0x338906(0x295)])return;!Cesium$6[_0x338906(0x29d)](this[_0x338906(0x23e)])&&(this['commandToExecute']=this[_0x338906(0x267)](_0x1aab1e['context'])),Cesium$6['defined'](this['preExecute'])&&this[_0x338906(0x208)](),Cesium$6['defined'](this['clearCommand'])&&_0x1aab1e['commandList']['push'](this[_0x338906(0x215)]),_0x1aab1e['commandList']['push'](this['commandToExecute']);}['isDestroyed'](){return![];}['destroy'](){const _0x1fd27a=_0x5abd34;if(this[_0x1fd27a(0x215)]){var _0x26e91f,_0x4d4d2c;(_0x26e91f=this[_0x1fd27a(0x215)])!==null&&_0x26e91f!==void 0x0&&_0x26e91f['vertexArray']&&this['clearCommand']['vertexArray']['destroy'](),(_0x4d4d2c=this[_0x1fd27a(0x215)])!==null&&_0x4d4d2c!==void 0x0&&_0x4d4d2c[_0x1fd27a(0x1f9)]&&this['clearCommand']['shaderProgram'][_0x1fd27a(0x1d1)](),delete this['clearCommand'];}return this['commandToExecute']&&(this['commandToExecute']['vertexArray']&&this['commandToExecute']['vertexArray'][_0x1fd27a(0x1d1)](),this['commandToExecute']['shaderProgram']&&this['commandToExecute']['shaderProgram']['destroy'](),delete this['commandToExecute']),Cesium$6[_0x1fd27a(0x299)](this);}}const Cesium$5=mars3d__namespace[_0x5abd34(0x219)],Util=(function(){const _0x13de70=function(){const _0x1a7955=_0x411b,_0x59d468=new Cesium$5['Geometry']({'attributes':new Cesium$5['GeometryAttributes']({'position':new Cesium$5['GeometryAttribute']({'componentDatatype':Cesium$5[_0x1a7955(0x28c)][_0x1a7955(0x22a)],'componentsPerAttribute':0x3,'values':new Float32Array([-0x1,-0x1,0x0,0x1,-0x1,0x0,0x1,0x1,0x0,-0x1,0x1,0x0])}),'st':new Cesium$5[(_0x1a7955(0x1bd))]({'componentDatatype':Cesium$5['ComponentDatatype'][_0x1a7955(0x22a)],'componentsPerAttribute':0x2,'values':new Float32Array([0x0,0x0,0x1,0x0,0x1,0x1,0x0,0x1])})}),'indices':new Uint32Array([0x3,0x2,0x0,0x0,0x2,0x1])});return _0x59d468;},_0x31aff7=function(_0x288fb4,_0x11e88e){const _0x2ec41f=_0x411b;if(Cesium$5[_0x2ec41f(0x29d)](_0x11e88e)){const _0x4f07e7={};_0x4f07e7[_0x2ec41f(0x1fc)]=_0x11e88e,_0x288fb4['source']=_0x4f07e7;}const _0x3e7758=new Cesium$5['Texture'](_0x288fb4);return _0x3e7758;},_0x282808=function(_0x462854,_0x316035,_0x1f681e){const _0x340bba=_0x411b,_0x16efb7=new Cesium$5[(_0x340bba(0x24b))]({'context':_0x462854,'colorTextures':[_0x316035],'depthTexture':_0x1f681e});return _0x16efb7;},_0x298c79=function(_0x1eb403){const _0x49ab4a=_0x411b,_0x427fa3=!![],_0x458435=![],_0xde2ad2={'viewport':_0x1eb403['viewport'],'depthTest':_0x1eb403['depthTest'],'depthMask':_0x1eb403['depthMask'],'blending':_0x1eb403['blending']},_0x4504c8=Cesium$5['Appearance'][_0x49ab4a(0x2a9)](_0x427fa3,_0x458435,_0xde2ad2);return _0x4504c8;},_0xdd6ecf=function(_0x7ee5e6){const _0x49660e=_0x411b,_0x41e06d={},_0x16886a=Cesium$5['Math'][_0x49660e(0x28a)](_0x7ee5e6[_0x49660e(0x24f)],Cesium$5['Math']['TWO_PI']),_0x2ace70=Cesium$5[_0x49660e(0x20d)]['mod'](_0x7ee5e6[_0x49660e(0x277)],Cesium$5['Math']['TWO_PI']),_0x10e331=_0x7ee5e6['width'];let _0x41db26,_0x2bf5e0;_0x10e331>Cesium$5[_0x49660e(0x20d)]['THREE_PI_OVER_TWO']?(_0x41db26=0x0,_0x2bf5e0=Cesium$5[_0x49660e(0x20d)]['TWO_PI']):_0x2ace70-_0x16886a<_0x10e331?(_0x41db26=_0x16886a,_0x2bf5e0=_0x16886a+_0x10e331):(_0x41db26=_0x16886a,_0x2bf5e0=_0x2ace70);_0x41e06d['lon']={'min':Cesium$5['Math']['toDegrees'](_0x41db26),'max':Cesium$5['Math'][_0x49660e(0x1e7)](_0x2bf5e0)};const _0x3d43a4=_0x7ee5e6[_0x49660e(0x2b1)],_0x4a6146=_0x7ee5e6['north'],_0x5d5931=_0x7ee5e6['height'],_0x4f5014=_0x5d5931>Cesium$5['Math']['PI']/0xc?_0x5d5931/0x2:0x0;let _0x222ede=Cesium$5['Math']['clampToLatitudeRange'](_0x3d43a4-_0x4f5014),_0x29a326=Cesium$5['Math']['clampToLatitudeRange'](_0x4a6146+_0x4f5014);return _0x222ede<-Cesium$5['Math']['PI_OVER_THREE']&&(_0x222ede=-Cesium$5['Math']['PI_OVER_TWO']),_0x29a326>Cesium$5['Math']['PI_OVER_THREE']&&(_0x29a326=Cesium$5['Math'][_0x49660e(0x213)]),_0x41e06d['lat']={'min':Cesium$5['Math']['toDegrees'](_0x222ede),'max':Cesium$5['Math']['toDegrees'](_0x29a326)},_0x41e06d;};return{'getFullscreenQuad':_0x13de70,'createTexture':_0x31aff7,'createFramebuffer':_0x282808,'createRawRenderState':_0x298c79,'viewRectangleToLonLatRange':_0xdd6ecf};}());var segmentDraw_vert=_0x5abd34(0x29b),segmentDraw_frag='uniform\x20sampler2D\x20colorTable;\x0a\x0ain\x20float\x20speedNormalization;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20out_FragColor\x20=\x20texture(colorTable,\x20vec2(speedNormalization,\x200.0));\x0a}\x0a',fullscreen_vert='in\x20vec3\x20position;\x0ain\x20vec2\x20st;\x0a\x0aout\x20vec2\x20textureCoordinate;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20textureCoordinate\x20=\x20st;\x0a\x20\x20\x20\x20gl_Position\x20=\x20vec4(position,\x201.0);\x0a}\x0a',trailDraw_frag='uniform\x20sampler2D\x20segmentsColorTexture;\x0auniform\x20sampler2D\x20segmentsDepthTexture;\x0a\x0auniform\x20sampler2D\x20currentTrailsColor;\x0auniform\x20sampler2D\x20trailsDepthTexture;\x0a\x0auniform\x20float\x20fadeOpacity;\x0a\x0ain\x20vec2\x20textureCoordinate;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec4\x20pointsColor\x20=\x20texture(segmentsColorTexture,\x20textureCoordinate);\x0a\x20\x20\x20\x20vec4\x20trailsColor\x20=\x20texture(currentTrailsColor,\x20textureCoordinate);\x0a\x0a\x20\x20\x20\x20trailsColor\x20=\x20floor(fadeOpacity\x20*\x20255.0\x20*\x20trailsColor)\x20/\x20255.0;\x20//\x20make\x20sure\x20the\x20trailsColor\x20will\x20be\x20strictly\x20decreased\x0a\x0a\x20\x20\x20\x20float\x20pointsDepth\x20=\x20texture(segmentsDepthTexture,\x20textureCoordinate).r;\x0a\x20\x20\x20\x20float\x20trailsDepth\x20=\x20texture(trailsDepthTexture,\x20textureCoordinate).r;\x0a\x20\x20\x20\x20float\x20globeDepth\x20=\x20czm_unpackDepth(texture(czm_globeDepthTexture,\x20textureCoordinate));\x0a\x0a\x20\x20\x20\x20out_FragColor\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20if\x20(pointsDepth\x20<\x20globeDepth)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20out_FragColor\x20+\x20pointsColor;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20if\x20(trailsDepth\x20<\x20globeDepth)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20out_FragColor\x20+\x20trailsColor;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20gl_FragDepth\x20=\x20min(pointsDepth,\x20trailsDepth);\x0a}\x0a',screenDraw_frag=_0x5abd34(0x23a);const Cesium$4=mars3d__namespace['Cesium'];class ParticlesRendering{constructor(_0x4e2600,_0x286d30,_0xfc054d,_0x27f366,_0x3298ae){const _0x24027f=_0x5abd34;this[_0x24027f(0x1c3)](_0x4e2600,_0x286d30,_0xfc054d[_0x24027f(0x226)]),this['createRenderingFramebuffers'](_0x4e2600),this['createRenderingPrimitives'](_0x4e2600,_0xfc054d,_0x27f366,_0x3298ae);}['createRenderingTextures'](_0x583bd2,_0x1008ad,_0x5ddd09){const _0x24d0a4=_0x5abd34,_0x3fe722={'context':_0x583bd2,'width':_0x583bd2['drawingBufferWidth'],'height':_0x583bd2['drawingBufferHeight'],'pixelFormat':Cesium$4[_0x24d0a4(0x26b)]['RGBA'],'pixelDatatype':Cesium$4['PixelDatatype']['UNSIGNED_BYTE']},_0x31237e={'context':_0x583bd2,'width':_0x583bd2['drawingBufferWidth'],'height':_0x583bd2['drawingBufferHeight'],'pixelFormat':Cesium$4['PixelFormat']['DEPTH_COMPONENT'],'pixelDatatype':Cesium$4['PixelDatatype'][_0x24d0a4(0x2a0)]},_0xbf5bbb=_0x5ddd09[_0x24d0a4(0x211)],_0x4ce848=new Float32Array(_0xbf5bbb*0x3);for(let _0x2eb089=0x0;_0x2eb089<_0xbf5bbb;_0x2eb089++){const _0x363368=Cesium$4[_0x24d0a4(0x258)]['fromCssColorString'](_0x5ddd09[_0x2eb089]);_0x4ce848[0x3*_0x2eb089]=_0x363368['red'],_0x4ce848[0x3*_0x2eb089+0x1]=_0x363368['green'],_0x4ce848[0x3*_0x2eb089+0x2]=_0x363368['blue'];}const _0x2b0af8={'context':_0x583bd2,'width':_0xbf5bbb,'height':0x1,'pixelFormat':Cesium$4['PixelFormat']['RGB'],'pixelDatatype':Cesium$4['PixelDatatype'][_0x24d0a4(0x22a)],'sampler':new Cesium$4[(_0x24d0a4(0x2aa))]({'minificationFilter':Cesium$4['TextureMinificationFilter']['LINEAR'],'magnificationFilter':Cesium$4[_0x24d0a4(0x29f)][_0x24d0a4(0x1f4)]})};this['textures']={'segmentsColor':Util['createTexture'](_0x3fe722),'segmentsDepth':Util['createTexture'](_0x31237e),'currentTrailsColor':Util['createTexture'](_0x3fe722),'currentTrailsDepth':Util[_0x24d0a4(0x24e)](_0x31237e),'nextTrailsColor':Util['createTexture'](_0x3fe722),'nextTrailsDepth':Util['createTexture'](_0x31237e),'colorTable':Util['createTexture'](_0x2b0af8,_0x4ce848)};}['createRenderingFramebuffers'](_0x52d481){const _0xc54fc=_0x5abd34;this['framebuffers']={'segments':Util['createFramebuffer'](_0x52d481,this['textures']['segmentsColor'],this['textures']['segmentsDepth']),'currentTrails':Util['createFramebuffer'](_0x52d481,this[_0xc54fc(0x1d2)][_0xc54fc(0x293)],this['textures']['currentTrailsDepth']),'nextTrails':Util['createFramebuffer'](_0x52d481,this['textures']['nextTrailsColor'],this['textures']['nextTrailsDepth'])};}['createSegmentsGeometry'](_0x1e1303){const _0x58b3c5=_0x5abd34,_0x83f521=0x4;let _0x15fe82=[];for(let _0x5056b4=0x0;_0x5056b4<_0x1e1303['particlesTextureSize'];_0x5056b4++){for(let _0x3e740f=0x0;_0x3e740f<_0x1e1303['particlesTextureSize'];_0x3e740f++){for(let _0x5d683a=0x0;_0x5d683a<_0x83f521;_0x5d683a++){_0x15fe82[_0x58b3c5(0x1cf)](_0x5056b4/_0x1e1303[_0x58b3c5(0x1be)]),_0x15fe82['push'](_0x3e740f/_0x1e1303['particlesTextureSize']);}}}_0x15fe82=new Float32Array(_0x15fe82);let _0x31077b=[];const _0xd2c71b=[-0x1,0x1],_0x11a623=[-0x1,0x1];for(let _0x14af76=0x0;_0x14af76<_0x1e1303[_0x58b3c5(0x287)];_0x14af76++){for(let _0x301998=0x0;_0x301998<_0x83f521/0x2;_0x301998++){for(let _0xfed863=0x0;_0xfed863<_0x83f521/0x2;_0xfed863++){_0x31077b['push'](_0xd2c71b[_0x301998]),_0x31077b['push'](_0x11a623[_0xfed863]),_0x31077b['push'](0x0);}}}_0x31077b=new Float32Array(_0x31077b);const _0x52c716=0x6*_0x1e1303['maxParticles'],_0xde4b39=new Uint32Array(_0x52c716);for(let _0x2d9d0e=0x0,_0x50bc7b=0x0,_0x5e2493=0x0;_0x2d9d0e<_0x1e1303[_0x58b3c5(0x287)];_0x2d9d0e++){_0xde4b39[_0x50bc7b++]=_0x5e2493+0x0,_0xde4b39[_0x50bc7b++]=_0x5e2493+0x1,_0xde4b39[_0x50bc7b++]=_0x5e2493+0x2,_0xde4b39[_0x50bc7b++]=_0x5e2493+0x2,_0xde4b39[_0x50bc7b++]=_0x5e2493+0x1,_0xde4b39[_0x50bc7b++]=_0x5e2493+0x3,_0x5e2493+=0x4;}const _0x10b77a=new Cesium$4[(_0x58b3c5(0x218))]({'attributes':new Cesium$4['GeometryAttributes']({'st':new Cesium$4['GeometryAttribute']({'componentDatatype':Cesium$4['ComponentDatatype']['FLOAT'],'componentsPerAttribute':0x2,'values':_0x15fe82}),'normal':new Cesium$4['GeometryAttribute']({'componentDatatype':Cesium$4['ComponentDatatype']['FLOAT'],'componentsPerAttribute':0x3,'values':_0x31077b})}),'indices':_0xde4b39});return _0x10b77a;}[_0x5abd34(0x228)](_0x3374c2,_0x2bf895,_0x34552b,_0x7ec0ec){const _0x432da6=_0x5abd34,_0x2ceb83=this;this['primitives']={'segments':new CustomPrimitive({'commandType':_0x432da6(0x1ed),'attributeLocations':{'st':0x0,'normal':0x1},'geometry':this[_0x432da6(0x212)](_0x2bf895),'primitiveType':Cesium$4[_0x432da6(0x284)]['TRIANGLES'],'uniformMap':{'currentParticlesPosition':function(){return _0x7ec0ec['particlesTextures']['currentParticlesPosition'];},'postProcessingPosition':function(){const _0x18c0c8=_0x432da6;return _0x7ec0ec[_0x18c0c8(0x206)]['postProcessingPosition'];},'postProcessingSpeed':function(){const _0x20281e=_0x432da6;return _0x7ec0ec['particlesTextures'][_0x20281e(0x1e4)];},'colorTable':function(){return _0x2ceb83['textures']['colorTable'];},'aspect':function(){return _0x3374c2['drawingBufferWidth']/_0x3374c2['drawingBufferHeight'];},'pixelSize':function(){return _0x34552b['pixelSize'];},'lineWidth':function(){return _0x2bf895['lineWidth'];},'particleHeight':function(){return _0x2bf895['particleHeight'];}},'vertexShaderSource':new Cesium$4['ShaderSource']({'sources':[segmentDraw_vert]}),'fragmentShaderSource':new Cesium$4['ShaderSource']({'sources':[segmentDraw_frag]}),'rawRenderState':Util['createRawRenderState']({'viewport':undefined,'depthTest':{'enabled':!![]},'depthMask':!![]}),'framebuffer':this['framebuffers']['segments'],'autoClear':!![]}),'trails':new CustomPrimitive({'commandType':'Draw','attributeLocations':{'position':0x0,'st':0x1},'geometry':Util['getFullscreenQuad'](),'primitiveType':Cesium$4['PrimitiveType'][_0x432da6(0x1ff)],'uniformMap':{'segmentsColorTexture':function(){const _0x21ad54=_0x432da6;return _0x2ceb83[_0x21ad54(0x1d2)]['segmentsColor'];},'segmentsDepthTexture':function(){const _0x30d768=_0x432da6;return _0x2ceb83[_0x30d768(0x1d2)]['segmentsDepth'];},'currentTrailsColor':function(){return _0x2ceb83['framebuffers']['currentTrails']['getColorTexture'](0x0);},'trailsDepthTexture':function(){return _0x2ceb83['framebuffers']['currentTrails']['depthTexture'];},'fadeOpacity':function(){const _0x8d6d3e=_0x432da6;return _0x2bf895[_0x8d6d3e(0x1f3)];}},'vertexShaderSource':new Cesium$4['ShaderSource']({'defines':['DISABLE_GL_POSITION_LOG_DEPTH'],'sources':[fullscreen_vert]}),'fragmentShaderSource':new Cesium$4['ShaderSource']({'defines':[_0x432da6(0x270)],'sources':[trailDraw_frag]}),'rawRenderState':Util['createRawRenderState']({'viewport':undefined,'depthTest':{'enabled':!![],'func':Cesium$4[_0x432da6(0x1c0)][_0x432da6(0x257)]},'depthMask':!![]}),'framebuffer':this['framebuffers'][_0x432da6(0x1cb)],'autoClear':!![],'preExecute':function(){const _0x5e73db=_0x432da6,_0x198c68=_0x2ceb83['framebuffers'][_0x5e73db(0x25c)];_0x2ceb83[_0x5e73db(0x20c)]['currentTrails']=_0x2ceb83['framebuffers']['nextTrails'],_0x2ceb83['framebuffers']['nextTrails']=_0x198c68,_0x2ceb83['primitives']['trails']['commandToExecute'][_0x5e73db(0x275)]=_0x2ceb83['framebuffers'][_0x5e73db(0x1cb)],_0x2ceb83['primitives']['trails']['clearCommand'][_0x5e73db(0x275)]=_0x2ceb83['framebuffers']['nextTrails'];}}),'screen':new CustomPrimitive({'commandType':'Draw','attributeLocations':{'position':0x0,'st':0x1},'geometry':Util['getFullscreenQuad'](),'primitiveType':Cesium$4['PrimitiveType']['TRIANGLES'],'uniformMap':{'trailsColorTexture':function(){return _0x2ceb83['framebuffers']['nextTrails']['getColorTexture'](0x0);},'trailsDepthTexture':function(){return _0x2ceb83['framebuffers']['nextTrails']['depthTexture'];}},'vertexShaderSource':new Cesium$4['ShaderSource']({'defines':['DISABLE_GL_POSITION_LOG_DEPTH'],'sources':[fullscreen_vert]}),'fragmentShaderSource':new Cesium$4['ShaderSource']({'defines':[_0x432da6(0x270)],'sources':[screenDraw_frag]}),'rawRenderState':Util['createRawRenderState']({'viewport':undefined,'depthTest':{'enabled':![]},'depthMask':!![],'blending':{'enabled':!![]}}),'framebuffer':undefined})};}}var getWind_frag='//\x20the\x20size\x20of\x20UV\x20textures:\x20width\x20=\x20lon,\x20height\x20=\x20lat*lev\x0auniform\x20sampler2D\x20U;\x20//\x20eastward\x20wind\x0auniform\x20sampler2D\x20V;\x20//\x20northward\x20wind\x0a\x0auniform\x20sampler2D\x20currentParticlesPosition;\x20//\x20(lon,\x20lat,\x20lev)\x0a\x0auniform\x20vec3\x20dimension;\x20//\x20(lon,\x20lat,\x20lev)\x0auniform\x20vec3\x20minimum;\x20//\x20minimum\x20of\x20each\x20dimension\x0auniform\x20vec3\x20maximum;\x20//\x20maximum\x20of\x20each\x20dimension\x0auniform\x20vec3\x20interval;\x20//\x20interval\x20of\x20each\x20dimension\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0avec2\x20mapPositionToNormalizedIndex2D(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20ensure\x20the\x20range\x20of\x20longitude\x20and\x20latitude\x0a\x20\x20\x20\x20lonLatLev.x\x20=\x20mod(lonLatLev.x,\x20360.0);\x0a\x20\x20\x20\x20lonLatLev.y\x20=\x20clamp(lonLatLev.y,\x20-90.0,\x2090.0);\x0a\x0a\x20\x20\x20\x20vec3\x20index3D\x20=\x20vec3(0.0);\x0a\x20\x20\x20\x20index3D.x\x20=\x20(lonLatLev.x\x20-\x20minimum.x)\x20/\x20interval.x;\x0a\x20\x20\x20\x20index3D.y\x20=\x20(lonLatLev.y\x20-\x20minimum.y)\x20/\x20interval.y;\x0a\x20\x20\x20\x20index3D.z\x20=\x20(lonLatLev.z\x20-\x20minimum.z)\x20/\x20interval.z;\x0a\x0a\x20\x20\x20\x20//\x20the\x20st\x20texture\x20coordinate\x20corresponding\x20to\x20(col,\x20row)\x20index\x0a\x20\x20\x20\x20//\x20example\x0a\x20\x20\x20\x20//\x20data\x20array\x20is\x20[0,\x201,\x202,\x203,\x204,\x205],\x20width\x20=\x203,\x20height\x20=\x202\x0a\x20\x20\x20\x20//\x20the\x20content\x20of\x20texture\x20will\x20be\x0a\x20\x20\x20\x20//\x20t\x201.0\x0a\x20\x20\x20\x20//\x20\x20\x20\x20|\x20\x203\x204\x205\x0a\x20\x20\x20\x20//\x20\x20\x20\x20|\x0a\x20\x20\x20\x20//\x20\x20\x20\x20|\x20\x200\x201\x202\x0a\x20\x20\x20\x20//\x20\x20\x200.0------1.0\x20s\x0a\x0a\x20\x20\x20\x20vec2\x20index2D\x20=\x20vec2(index3D.x,\x20index3D.z\x20*\x20dimension.y\x20+\x20index3D.y);\x0a\x20\x20\x20\x20vec2\x20normalizedIndex2D\x20=\x20vec2(index2D.x\x20/\x20dimension.x,\x20index2D.y\x20/\x20(dimension.y\x20*\x20dimension.z));\x0a\x20\x20\x20\x20return\x20normalizedIndex2D;\x0a}\x0a\x0afloat\x20getWind(sampler2D\x20windTexture,\x20vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20vec2\x20normalizedIndex2D\x20=\x20mapPositionToNormalizedIndex2D(lonLatLev);\x0a\x20\x20\x20\x20float\x20result\x20=\x20texture(windTexture,\x20normalizedIndex2D).r;\x0a\x20\x20\x20\x20return\x20result;\x0a}\x0a\x0aconst\x20mat4\x20kernelMatrix\x20=\x20mat4(\x0a\x20\x20\x20\x200.0,\x20-1.0,\x202.0,\x20-1.0,\x20//\x20first\x20column\x0a\x20\x20\x20\x202.0,\x200.0,\x20-5.0,\x203.0,\x20//\x20second\x20column\x0a\x20\x20\x20\x200.0,\x201.0,\x204.0,\x20-3.0,\x20//\x20third\x20column\x0a\x20\x20\x20\x200.0,\x200.0,\x20-1.0,\x201.0\x20//\x20fourth\x20column\x0a);\x0afloat\x20oneDimensionInterpolation(float\x20t,\x20float\x20p0,\x20float\x20p1,\x20float\x20p2,\x20float\x20p3)\x20{\x0a\x20\x20\x20\x20vec4\x20tVec4\x20=\x20vec4(1.0,\x20t,\x20t\x20*\x20t,\x20t\x20*\x20t\x20*\x20t);\x0a\x20\x20\x20\x20tVec4\x20=\x20tVec4\x20/\x202.0;\x0a\x20\x20\x20\x20vec4\x20pVec4\x20=\x20vec4(p0,\x20p1,\x20p2,\x20p3);\x0a\x20\x20\x20\x20return\x20dot((tVec4\x20*\x20kernelMatrix),\x20pVec4);\x0a}\x0a\x0afloat\x20calculateB(sampler2D\x20windTexture,\x20float\x20t,\x20float\x20lon,\x20float\x20lat,\x20float\x20lev)\x20{\x0a\x20\x20\x20\x20float\x20lon0\x20=\x20floor(lon)\x20-\x201.0\x20*\x20interval.x;\x0a\x20\x20\x20\x20float\x20lon1\x20=\x20floor(lon);\x0a\x20\x20\x20\x20float\x20lon2\x20=\x20floor(lon)\x20+\x201.0\x20*\x20interval.x;\x0a\x20\x20\x20\x20float\x20lon3\x20=\x20floor(lon)\x20+\x202.0\x20*\x20interval.x;\x0a\x0a\x20\x20\x20\x20float\x20p0\x20=\x20getWind(windTexture,\x20vec3(lon0,\x20lat,\x20lev));\x0a\x20\x20\x20\x20float\x20p1\x20=\x20getWind(windTexture,\x20vec3(lon1,\x20lat,\x20lev));\x0a\x20\x20\x20\x20float\x20p2\x20=\x20getWind(windTexture,\x20vec3(lon2,\x20lat,\x20lev));\x0a\x20\x20\x20\x20float\x20p3\x20=\x20getWind(windTexture,\x20vec3(lon3,\x20lat,\x20lev));\x0a\x0a\x20\x20\x20\x20return\x20oneDimensionInterpolation(t,\x20p0,\x20p1,\x20p2,\x20p3);\x0a}\x0a\x0afloat\x20interpolateOneTexture(sampler2D\x20windTexture,\x20vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20float\x20lon\x20=\x20lonLatLev.x;\x0a\x20\x20\x20\x20float\x20lat\x20=\x20lonLatLev.y;\x0a\x20\x20\x20\x20float\x20lev\x20=\x20lonLatLev.z;\x0a\x0a\x20\x20\x20\x20float\x20lat0\x20=\x20floor(lat)\x20-\x201.0\x20*\x20interval.y;\x0a\x20\x20\x20\x20float\x20lat1\x20=\x20floor(lat);\x0a\x20\x20\x20\x20float\x20lat2\x20=\x20floor(lat)\x20+\x201.0\x20*\x20interval.y;\x0a\x20\x20\x20\x20float\x20lat3\x20=\x20floor(lat)\x20+\x202.0\x20*\x20interval.y;\x0a\x0a\x20\x20\x20\x20vec2\x20coefficient\x20=\x20lonLatLev.xy\x20-\x20floor(lonLatLev.xy);\x0a\x20\x20\x20\x20float\x20b0\x20=\x20calculateB(windTexture,\x20coefficient.x,\x20lon,\x20lat0,\x20lev);\x0a\x20\x20\x20\x20float\x20b1\x20=\x20calculateB(windTexture,\x20coefficient.x,\x20lon,\x20lat1,\x20lev);\x0a\x20\x20\x20\x20float\x20b2\x20=\x20calculateB(windTexture,\x20coefficient.x,\x20lon,\x20lat2,\x20lev);\x0a\x20\x20\x20\x20float\x20b3\x20=\x20calculateB(windTexture,\x20coefficient.x,\x20lon,\x20lat3,\x20lev);\x0a\x0a\x20\x20\x20\x20return\x20oneDimensionInterpolation(coefficient.y,\x20b0,\x20b1,\x20b2,\x20b3);\x0a}\x0a\x0avec3\x20bicubic(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20https://en.wikipedia.org/wiki/Bicubic_interpolation#Bicubic_convolution_algorithm\x0a\x20\x20\x20\x20float\x20u\x20=\x20interpolateOneTexture(U,\x20lonLatLev);\x0a\x20\x20\x20\x20float\x20v\x20=\x20interpolateOneTexture(V,\x20lonLatLev);\x0a\x20\x20\x20\x20float\x20w\x20=\x200.0;\x0a\x20\x20\x20\x20return\x20vec3(u,\x20v,\x20w);\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20//\x20texture\x20coordinate\x20must\x20be\x20normalized\x0a\x20\x20\x20\x20vec3\x20lonLatLev\x20=\x20texture(currentParticlesPosition,\x20v_textureCoordinates).rgb;\x0a\x20\x20\x20\x20vec3\x20windVector\x20=\x20bicubic(lonLatLev);\x0a\x20\x20\x20\x20out_FragColor\x20=\x20vec4(windVector,\x200.0);\x0a}\x0a',updateSpeed_frag=_0x5abd34(0x263),updatePosition_frag='uniform\x20sampler2D\x20currentParticlesPosition;\x20//\x20(lon,\x20lat,\x20lev)\x0auniform\x20sampler2D\x20currentParticlesSpeed;\x20//\x20(u,\x20v,\x20w,\x20normalization)\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0avec2\x20lengthOfLonLat(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20unit\x20conversion:\x20meters\x20->\x20longitude\x20latitude\x20degrees\x0a\x20\x20\x20\x20//\x20see\x20https://en.wikipedia.org/wiki/Geographic_coordinate_system#Length_of_a_degree\x20for\x20detail\x0a\x0a\x20\x20\x20\x20//\x20Calculate\x20the\x20length\x20of\x20a\x20degree\x20of\x20latitude\x20and\x20longitude\x20in\x20meters\x0a\x20\x20\x20\x20float\x20latitude\x20=\x20radians(lonLatLev.y);\x0a\x0a\x20\x20\x20\x20float\x20term1\x20=\x20111132.92;\x0a\x20\x20\x20\x20float\x20term2\x20=\x20559.82\x20*\x20cos(2.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20term3\x20=\x201.175\x20*\x20cos(4.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20term4\x20=\x200.0023\x20*\x20cos(6.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20latLength\x20=\x20term1\x20-\x20term2\x20+\x20term3\x20-\x20term4;\x0a\x0a\x20\x20\x20\x20float\x20term5\x20=\x20111412.84\x20*\x20cos(latitude);\x0a\x20\x20\x20\x20float\x20term6\x20=\x2093.5\x20*\x20cos(3.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20term7\x20=\x200.118\x20*\x20cos(5.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20longLength\x20=\x20term5\x20-\x20term6\x20+\x20term7;\x0a\x0a\x20\x20\x20\x20return\x20vec2(longLength,\x20latLength);\x0a}\x0a\x0avoid\x20updatePosition(vec3\x20lonLatLev,\x20vec3\x20speed)\x20{\x0a\x20\x20\x20\x20vec2\x20lonLatLength\x20=\x20lengthOfLonLat(lonLatLev);\x0a\x20\x20\x20\x20float\x20u\x20=\x20speed.x\x20/\x20lonLatLength.x;\x0a\x20\x20\x20\x20float\x20v\x20=\x20speed.y\x20/\x20lonLatLength.y;\x0a\x20\x20\x20\x20float\x20w\x20=\x200.0;\x0a\x20\x20\x20\x20vec3\x20windVectorInLonLatLev\x20=\x20vec3(u,\x20v,\x20w);\x0a\x0a\x20\x20\x20\x20vec3\x20nextParticle\x20=\x20lonLatLev\x20+\x20windVectorInLonLatLev;\x0a\x0a\x20\x20\x20\x20out_FragColor\x20=\x20vec4(nextParticle,\x200.0);\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20//\x20texture\x20coordinate\x20must\x20be\x20normalized\x0a\x20\x20\x20\x20vec3\x20lonLatLev\x20=\x20texture(currentParticlesPosition,\x20v_textureCoordinates).rgb;\x0a\x20\x20\x20\x20vec3\x20speed\x20=\x20texture(currentParticlesSpeed,\x20v_textureCoordinates).rgb;\x0a\x0a\x20\x20\x20\x20updatePosition(lonLatLev,\x20speed);\x0a}\x0a',postProcessingPosition_frag='uniform\x20sampler2D\x20nextParticlesPosition;\x0auniform\x20sampler2D\x20nextParticlesSpeed;\x20//\x20(u,\x20v,\x20w,\x20normalization)\x0a\x0a//\x20range\x20(min,\x20max)\x0auniform\x20vec2\x20lonRange;\x0auniform\x20vec2\x20latRange;\x0a\x0auniform\x20float\x20randomCoefficient;\x20//\x20use\x20to\x20improve\x20the\x20pseudo-random\x20generator\x0auniform\x20float\x20dropRate;\x20//\x20drop\x20rate\x20is\x20a\x20chance\x20a\x20particle\x20will\x20restart\x20at\x20random\x20position\x20to\x20avoid\x20degeneration\x0auniform\x20float\x20dropRateBump;\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0a//\x20pseudo-random\x20generator\x0aconst\x20vec3\x20randomConstants\x20=\x20vec3(12.9898,\x2078.233,\x204375.85453);\x0aconst\x20vec2\x20normalRange\x20=\x20vec2(0.0,\x201.0);\x0afloat\x20rand(vec2\x20seed,\x20vec2\x20range)\x20{\x0a\x20\x20\x20\x20vec2\x20randomSeed\x20=\x20randomCoefficient\x20*\x20seed;\x0a\x20\x20\x20\x20float\x20temp\x20=\x20dot(randomConstants.xy,\x20randomSeed);\x0a\x20\x20\x20\x20temp\x20=\x20fract(sin(temp)\x20*\x20(randomConstants.z\x20+\x20temp));\x0a\x20\x20\x20\x20return\x20temp\x20*\x20(range.y\x20-\x20range.x)\x20+\x20range.x;\x0a}\x0a\x0avec3\x20generateRandomParticle(vec2\x20seed,\x20float\x20lev)\x20{\x0a\x20\x20\x20\x20//\x20ensure\x20the\x20longitude\x20is\x20in\x20[0,\x20360]\x0a\x20\x20\x20\x20float\x20randomLon\x20=\x20mod(rand(seed,\x20lonRange),\x20360.0);\x0a\x20\x20\x20\x20float\x20randomLat\x20=\x20rand(-seed,\x20latRange);\x0a\x0a\x20\x20\x20\x20return\x20vec3(randomLon,\x20randomLat,\x20lev);\x0a}\x0a\x0abool\x20particleOutbound(vec3\x20particle)\x20{\x0a\x20\x20\x20\x20return\x20particle.y\x20<\x20-90.0\x20||\x20particle.y\x20>\x2090.0;\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec3\x20nextParticle\x20=\x20texture(nextParticlesPosition,\x20v_textureCoordinates).rgb;\x0a\x20\x20\x20\x20vec4\x20nextSpeed\x20=\x20texture(nextParticlesSpeed,\x20v_textureCoordinates);\x0a\x20\x20\x20\x20float\x20particleDropRate\x20=\x20dropRate\x20+\x20dropRateBump\x20*\x20nextSpeed.a;\x0a\x0a\x20\x20\x20\x20vec2\x20seed1\x20=\x20nextParticle.xy\x20+\x20v_textureCoordinates;\x0a\x20\x20\x20\x20vec2\x20seed2\x20=\x20nextSpeed.xy\x20+\x20v_textureCoordinates;\x0a\x20\x20\x20\x20vec3\x20randomParticle\x20=\x20generateRandomParticle(seed1,\x20nextParticle.z);\x0a\x20\x20\x20\x20float\x20randomNumber\x20=\x20rand(seed2,\x20normalRange);\x0a\x0a\x20\x20\x20\x20if\x20(randomNumber\x20<\x20particleDropRate\x20||\x20particleOutbound(nextParticle))\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20vec4(randomParticle,\x201.0);\x20//\x201.0\x20means\x20this\x20is\x20a\x20random\x20particle\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20vec4(nextParticle,\x200.0);\x0a\x20\x20\x20\x20}\x0a}\x0a',postProcessingSpeed_frag='uniform\x20sampler2D\x20postProcessingPosition;\x0auniform\x20sampler2D\x20nextParticlesSpeed;\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec4\x20randomParticle\x20=\x20texture(postProcessingPosition,\x20v_textureCoordinates);\x0a\x20\x20\x20\x20vec4\x20particleSpeed\x20=\x20texture(nextParticlesSpeed,\x20v_textureCoordinates);\x0a\x0a\x20\x20\x20\x20if\x20(randomParticle.a\x20>\x200.0)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20particleSpeed;\x0a\x20\x20\x20\x20}\x0a}\x0a';const Cesium$3=mars3d__namespace['Cesium'];class ParticlesComputing{constructor(_0x35ad96,_0x58fc27,_0x9269d3,_0x2627dd){this['data']=_0x58fc27,this['createWindTextures'](_0x35ad96,_0x58fc27),this['createParticlesTextures'](_0x35ad96,_0x9269d3,_0x2627dd),this['createComputingPrimitives'](_0x58fc27,_0x9269d3,_0x2627dd);}['createWindTextures'](_0x7a5bcb,_0xde6a08){const _0x33edd0=_0x5abd34,_0x3aed08={'context':_0x7a5bcb,'width':_0xde6a08['dimensions']['lon'],'height':_0xde6a08[_0x33edd0(0x1d4)][_0x33edd0(0x216)]*(_0xde6a08['dimensions'][_0x33edd0(0x1dd)]||0x1),'pixelFormat':Cesium$3['PixelFormat']['LUMINANCE'],'pixelDatatype':Cesium$3['PixelDatatype'][_0x33edd0(0x22a)],'flipY':![],'sampler':new Cesium$3['Sampler']({'minificationFilter':Cesium$3['TextureMinificationFilter']['NEAREST'],'magnificationFilter':Cesium$3['TextureMagnificationFilter']['NEAREST']})};this['windTextures']={'U':Util['createTexture'](_0x3aed08,_0xde6a08['U']['array']),'V':Util['createTexture'](_0x3aed08,_0xde6a08['V']['array'])};}['createParticlesTextures'](_0x3fe1bb,_0x5c18eb,_0x420f81){const _0x2fadc1=_0x5abd34,_0x103c11={'context':_0x3fe1bb,'width':_0x5c18eb['particlesTextureSize'],'height':_0x5c18eb['particlesTextureSize'],'pixelFormat':Cesium$3['PixelFormat']['RGBA'],'pixelDatatype':Cesium$3['PixelDatatype']['FLOAT'],'flipY':![],'sampler':new Cesium$3[(_0x2fadc1(0x2aa))]({'minificationFilter':Cesium$3[_0x2fadc1(0x27c)][_0x2fadc1(0x217)],'magnificationFilter':Cesium$3['TextureMagnificationFilter']['NEAREST']})},_0x5160a2=this[_0x2fadc1(0x2af)](_0x5c18eb['maxParticles'],_0x420f81),_0x3476b9=new Float32Array(0x4*_0x5c18eb['maxParticles'])['fill'](0x0);this['particlesTextures']={'particlesWind':Util['createTexture'](_0x103c11),'currentParticlesPosition':Util['createTexture'](_0x103c11,_0x5160a2),'nextParticlesPosition':Util['createTexture'](_0x103c11,_0x5160a2),'currentParticlesSpeed':Util['createTexture'](_0x103c11,_0x3476b9),'nextParticlesSpeed':Util['createTexture'](_0x103c11,_0x3476b9),'postProcessingPosition':Util['createTexture'](_0x103c11,_0x5160a2),'postProcessingSpeed':Util['createTexture'](_0x103c11,_0x3476b9)};}[_0x5abd34(0x2af)](_0x1a7e3b,_0x34cb4c){const _0x2ca6a0=_0x5abd34,_0x156333=new Float32Array(0x4*_0x1a7e3b);for(let _0x162854=0x0;_0x162854<_0x1a7e3b;_0x162854++){_0x156333[0x4*_0x162854]=Cesium$3[_0x2ca6a0(0x20d)]['randomBetween'](_0x34cb4c['lonRange']['x'],_0x34cb4c['lonRange']['y']),_0x156333[0x4*_0x162854+0x1]=Cesium$3[_0x2ca6a0(0x20d)]['randomBetween'](_0x34cb4c['latRange']['x'],_0x34cb4c[_0x2ca6a0(0x204)]['y']),_0x156333[0x4*_0x162854+0x2]=Cesium$3['Math'][_0x2ca6a0(0x1c1)](this['data']['lev']['min'],this[_0x2ca6a0(0x279)][_0x2ca6a0(0x1dd)]['max']),_0x156333[0x4*_0x162854+0x3]=0x0;}return _0x156333;}[_0x5abd34(0x266)](){Object['keys'](this['particlesTextures'])['forEach'](_0x234d8c=>{this['particlesTextures'][_0x234d8c]['destroy']();});}[_0x5abd34(0x256)](_0x24dfa7,_0x229845,_0x594618){const _0xd3f233=_0x5abd34,_0x447e3f=new Cesium$3['Cartesian3'](_0x24dfa7['dimensions']['lon'],_0x24dfa7['dimensions'][_0xd3f233(0x216)],_0x24dfa7[_0xd3f233(0x1d4)][_0xd3f233(0x1dd)]),_0x1f71a9=new Cesium$3['Cartesian3'](_0x24dfa7['lon'][_0xd3f233(0x221)],_0x24dfa7['lat']['min'],_0x24dfa7[_0xd3f233(0x1dd)][_0xd3f233(0x221)]),_0xe35f66=new Cesium$3['Cartesian3'](_0x24dfa7[_0xd3f233(0x26d)]['max'],_0x24dfa7['lat']['max'],_0x24dfa7['lev'][_0xd3f233(0x25a)]),_0x1be843=new Cesium$3['Cartesian3']((_0xe35f66['x']-_0x1f71a9['x'])/(_0x447e3f['x']-0x1),(_0xe35f66['y']-_0x1f71a9['y'])/(_0x447e3f['y']-0x1),_0x447e3f['z']>0x1?(_0xe35f66['z']-_0x1f71a9['z'])/(_0x447e3f['z']-0x1):0x1),_0x2f131d=new Cesium$3['Cartesian2'](_0x24dfa7['U']['min'],_0x24dfa7['U']['max']),_0x30c66c=new Cesium$3['Cartesian2'](_0x24dfa7['V']['min'],_0x24dfa7['V']['max']),_0x556d35=this;this['primitives']={'getWind':new CustomPrimitive({'commandType':'Compute','uniformMap':{'U':function(){return _0x556d35['windTextures']['U'];},'V':function(){return _0x556d35['windTextures']['V'];},'currentParticlesPosition':function(){return _0x556d35['particlesTextures']['currentParticlesPosition'];},'dimension':function(){return _0x447e3f;},'minimum':function(){return _0x1f71a9;},'maximum':function(){return _0xe35f66;},'interval':function(){return _0x1be843;}},'fragmentShaderSource':new Cesium$3['ShaderSource']({'sources':[getWind_frag]}),'outputTexture':this['particlesTextures']['particlesWind'],'preExecute':function(){const _0x244d84=_0xd3f233;_0x556d35['primitives'][_0x244d84(0x25d)]['commandToExecute']['outputTexture']=_0x556d35['particlesTextures']['particlesWind'];}}),'updateSpeed':new CustomPrimitive({'commandType':_0xd3f233(0x1e2),'uniformMap':{'currentParticlesSpeed':function(){const _0x74823f=_0xd3f233;return _0x556d35[_0x74823f(0x206)][_0x74823f(0x269)];},'particlesWind':function(){const _0x25709b=_0xd3f233;return _0x556d35['particlesTextures'][_0x25709b(0x247)];},'uSpeedRange':function(){return _0x2f131d;},'vSpeedRange':function(){return _0x30c66c;},'pixelSize':function(){return _0x594618['pixelSize'];},'speedFactor':function(){const _0x5d38bf=_0xd3f233;return _0x229845[_0x5d38bf(0x23f)];}},'fragmentShaderSource':new Cesium$3[(_0xd3f233(0x1f5))]({'sources':[updateSpeed_frag]}),'outputTexture':this['particlesTextures']['nextParticlesSpeed'],'preExecute':function(){const _0x47dced=_0xd3f233,_0x5c5520=_0x556d35[_0x47dced(0x206)][_0x47dced(0x269)];_0x556d35[_0x47dced(0x206)][_0x47dced(0x269)]=_0x556d35['particlesTextures'][_0x47dced(0x1e4)],_0x556d35[_0x47dced(0x206)][_0x47dced(0x1e4)]=_0x5c5520,_0x556d35[_0x47dced(0x27b)]['updateSpeed']['commandToExecute']['outputTexture']=_0x556d35[_0x47dced(0x206)]['nextParticlesSpeed'];}}),'updatePosition':new CustomPrimitive({'commandType':'Compute','uniformMap':{'currentParticlesPosition':function(){const _0x3046bb=_0xd3f233;return _0x556d35['particlesTextures'][_0x3046bb(0x2a1)];},'currentParticlesSpeed':function(){return _0x556d35['particlesTextures']['currentParticlesSpeed'];}},'fragmentShaderSource':new Cesium$3['ShaderSource']({'sources':[updatePosition_frag]}),'outputTexture':this['particlesTextures']['nextParticlesPosition'],'preExecute':function(){const _0x433cab=_0xd3f233,_0x2262f8=_0x556d35['particlesTextures'][_0x433cab(0x2a1)];_0x556d35['particlesTextures'][_0x433cab(0x2a1)]=_0x556d35[_0x433cab(0x206)]['postProcessingPosition'],_0x556d35['particlesTextures'][_0x433cab(0x1ef)]=_0x2262f8,_0x556d35['primitives'][_0x433cab(0x29a)]['commandToExecute'][_0x433cab(0x229)]=_0x556d35[_0x433cab(0x206)]['nextParticlesPosition'];}}),'postProcessingPosition':new CustomPrimitive({'commandType':'Compute','uniformMap':{'nextParticlesPosition':function(){return _0x556d35['particlesTextures']['nextParticlesPosition'];},'nextParticlesSpeed':function(){const _0x17fdc8=_0xd3f233;return _0x556d35['particlesTextures'][_0x17fdc8(0x21d)];},'lonRange':function(){const _0x34a54f=_0xd3f233;return _0x594618[_0x34a54f(0x21e)];},'latRange':function(){return _0x594618['latRange'];},'randomCoefficient':function(){const _0x1b7115=Math['random']();return _0x1b7115;},'dropRate':function(){const _0x1c2405=_0xd3f233;return _0x229845[_0x1c2405(0x1e1)];},'dropRateBump':function(){const _0x4aee32=_0xd3f233;return _0x229845[_0x4aee32(0x26a)];}},'fragmentShaderSource':new Cesium$3['ShaderSource']({'sources':[postProcessingPosition_frag]}),'outputTexture':this[_0xd3f233(0x206)][_0xd3f233(0x1ef)],'preExecute':function(){const _0x2b1416=_0xd3f233;_0x556d35['primitives'][_0x2b1416(0x1ef)]['commandToExecute']['outputTexture']=_0x556d35[_0x2b1416(0x206)]['postProcessingPosition'];}}),'postProcessingSpeed':new CustomPrimitive({'commandType':'Compute','uniformMap':{'postProcessingPosition':function(){const _0x3e8fb7=_0xd3f233;return _0x556d35['particlesTextures'][_0x3e8fb7(0x1ef)];},'nextParticlesSpeed':function(){const _0x86098f=_0xd3f233;return _0x556d35[_0x86098f(0x206)][_0x86098f(0x21d)];}},'fragmentShaderSource':new Cesium$3['ShaderSource']({'sources':[postProcessingSpeed_frag]}),'outputTexture':this['particlesTextures']['postProcessingSpeed'],'preExecute':function(){const _0x3980bf=_0xd3f233;_0x556d35['primitives'][_0x3980bf(0x1e4)]['commandToExecute']['outputTexture']=_0x556d35['particlesTextures'][_0x3980bf(0x1e4)];}})};}}const Cesium$2=mars3d__namespace[_0x5abd34(0x219)];class ParticleSystem{constructor(_0xfa98ea,_0x1b4d57,_0x2aed25,_0x3338a3){const _0x250f57=_0x5abd34;this[_0x250f57(0x209)]=_0xfa98ea,_0x1b4d57={..._0x1b4d57},_0x1b4d57['udata']&&_0x1b4d57['vdata']&&(_0x1b4d57['dimensions']={},_0x1b4d57['dimensions'][_0x250f57(0x26d)]=_0x1b4d57['cols'],_0x1b4d57['dimensions'][_0x250f57(0x216)]=_0x1b4d57[_0x250f57(0x262)],_0x1b4d57['dimensions']['lev']=_0x1b4d57[_0x250f57(0x1dd)]||0x1,_0x1b4d57[_0x250f57(0x26d)]={},_0x1b4d57[_0x250f57(0x26d)][_0x250f57(0x221)]=_0x1b4d57['xmin'],_0x1b4d57[_0x250f57(0x26d)][_0x250f57(0x25a)]=_0x1b4d57[_0x250f57(0x1c9)],_0x1b4d57['lat']={},_0x1b4d57['lat']['min']=_0x1b4d57['ymin'],_0x1b4d57[_0x250f57(0x216)]['max']=_0x1b4d57['ymax'],_0x1b4d57['lev']={},_0x1b4d57[_0x250f57(0x1dd)]['min']=_0x1b4d57['levmin']??0x1,_0x1b4d57[_0x250f57(0x1dd)]['max']=_0x1b4d57[_0x250f57(0x2a8)]??0x1,_0x1b4d57['U']={},_0x1b4d57['U']['array']=new Float32Array(_0x1b4d57[_0x250f57(0x260)]),_0x1b4d57['U'][_0x250f57(0x221)]=_0x1b4d57[_0x250f57(0x261)]??Math['min'](..._0x1b4d57['udata']),_0x1b4d57['U']['max']=_0x1b4d57[_0x250f57(0x241)]??Math[_0x250f57(0x25a)](..._0x1b4d57['udata']),_0x1b4d57['V']={},_0x1b4d57['V']['array']=new Float32Array(_0x1b4d57['vdata']),_0x1b4d57['V']['min']=_0x1b4d57['vmin']??Math['min'](..._0x1b4d57['vdata']),_0x1b4d57['V']['max']=_0x1b4d57[_0x250f57(0x27e)]??Math[_0x250f57(0x25a)](..._0x1b4d57['vdata'])),this[_0x250f57(0x279)]=_0x1b4d57,this['options']=_0x2aed25,this[_0x250f57(0x1ee)]=_0x3338a3,this[_0x250f57(0x250)]=new ParticlesComputing(this['context'],this['data'],this['options'],this['viewerParameters']),this['particlesRendering']=new ParticlesRendering(this[_0x250f57(0x209)],this['data'],this['options'],this['viewerParameters'],this['particlesComputing']);}[_0x5abd34(0x1c6)](_0x4fb835){const _0x3ec7=_0x5abd34;this[_0x3ec7(0x250)]['destroyParticlesTextures'](),Object['keys'](this['particlesComputing']['windTextures'])['forEach'](_0x420477=>{this['particlesComputing']['windTextures'][_0x420477]['destroy']();}),this[_0x3ec7(0x210)]['textures'][_0x3ec7(0x288)]['destroy'](),Object['keys'](this[_0x3ec7(0x210)]['framebuffers'])['forEach'](_0x5e1f04=>{const _0x1410e7=_0x3ec7;this[_0x1410e7(0x210)]['framebuffers'][_0x5e1f04]['destroy']();}),this['context']=_0x4fb835,this['particlesComputing']=new ParticlesComputing(this['context'],this['data'],this[_0x3ec7(0x20f)],this[_0x3ec7(0x1ee)]),this[_0x3ec7(0x210)]=new ParticlesRendering(this['context'],this['data'],this['options'],this['viewerParameters'],this[_0x3ec7(0x250)]);}['clearFramebuffers'](){const _0x442db7=_0x5abd34,_0x128402=new Cesium$2[(_0x442db7(0x200))]({'color':new Cesium$2['Color'](0x0,0x0,0x0,0x0),'depth':0x1,'framebuffer':undefined,'pass':Cesium$2['Pass']['OPAQUE']});Object['keys'](this['particlesRendering']['framebuffers'])[_0x442db7(0x1fb)](_0x547497=>{const _0x90740c=_0x442db7;_0x128402['framebuffer']=this['particlesRendering']['framebuffers'][_0x547497],_0x128402['execute'](this[_0x90740c(0x209)]);});}['refreshParticles'](_0x427fbb){const _0x59daf7=_0x5abd34;this[_0x59daf7(0x297)](),this['particlesComputing'][_0x59daf7(0x266)](),this['particlesComputing'][_0x59daf7(0x203)](this['context'],this['options'],this['viewerParameters']);if(_0x427fbb){var _0x26137d;const _0x5cec58=this['particlesRendering']['createSegmentsGeometry'](this['options']);this[_0x59daf7(0x210)][_0x59daf7(0x27b)]['segments']['geometry']=_0x5cec58;const _0x1643b9=Cesium$2['VertexArray'][_0x59daf7(0x1d8)]({'context':this[_0x59daf7(0x209)],'geometry':_0x5cec58,'attributeLocations':this[_0x59daf7(0x210)][_0x59daf7(0x27b)]['segments']['attributeLocations'],'bufferUsage':Cesium$2['BufferUsage']['STATIC_DRAW']});(_0x26137d=this['particlesRendering']['primitives'])!==null&&_0x26137d!==void 0x0&&(_0x26137d=_0x26137d[_0x59daf7(0x20b)])!==null&&_0x26137d!==void 0x0&&_0x26137d[_0x59daf7(0x23e)]&&(this['particlesRendering']['primitives']['segments']['commandToExecute']['vertexArray']=_0x1643b9);}}[_0x5abd34(0x242)](_0x349530){let _0x280501=![];this['options']['maxParticles']!==_0x349530['maxParticles']&&(_0x280501=!![]),Object['keys'](_0x349530)['forEach'](_0xbe6fe=>{const _0x354c3c=_0x411b;this[_0x354c3c(0x20f)][_0xbe6fe]=_0x349530[_0xbe6fe];}),this['refreshParticles'](_0x280501);}['applyViewerParameters'](_0x48c4d0){Object['keys'](_0x48c4d0)['forEach'](_0xf3cce9=>{this['viewerParameters'][_0xf3cce9]=_0x48c4d0[_0xf3cce9];}),this['refreshParticles'](![]);}['destroy'](){const _0xa5547a=_0x5abd34;clearTimeout(this['canrefresh']),this['particlesComputing']['destroyParticlesTextures'](),Object['keys'](this['particlesComputing'][_0xa5547a(0x21f)])[_0xa5547a(0x1fb)](_0xaf34b1=>{const _0x106f1d=_0xa5547a;this['particlesComputing'][_0x106f1d(0x21f)][_0xaf34b1]['destroy']();}),this['particlesRendering'][_0xa5547a(0x1d2)]['colorTable']['destroy'](),Object['keys'](this['particlesRendering']['framebuffers'])[_0xa5547a(0x1fb)](_0x3ebf23=>{const _0x4620c5=_0xa5547a;this[_0x4620c5(0x210)]['framebuffers'][_0x3ebf23]['destroy']();});for(const _0x45e2c2 in this){delete this[_0x45e2c2];}}}const Cesium$1=mars3d__namespace['Cesium'],BaseLayer$1=mars3d__namespace[_0x5abd34(0x27d)]['BaseLayer'],DEF_OPTIONS={'particlesNumber':0x1000,'fixedHeight':0x0,'fadeOpacity':0.996,'dropRate':0.003,'dropRateBump':0.01,'speedFactor':0.5,'lineWidth':0x2,'colors':['rgb(206,255,255)']};class WindLayer extends BaseLayer$1{constructor(_0x319482={}){_0x319482={...DEF_OPTIONS,..._0x319482},super(_0x319482),this['_setOptionsHook'](_0x319482);}get['layer'](){return this['primitives'];}get[_0x5abd34(0x279)](){const _0x52fffc=_0x5abd34;return this[_0x52fffc(0x22c)];}set[_0x5abd34(0x279)](_0x2c29da){const _0x2c7f2a=_0x5abd34;this[_0x2c7f2a(0x25e)](_0x2c29da);}get[_0x5abd34(0x226)](){const _0x24b07a=_0x5abd34;return this[_0x24b07a(0x20f)][_0x24b07a(0x226)];}set['colors'](_0x4aeeba){const _0x659ff0=_0x5abd34;this['options']['colors']=_0x4aeeba,this[_0x659ff0(0x240)]&&this[_0x659ff0(0x240)][_0x659ff0(0x242)]({'colors':_0x4aeeba}),this[_0x659ff0(0x1e0)]();}['_mountedHook'](){}['_addedHook'](){const _0x4f5a17=_0x5abd34;this['scene']=this[_0x4f5a17(0x22e)]['scene'],this['camera']=this['_map'][_0x4f5a17(0x237)],this['primitives']=new Cesium$1['PrimitiveCollection'](),this['_map'][_0x4f5a17(0x273)]['primitives']['add'](this['primitives']),this[_0x4f5a17(0x1ee)]={'lonRange':new Cesium$1[(_0x4f5a17(0x24a))](),'latRange':new Cesium$1[(_0x4f5a17(0x24a))](),'pixelSize':0x0},this['globeBoundingSphere']=new Cesium$1[(_0x4f5a17(0x253))](Cesium$1[_0x4f5a17(0x201)]['ZERO'],0.99*0x615299),this[_0x4f5a17(0x285)](),window['addEventListener']('resize',this['resize']['bind'](this),![]),this[_0x4f5a17(0x1f7)]=![],this['mouse_move']=![],this['_map']['on'](mars3d__namespace['EventType'][_0x4f5a17(0x29e)],this['_onMapWhellEvent'],this),this[_0x4f5a17(0x22e)]['on'](mars3d__namespace['EventType']['mouseDown'],this['_onMouseDownEvent'],this),this['_map']['on'](mars3d__namespace['EventType']['mouseUp'],this['_onMouseUpEvent'],this),this['_map']['on'](mars3d__namespace[_0x4f5a17(0x1d6)]['mouseMove'],this[_0x4f5a17(0x274)],this),this['_data']&&this[_0x4f5a17(0x25e)](this[_0x4f5a17(0x22c)]);}[_0x5abd34(0x20e)](){const _0x6fa66d=_0x5abd34;window['removeEventListener']('resize',this['resize']),this[_0x6fa66d(0x22e)]['off'](mars3d__namespace[_0x6fa66d(0x1d6)][_0x6fa66d(0x244)],this['_onMap_preRenderEvent'],this),this['_map']['off'](mars3d__namespace['EventType']['wheel'],this['_onMapWhellEvent'],this),this['_map'][_0x6fa66d(0x1da)](mars3d__namespace['EventType'][_0x6fa66d(0x1d0)],this[_0x6fa66d(0x22d)],this),this['_map'][_0x6fa66d(0x1da)](mars3d__namespace['EventType']['mouseUp'],this['_onMouseUpEvent'],this),this[_0x6fa66d(0x22e)]['off'](mars3d__namespace['EventType']['mouseMove'],this['_onMouseMoveEvent'],this),this['primitives']['removeAll'](),this['_map']['scene'][_0x6fa66d(0x27b)]['remove'](this['primitives']);}['resize'](){const _0x24338e=_0x5abd34;if(!this['show']||!this['particleSystem'])return;this['primitives']['show']=![],this[_0x24338e(0x27b)][_0x24338e(0x205)](),this['_map']['once'](mars3d__namespace['EventType']['preRender'],this['_onMap_preRenderEvent'],this);}['_onMap_preRenderEvent'](_0x4c8a5b){const _0x1e5269=_0x5abd34;this['particleSystem']['canvasResize'](this[_0x1e5269(0x273)][_0x1e5269(0x209)]),this[_0x1e5269(0x2a2)](),this['primitives']['show']=!![];}['_onMapWhellEvent'](_0x46c96f){const _0x42d7da=_0x5abd34;clearTimeout(this['refreshTimer']);if(!this['show']||!this['particleSystem'])return;this[_0x42d7da(0x27b)][_0x42d7da(0x1d5)]=![],this['refreshTimer']=setTimeout(()=>{if(!this['show'])return;this['redraw']();},0xc8);}['_onMouseDownEvent'](_0x2cbfc4){const _0x5beffe=_0x5abd34;this[_0x5beffe(0x1f7)]=!![];}[_0x5abd34(0x274)](_0x4eb19a){const _0x110fa7=_0x5abd34;if(!this['show']||!this['particleSystem'])return;this[_0x110fa7(0x1f7)]&&(this[_0x110fa7(0x27b)]['show']=![],this['mouse_move']=!![]);}['_onMouseUpEvent'](_0x38f482){const _0x24fbbe=_0x5abd34;if(!this[_0x24fbbe(0x1d5)]||!this['particleSystem'])return;this[_0x24fbbe(0x1f7)]&&this['mouse_move']&&this['redraw'](),this['primitives']['show']=!![],this['mouse_down']=![],this['mouse_move']=![];}[_0x5abd34(0x2ab)](){const _0x53791c=_0x5abd34;if(!this['_map']||!this['show'])return;this['updateViewerParameters'](),this['particleSystem']['applyViewerParameters'](this['viewerParameters']),this[_0x53791c(0x27b)]['show']=!![];}['setData'](_0x52366d){const _0x52e8dd=_0x5abd34;this['_data']=_0x52366d,this[_0x52e8dd(0x240)]&&this[_0x52e8dd(0x240)]['destroy'](),this['particleSystem']=new ParticleSystem(this['scene'][_0x52e8dd(0x209)],_0x52366d,this['getOptions'](),this[_0x52e8dd(0x1ee)]),this['addPrimitives']();}['_setOptionsHook'](_0x155376,_0x2f1559){const _0x56f044=_0x5abd34;if(_0x155376)for(const _0xcb8552 in _0x155376){this[_0xcb8552]=_0x155376[_0xcb8552];}this['particleSystem']&&this['particleSystem']['setOptions'](this[_0x56f044(0x1f6)]());}['getOptions'](){const _0x5790c7=_0x5abd34,_0x57e083=Math[_0x5790c7(0x251)](Math[_0x5790c7(0x222)](this['particlesNumber']));return this['particlesNumber']=_0x57e083*_0x57e083,{'particlesTextureSize':_0x57e083,'maxParticles':this['particlesNumber'],'particleHeight':this['fixedHeight'],'fadeOpacity':this[_0x5790c7(0x1f3)],'dropRate':this['dropRate'],'dropRateBump':this['dropRateBump'],'speedFactor':this['speedFactor'],'lineWidth':this['lineWidth'],'colors':this['colors']};}['addPrimitives'](){const _0x42128b=_0x5abd34;this['primitives'][_0x42128b(0x282)](this['particleSystem']['particlesComputing'][_0x42128b(0x27b)]['getWind']),this['primitives']['add'](this[_0x42128b(0x240)][_0x42128b(0x250)]['primitives'][_0x42128b(0x1c2)]),this['primitives'][_0x42128b(0x282)](this['particleSystem']['particlesComputing']['primitives'][_0x42128b(0x29a)]),this[_0x42128b(0x27b)]['add'](this['particleSystem'][_0x42128b(0x250)]['primitives']['postProcessingPosition']),this[_0x42128b(0x27b)]['add'](this['particleSystem'][_0x42128b(0x250)][_0x42128b(0x27b)]['postProcessingSpeed']),this['primitives']['add'](this['particleSystem'][_0x42128b(0x210)]['primitives']['segments']),this['primitives']['add'](this['particleSystem']['particlesRendering']['primitives']['trails']),this['primitives']['add'](this['particleSystem']['particlesRendering']['primitives']['screen']);}['updateViewerParameters'](){const _0x51d14a=_0x5abd34;let _0x5c7124=this[_0x51d14a(0x237)][_0x51d14a(0x289)](this['scene']['globe']['ellipsoid']);if(!_0x5c7124){const _0x2fe3b5=this['_map']['getExtent']();_0x5c7124=Cesium$1[_0x51d14a(0x276)]['fromDegrees'](_0x2fe3b5['xmin'],_0x2fe3b5['ymin'],_0x2fe3b5[_0x51d14a(0x1c9)],_0x2fe3b5[_0x51d14a(0x264)]);}const _0x4af1ca=Util[_0x51d14a(0x223)](_0x5c7124);this[_0x51d14a(0x1ee)]['lonRange']['x']=_0x4af1ca[_0x51d14a(0x26d)]['min'],this[_0x51d14a(0x1ee)][_0x51d14a(0x21e)]['y']=_0x4af1ca['lon']['max'],this[_0x51d14a(0x1ee)]['latRange']['x']=_0x4af1ca[_0x51d14a(0x216)]['min'],this['viewerParameters']['latRange']['y']=_0x4af1ca['lat']['max'];const _0x176bea=this[_0x51d14a(0x237)]['getPixelSize'](this[_0x51d14a(0x2a3)],this['scene']['drawingBufferWidth'],this['scene']['drawingBufferHeight']);_0x176bea>0x0&&(this['viewerParameters']['pixelSize']=_0x176bea);}}function _0x411b(_0x2f5a37,_0x96e927){const _0x1b0e85=_0x1b0e();return _0x411b=function(_0x411b62,_0x1c9c61){_0x411b62=_0x411b62-0x1bd;let _0x12a729=_0x1b0e85[_0x411b62];return _0x12a729;},_0x411b(_0x2f5a37,_0x96e927);}mars3d__namespace['LayerUtil'][_0x5abd34(0x224)]('wind',WindLayer),mars3d__namespace['layer']['WindLayer']=WindLayer;class CanvasParticle{constructor(){const _0x22f9e7=_0x5abd34;this[_0x22f9e7(0x246)]=null,this['lat']=null,this['tlng']=null,this['tlat']=null,this['age']=null,this[_0x22f9e7(0x2b2)]=null;}['destroy'](){for(const _0x2bc84f in this){delete this[_0x2bc84f];}}}class CanvasWindField{constructor(_0x223ba4){this['setOptions'](_0x223ba4);}get['speedRate'](){return this['_speedRate'];}set[_0x5abd34(0x23c)](_0x5783ed){const _0x568cfd=_0x5abd34;this['_speedRate']=(0x64-(_0x5783ed>0x63?0x63:_0x5783ed))*0x64,this[_0x568cfd(0x280)]=[(this['xmax']-this['xmin'])/this['_speedRate'],(this['ymax']-this['ymin'])/this['_speedRate']];}get['maxAge'](){const _0x568253=_0x5abd34;return this[_0x568253(0x1f2)];}set[_0x5abd34(0x1ce)](_0xbd84b9){const _0x3a27c2=_0x5abd34;this[_0x3a27c2(0x1f2)]=_0xbd84b9;}['setOptions'](_0x278102){const _0x593a3c=_0x5abd34;this['options']=_0x278102,this['maxAge']=_0x278102[_0x593a3c(0x1ce)]||0x78,this['speedRate']=_0x278102[_0x593a3c(0x23c)]||0x32,this['particles']=[];const _0x1da546=_0x278102['particlesNumber']||0x1000;for(let _0x45ad05=0x0;_0x45ad05<_0x1da546;_0x45ad05++){const _0x6484f8=this['_randomParticle'](new CanvasParticle());this['particles']['push'](_0x6484f8);}}['setDate'](_0x4c621a){const _0x3b135c=_0x5abd34;this['rows']=_0x4c621a[_0x3b135c(0x262)],this['cols']=_0x4c621a['cols'],this[_0x3b135c(0x1f1)]=_0x4c621a['xmin'],this['xmax']=_0x4c621a['xmax'],this['ymin']=_0x4c621a['ymin'],this['ymax']=_0x4c621a['ymax'],this['grid']=[];const _0x3fa6e0=_0x4c621a['udata'],_0x319c15=_0x4c621a['vdata'];let _0x549a01=![];_0x3fa6e0['length']===this[_0x3b135c(0x262)]&&_0x3fa6e0[0x0]['length']===this[_0x3b135c(0x234)]&&(_0x549a01=!![]);let _0x4f13a4=0x0,_0x5aed59=null,_0x3d3579=null;for(let _0x5080fb=0x0;_0x5080fb<this['rows'];_0x5080fb++){_0x5aed59=[];for(let _0x3a416a=0x0;_0x3a416a<this[_0x3b135c(0x234)];_0x3a416a++,_0x4f13a4++){_0x549a01?_0x3d3579=this[_0x3b135c(0x1de)](_0x3fa6e0[_0x5080fb][_0x3a416a],_0x319c15[_0x5080fb][_0x3a416a]):_0x3d3579=this['_calcUV'](_0x3fa6e0[_0x4f13a4],_0x319c15[_0x4f13a4]),_0x5aed59[_0x3b135c(0x1cf)](_0x3d3579);}this[_0x3b135c(0x29c)][_0x3b135c(0x1cf)](_0x5aed59);}this[_0x3b135c(0x20f)]['reverseY']&&this['grid'][_0x3b135c(0x28f)]();}['clear'](){const _0x4c0e0f=_0x5abd34;delete this[_0x4c0e0f(0x262)],delete this['cols'],delete this['xmin'],delete this['xmax'],delete this['ymin'],delete this[_0x4c0e0f(0x264)],delete this['grid'],delete this['particles'];}['toGridXY'](_0x9ae399,_0x9d4f21){const _0x2d85e2=_0x5abd34,_0x2508e3=(_0x9ae399-this[_0x2d85e2(0x1f1)])/(this['xmax']-this['xmin'])*(this['cols']-0x1),_0x238446=(this['ymax']-_0x9d4f21)/(this['ymax']-this['ymin'])*(this['rows']-0x1);return[_0x2508e3,_0x238446];}['getUVByXY'](_0x1a28e3,_0x34589f){const _0x31bdde=_0x5abd34;if(_0x1a28e3<0x0||_0x1a28e3>=this[_0x31bdde(0x234)]||_0x34589f>=this['rows'])return[0x0,0x0,0x0];const _0x2ccca5=Math['floor'](_0x1a28e3),_0x4f0bf1=Math['floor'](_0x34589f);if(_0x2ccca5===_0x1a28e3&&_0x4f0bf1===_0x34589f)return this['grid'][_0x34589f][_0x1a28e3];const _0x11ff45=_0x2ccca5+0x1,_0x4b50cb=_0x4f0bf1+0x1,_0x9c8dc2=this[_0x31bdde(0x26f)](_0x2ccca5,_0x4f0bf1),_0x1c017a=this['getUVByXY'](_0x11ff45,_0x4f0bf1),_0x3b3cc8=this[_0x31bdde(0x26f)](_0x2ccca5,_0x4b50cb),_0x5a047c=this[_0x31bdde(0x26f)](_0x11ff45,_0x4b50cb);let _0x486aa5=null;try{_0x486aa5=this['_bilinearInterpolation'](_0x1a28e3-_0x2ccca5,_0x34589f-_0x4f0bf1,_0x9c8dc2,_0x1c017a,_0x3b3cc8,_0x5a047c);}catch(_0x3ca714){console['log'](_0x1a28e3,_0x34589f);}return _0x486aa5;}['_bilinearInterpolation'](_0x2926ca,_0xbfe93c,_0xa79775,_0x1cf556,_0x141542,_0x31d917){const _0x35a5cf=0x1-_0x2926ca,_0x1d5f0f=0x1-_0xbfe93c,_0x221a37=_0x35a5cf*_0x1d5f0f,_0x45de0b=_0x2926ca*_0x1d5f0f,_0x6e14e2=_0x35a5cf*_0xbfe93c,_0x40b318=_0x2926ca*_0xbfe93c,_0x448e4c=_0xa79775[0x0]*_0x221a37+_0x1cf556[0x0]*_0x45de0b+_0x141542[0x0]*_0x6e14e2+_0x31d917[0x0]*_0x40b318,_0x1990bf=_0xa79775[0x1]*_0x221a37+_0x1cf556[0x1]*_0x45de0b+_0x141542[0x1]*_0x6e14e2+_0x31d917[0x1]*_0x40b318;return this['_calcUV'](_0x448e4c,_0x1990bf);}['_calcUV'](_0x4c86a0,_0x1a6959){const _0x433f34=_0x5abd34;return[+_0x4c86a0,+_0x1a6959,Math[_0x433f34(0x222)](_0x4c86a0*_0x4c86a0+_0x1a6959*_0x1a6959)];}['getUVByPoint'](_0x62981,_0x4a25fd){const _0x257759=_0x5abd34;if(!this[_0x257759(0x2a7)](_0x62981,_0x4a25fd))return null;const _0x136d0f=this['toGridXY'](_0x62981,_0x4a25fd),_0x439630=this['getUVByXY'](_0x136d0f[0x0],_0x136d0f[0x1]);return _0x439630;}[_0x5abd34(0x2a7)](_0x2812f4,_0x4839a2){const _0x42b15e=_0x5abd34;return _0x2812f4>=this['xmin']&&_0x2812f4<=this[_0x42b15e(0x1c9)]&&_0x4839a2>=this[_0x42b15e(0x23d)]&&_0x4839a2<=this['ymax']?!![]:![];}[_0x5abd34(0x25b)](){const _0x714284=_0x5abd34,_0x176ade=fRandomByfloat(this[_0x714284(0x1f1)],this['xmax']),_0x19f5c4=fRandomByfloat(this[_0x714284(0x23d)],this[_0x714284(0x264)]);return{'lat':_0x19f5c4,'lng':_0x176ade};}['getParticles'](){const _0x233d5e=_0x5abd34;let _0x8e0aff,_0xe690f5,_0x1d396c;for(let _0x4e496c=0x0,_0x11d303=this[_0x233d5e(0x2ad)][_0x233d5e(0x211)];_0x4e496c<_0x11d303;_0x4e496c++){let _0x127753=this['particles'][_0x4e496c];_0x127753['age']<=0x0&&(_0x127753=this['_randomParticle'](_0x127753));if(_0x127753[_0x233d5e(0x22f)]>0x0){const _0x2407a1=_0x127753['tlng'],_0x4920bc=_0x127753[_0x233d5e(0x249)];_0x1d396c=this[_0x233d5e(0x1fa)](_0x2407a1,_0x4920bc),_0x1d396c?(_0x8e0aff=_0x2407a1+this['_calc_speedRate'][0x0]*_0x1d396c[0x0],_0xe690f5=_0x4920bc+this['_calc_speedRate'][0x1]*_0x1d396c[0x1],_0x127753[_0x233d5e(0x246)]=_0x2407a1,_0x127753['lat']=_0x4920bc,_0x127753[_0x233d5e(0x271)]=_0x8e0aff,_0x127753['tlat']=_0xe690f5,_0x127753['speed']=_0x1d396c[0x2],_0x127753['age']--):_0x127753['age']=0x0;}}return this[_0x233d5e(0x2ad)];}[_0x5abd34(0x245)](_0x374947){const _0x26a141=_0x5abd34;let _0x11c2d5,_0x283d91;for(let _0x1a498e=0x0;_0x1a498e<0x1e;_0x1a498e++){_0x11c2d5=this['getRandomLatLng'](),_0x283d91=this['getUVByPoint'](_0x11c2d5['lng'],_0x11c2d5['lat']);if(_0x283d91&&_0x283d91[0x2]>0x0)break;}if(!_0x283d91)return _0x374947;const _0x44f363=_0x11c2d5['lng']+this[_0x26a141(0x280)][0x0]*_0x283d91[0x0],_0x506f39=_0x11c2d5['lat']+this[_0x26a141(0x280)][0x1]*_0x283d91[0x1];return _0x374947[_0x26a141(0x246)]=_0x11c2d5[_0x26a141(0x246)],_0x374947['lat']=_0x11c2d5['lat'],_0x374947[_0x26a141(0x271)]=_0x44f363,_0x374947['tlat']=_0x506f39,_0x374947[_0x26a141(0x22f)]=Math['round'](Math['random']()*this['maxAge']),_0x374947[_0x26a141(0x2b2)]=_0x283d91[0x2],_0x374947;}['destroy'](){for(const _0x4dd5f9 in this){delete this[_0x4dd5f9];}}}function fRandomByfloat(_0x599fd4,_0x1afb10){const _0x35c6af=_0x5abd34;return _0x599fd4+Math[_0x35c6af(0x220)]()*(_0x1afb10-_0x599fd4);}const Cesium=mars3d__namespace['Cesium'],BaseLayer=mars3d__namespace['layer'][_0x5abd34(0x239)];class CanvasWindLayer extends BaseLayer{constructor(_0x59221f={}){const _0x4bb6ce=_0x5abd34;super(_0x59221f),this[_0x4bb6ce(0x26c)](_0x59221f),this['canvas']=null,_0x59221f[_0x4bb6ce(0x226)]&&_0x59221f[_0x4bb6ce(0x202)]&&(this['_colorRamp']=new mars3d__namespace['ColorRamp'](_0x59221f));}['_setOptionsHook'](_0x150f13,_0x1f983d){const _0x11ed96=_0x5abd34;this['frameTime']=0x3e8/(_0x150f13['frameRate']||0xa),this['_pointerEvents']=this['options']['pointerEvents']??![],this['color']=_0x150f13['color']||'#ffffff',this['lineWidth']=_0x150f13[_0x11ed96(0x1df)]||0x1,this[_0x11ed96(0x1ec)]=_0x150f13[_0x11ed96(0x1ec)]??0x0,this['reverseY']=_0x150f13[_0x11ed96(0x2ae)]??![],this['windField']&&this['windField']['setOptions'](_0x150f13);}get['layer'](){return this['canvas'];}get['canvasWidth'](){const _0x5d525f=_0x5abd34;return this['_map']['scene']['canvas'][_0x5d525f(0x292)];}get[_0x5abd34(0x1d9)](){return this['_map']['scene']['canvas']['clientHeight'];}get['pointerEvents'](){return this['_pointerEvents'];}set['pointerEvents'](_0x42f8d9){this['_pointerEvents']=_0x42f8d9;if(!this['canvas'])return;_0x42f8d9?this['canvas']['style']['pointer-events']='all':this['canvas']['style']['pointer-events']='none';}get['particlesNumber'](){return this['options']['particlesNumber'];}set[_0x5abd34(0x1ca)](_0x453adf){const _0x38bbc1=_0x5abd34;this['options']['particlesNumber']=_0x453adf,clearTimeout(this['_canrefresh']),this[_0x38bbc1(0x2b0)]=setTimeout(()=>{this['redraw']();},0x1f4);}get[_0x5abd34(0x23c)](){return this['options']['speedRate'];}set[_0x5abd34(0x23c)](_0x8e645){const _0x76fe89=_0x5abd34;this['options'][_0x76fe89(0x23c)]=_0x8e645,this[_0x76fe89(0x265)]&&(this['windField']['speedRate']=_0x8e645);}get['maxAge'](){const _0x4d7521=_0x5abd34;return this[_0x4d7521(0x20f)]['maxAge'];}set['maxAge'](_0x13a0cd){this['options']['maxAge']=_0x13a0cd,this['windField']&&(this['windField']['maxAge']=_0x13a0cd);}get['data'](){const _0x5e0e0f=_0x5abd34;return this[_0x5e0e0f(0x286)];}set['data'](_0x1702d0){this['setData'](_0x1702d0);}['_showHook'](_0x2ed942){const _0x20a88a=_0x5abd34;_0x2ed942?this['_addedHook']():(this[_0x20a88a(0x286)]&&(this['options'][_0x20a88a(0x279)]=this[_0x20a88a(0x286)]),this['_removedHook']());}['_mountedHook'](){const _0x1096e2=_0x5abd34;this[_0x1096e2(0x20f)]['worker']?this['initWorker']():this['windField']=new CanvasWindField(this['options']);}[_0x5abd34(0x281)](){const _0x3353e4=_0x5abd34;this['canvas']=this['_createCanvas'](),this['canvasContext']=this[_0x3353e4(0x278)]['getContext']('2d',{'willReadFrequently':!![]}),this['bindEvent'](),this['options'][_0x3353e4(0x279)]&&this['setData'](this['options'][_0x3353e4(0x279)]);}['_removedHook'](){const _0x1e5f59=_0x5abd34;this['clear'](),this[_0x1e5f59(0x296)](),this[_0x1e5f59(0x278)]&&(this['_map']['container']['removeChild'](this['canvas']),delete this['canvas']);}[_0x5abd34(0x230)](){const _0x5170b1=_0x5abd34,_0x37fc22=mars3d__namespace['DomUtil'][_0x5170b1(0x25f)]('canvas',_0x5170b1(0x252),this[_0x5170b1(0x22e)]['container']);return _0x37fc22['style']['position']='absolute',_0x37fc22['style']['top']='0px',_0x37fc22['style']['left']='0px',_0x37fc22['style']['width']=this[_0x5170b1(0x22e)]['scene'][_0x5170b1(0x278)][_0x5170b1(0x292)]+'px',_0x37fc22[_0x5170b1(0x20a)]['height']=this[_0x5170b1(0x22e)]['scene']['canvas'][_0x5170b1(0x272)]+'px',_0x37fc22['style']['pointerEvents']=this['_pointerEvents']?'auto':'none',_0x37fc22[_0x5170b1(0x20a)]['zIndex']=this['options']['zIndex']??0x9,_0x37fc22[_0x5170b1(0x1db)]=this[_0x5170b1(0x22e)]['scene']['canvas']['clientWidth'],_0x37fc22['height']=this['_map']['scene']['canvas']['clientHeight'],_0x37fc22;}['resize'](){const _0x39e41f=_0x5abd34;this['canvas']&&(this['canvas'][_0x39e41f(0x20a)]['width']=this['_map']['scene'][_0x39e41f(0x278)][_0x39e41f(0x292)]+'px',this['canvas'][_0x39e41f(0x20a)]['height']=this[_0x39e41f(0x22e)][_0x39e41f(0x273)][_0x39e41f(0x278)][_0x39e41f(0x272)]+'px',this[_0x39e41f(0x278)]['width']=this['_map'][_0x39e41f(0x273)]['canvas']['clientWidth'],this['canvas'][_0x39e41f(0x268)]=this[_0x39e41f(0x22e)][_0x39e41f(0x273)]['canvas'][_0x39e41f(0x272)]);}[_0x5abd34(0x227)](){const _0x5661fa=_0x5abd34,_0x3d90df=this;let _0x300ee1=Date['now']();(function _0x5578c6(){const _0xcf9dc6=_0x411b;_0x3d90df['animateFrame']=window['requestAnimationFrame'](_0x5578c6);if(_0x3d90df['show']&&_0x3d90df['windField']){const _0x51f1de=Date[_0xcf9dc6(0x24d)](),_0x32a3c9=_0x51f1de-_0x300ee1;_0x32a3c9>_0x3d90df['frameTime']&&(_0x300ee1=_0x51f1de-_0x32a3c9%_0x3d90df['frameTime'],_0x3d90df['update']());}}(),window[_0x5661fa(0x1dc)](_0x5661fa(0x1e0),this['resize']['bind'](this),![]),this['mouse_down']=![],this['mouse_move']=![],this['options'][_0x5661fa(0x233)]&&(this['_map']['on'](mars3d__namespace['EventType']['wheel'],this['_onMapWhellEvent'],this),this['_map']['on'](mars3d__namespace['EventType']['mouseDown'],this['_onMouseDownEvent'],this),this['_map']['on'](mars3d__namespace['EventType']['mouseUp'],this['_onMouseUpEvent'],this)));}[_0x5abd34(0x296)](){const _0x302987=_0x5abd34;window[_0x302987(0x23b)](this['animateFrame']),delete this['animateFrame'],window['removeEventListener']('resize',this[_0x302987(0x1e0)]),this[_0x302987(0x20f)]['mouseHidden']&&(this[_0x302987(0x22e)]['off'](mars3d__namespace['EventType']['wheel'],this[_0x302987(0x1cd)],this),this['_map']['off'](mars3d__namespace[_0x302987(0x1d6)]['mouseDown'],this['_onMouseDownEvent'],this),this['_map'][_0x302987(0x1da)](mars3d__namespace[_0x302987(0x1d6)]['mouseUp'],this['_onMouseUpEvent'],this),this['_map']['off'](mars3d__namespace[_0x302987(0x1d6)]['mouseMove'],this['_onMouseMoveEvent'],this));}[_0x5abd34(0x1cd)](_0x4cf8be){const _0x1a010d=_0x5abd34;clearTimeout(this[_0x1a010d(0x298)]);if(!this['show']||!this['canvas'])return;this['canvas']['style'][_0x1a010d(0x283)]='hidden',this['refreshTimer']=setTimeout(()=>{const _0x2b4a2a=_0x1a010d;if(!this['show'])return;this['redraw'](),this['canvas'][_0x2b4a2a(0x20a)]['visibility']='visible';},0xc8);}['_onMouseDownEvent'](_0x317321){const _0xd83643=_0x5abd34;this['mouse_down']=!![],this['_map']['off'](mars3d__namespace['EventType']['mouseMove'],this['_onMouseMoveEvent'],this),this['_map']['on'](mars3d__namespace[_0xd83643(0x1d6)]['mouseMove'],this[_0xd83643(0x274)],this);}['_onMouseMoveEvent'](_0x8e1751){const _0x13035d=_0x5abd34;if(!this['show']||!this['canvas'])return;this[_0x13035d(0x1f7)]&&(this['canvas']['style']['visibility']='hidden',this['mouse_move']=!![]);}[_0x5abd34(0x1e8)](_0x21366a){const _0x3420a3=_0x5abd34;if(!this['show']||!this[_0x3420a3(0x278)])return;this['_map']['off'](mars3d__namespace['EventType']['mouseMove'],this[_0x3420a3(0x274)],this),this[_0x3420a3(0x1f7)]&&this['mouse_move']&&this[_0x3420a3(0x2ab)](),this[_0x3420a3(0x278)]['style']['visibility']='visible',this['mouse_down']=![],this[_0x3420a3(0x255)]=![];}['setData'](_0x50d82a){const _0x43c8aa=_0x5abd34;this['clear'](),this[_0x43c8aa(0x286)]=_0x50d82a,this['windField']['setDate'](_0x50d82a),this[_0x43c8aa(0x2ab)]();}[_0x5abd34(0x2ab)](){const _0xa7bd0=_0x5abd34;if(!this[_0xa7bd0(0x1d5)])return;this[_0xa7bd0(0x265)]['setOptions'](this['options']),this['update']();}[_0x5abd34(0x1bf)](){const _0x3277e6=_0x5abd34;if(this['_updateIng'])return;this[_0x3277e6(0x254)]=!![];if(this[_0x3277e6(0x24c)])this['windField'][_0x3277e6(0x1bf)]();else{const _0x18b9cd=this['windField'][_0x3277e6(0x21a)]();this[_0x3277e6(0x207)](_0x18b9cd);}this['_updateIng']=![];}['_drawLines'](_0x5d8c84){const _0x214fac=_0x5abd34;this[_0x214fac(0x232)]['globalCompositeOperation']='destination-in',this['canvasContext'][_0x214fac(0x1ea)](0x0,0x0,this[_0x214fac(0x1c7)],this['canvasHeight']),this['canvasContext']['globalCompositeOperation']='lighter',this[_0x214fac(0x232)]['globalAlpha']=0.9;const _0x5aa6db=this['_map']['scene']['mode']!==Cesium[_0x214fac(0x21b)]['SCENE3D'],_0xd66089=this[_0x214fac(0x1c7)]*0.25;if(this['_colorRamp'])for(let _0x539e3a=0x0,_0x338fdd=_0x5d8c84['length'];_0x539e3a<_0x338fdd;_0x539e3a++){const _0x2a8478=_0x5d8c84[_0x539e3a],_0x1fdcda=this['_tomap'](_0x2a8478['lng'],_0x2a8478['lat'],_0x2a8478),_0x33bbc6=this[_0x214fac(0x1f8)](_0x2a8478['tlng'],_0x2a8478[_0x214fac(0x249)],_0x2a8478);if(!_0x1fdcda||!_0x33bbc6)continue;if(_0x5aa6db&&Math['abs'](_0x1fdcda[0x0]-_0x33bbc6[0x0])>=_0xd66089)continue;this[_0x214fac(0x232)][_0x214fac(0x2a5)](),this['canvasContext'][_0x214fac(0x1df)]=this[_0x214fac(0x1df)],this['canvasContext'][_0x214fac(0x1fe)]=this['_colorRamp']['getColor'](_0x2a8478['speed']),this['canvasContext']['moveTo'](_0x1fdcda[0x0],_0x1fdcda[0x1]),this[_0x214fac(0x232)]['lineTo'](_0x33bbc6[0x0],_0x33bbc6[0x1]),this['canvasContext']['stroke']();}else{this['canvasContext']['beginPath'](),this[_0x214fac(0x232)][_0x214fac(0x1df)]=this['lineWidth'],this['canvasContext']['strokeStyle']=this[_0x214fac(0x27a)];for(let _0x45e0ad=0x0,_0x48a6b2=_0x5d8c84['length'];_0x45e0ad<_0x48a6b2;_0x45e0ad++){const _0x590d24=_0x5d8c84[_0x45e0ad],_0x2bd0ad=this['_tomap'](_0x590d24['lng'],_0x590d24['lat'],_0x590d24),_0x510a6b=this[_0x214fac(0x1f8)](_0x590d24['tlng'],_0x590d24['tlat'],_0x590d24);if(!_0x2bd0ad||!_0x510a6b)continue;if(_0x5aa6db&&Math['abs'](_0x2bd0ad[0x0]-_0x510a6b[0x0])>=_0xd66089)continue;this['canvasContext']['moveTo'](_0x2bd0ad[0x0],_0x2bd0ad[0x1]),this[_0x214fac(0x232)][_0x214fac(0x1d7)](_0x510a6b[0x0],_0x510a6b[0x1]);}this['canvasContext']['stroke']();}}['_tomap'](_0x5b4a7d,_0x1ce4df,_0x2cfed5){const _0x39c4ec=_0x5abd34,_0x59344c=Cesium[_0x39c4ec(0x201)]['fromDegrees'](_0x5b4a7d,_0x1ce4df,this['fixedHeight']),_0x405e3a=this[_0x39c4ec(0x22e)]['scene'];if(_0x405e3a['mode']===Cesium['SceneMode']['SCENE3D']){const _0x100684=new Cesium['EllipsoidalOccluder'](_0x405e3a['globe'][_0x39c4ec(0x243)],_0x405e3a['camera']['positionWC']),_0x4b542f=_0x100684['isPointVisible'](_0x59344c);if(!_0x4b542f)return _0x2cfed5['age']=0x0,null;}const _0x500d60=Cesium[_0x39c4ec(0x1eb)]['wgs84ToWindowCoordinates'](this['_map']['scene'],_0x59344c);return _0x500d60?[_0x500d60['x'],_0x500d60['y']]:null;}[_0x5abd34(0x214)](){const _0x1f0986=_0x5abd34;this['windField'][_0x1f0986(0x214)](),delete this[_0x1f0986(0x286)];}[_0x5abd34(0x28d)](){const _0x373e0e=_0x5abd34;this['worker']=new Worker(this['options']['worker']),this['worker']['onmessage']=_0x18adf8=>{const _0x107365=_0x411b;this[_0x107365(0x207)](_0x18adf8['data']['particles']),this['_updateIng2']=![];},this['windField']={'init':_0x5b90bc=>{const _0x2529e1=_0x411b;this[_0x2529e1(0x24c)][_0x2529e1(0x1e9)]({'type':'init','options':_0x5b90bc});},'setOptions':_0x4bd8bd=>{this['worker']['postMessage']({'type':'setOptions','options':_0x4bd8bd});},'setDate':_0x19ad11=>{const _0x584c07=_0x411b;this['worker']['postMessage']({'type':_0x584c07(0x21c),'data':_0x19ad11});},'update':()=>{const _0xa3f5c3=_0x411b;if(this['_updateIng2'])return;this['_updateIng2']=!![],this['worker'][_0xa3f5c3(0x1e9)]({'type':_0xa3f5c3(0x1bf)});},'clear':()=>{this['worker']['postMessage']({'type':'clear'});}},this['windField']['init'](this[_0x373e0e(0x20f)]);}}mars3d__namespace['LayerUtil']['register']('canvasWind',CanvasWindLayer),mars3d__namespace['layer']['CanvasWindLayer']=CanvasWindLayer,mars3d__namespace[_0x5abd34(0x27f)]=CanvasWindField,mars3d__namespace[_0x5abd34(0x1fd)]=WindUtil,exports['CanvasWindField']=CanvasWindField,exports['CanvasWindLayer']=CanvasWindLayer,exports['WindLayer']=WindLayer,exports[_0x5abd34(0x1fd)]=WindUtil,Object['defineProperty'](exports,_0x5abd34(0x28e),{'value':!![]});
14
+ 'use strict';const _0x327d5f=_0x3887;(function(_0x47e076,_0x152cb0){const _0x2de638=_0x3887,_0x2c1c34=_0x47e076();while(!![]){try{const _0x206252=parseInt(_0x2de638(0x18a))/0x1+parseInt(_0x2de638(0x254))/0x2+-parseInt(_0x2de638(0x253))/0x3+-parseInt(_0x2de638(0x250))/0x4+parseInt(_0x2de638(0x1fc))/0x5*(-parseInt(_0x2de638(0x17d))/0x6)+-parseInt(_0x2de638(0x252))/0x7+parseInt(_0x2de638(0x1df))/0x8;if(_0x206252===_0x152cb0)break;else _0x2c1c34['push'](_0x2c1c34['shift']());}catch(_0x2f2056){_0x2c1c34['push'](_0x2c1c34['shift']());}}}(_0x539b,0x81e76));function _interopNamespace(_0x5c5467){const _0x360c8f=_0x3887;if(_0x5c5467&&_0x5c5467[_0x360c8f(0x1bb)])return _0x5c5467;var _0x24a5d7=Object['create'](null);return _0x5c5467&&Object['keys'](_0x5c5467)['forEach'](function(_0x4e63a8){if(_0x4e63a8!=='default'){var _0x3e056f=Object['getOwnPropertyDescriptor'](_0x5c5467,_0x4e63a8);Object['defineProperty'](_0x24a5d7,_0x4e63a8,_0x3e056f['get']?_0x3e056f:{'enumerable':!![],'get':function(){return _0x5c5467[_0x4e63a8];}});}}),_0x24a5d7['default']=_0x5c5467,_0x24a5d7;}var mars3d__namespace=_interopNamespace(mars3d);const Cesium$7=mars3d__namespace[_0x327d5f(0x22d)];function getU(_0x25291e,_0x1c8826){const _0x39a42d=_0x327d5f,_0x3bd59f=_0x25291e*Math[_0x39a42d(0x1f6)](Cesium$7[_0x39a42d(0x1db)]['toRadians'](_0x1c8826));return _0x3bd59f;}function getV(_0x1a0488,_0x13842d){const _0x1fbce7=_0x1a0488*Math['sin'](Cesium$7['Math']['toRadians'](_0x13842d));return _0x1fbce7;}function getSpeed(_0x569b4b,_0x1a3d39){const _0x468fc8=_0x327d5f,_0x17e639=Math['sqrt'](Math['pow'](_0x569b4b,0x2)+Math[_0x468fc8(0x1a7)](_0x1a3d39,0x2));return _0x17e639;}function getDirection(_0x29721b,_0x3c26f3){const _0x50e090=_0x327d5f;let _0x4229f2=Cesium$7['Math']['toDegrees'](Math[_0x50e090(0x263)](_0x3c26f3,_0x29721b));return _0x4229f2+=_0x4229f2<0x0?0x168:0x0,_0x4229f2;}var WindUtil={'__proto__':null,'getU':getU,'getV':getV,'getSpeed':getSpeed,'getDirection':getDirection};const Cesium$6=mars3d__namespace['Cesium'];function _0x539b(){const _0x3c7ec1=['particlesTextures','setData','context','fragmentShaderSource','primitives','redraw','mouse_down','autoClear','max','_updateIng2','pointerEvents','lev','top','fadeOpacity','ellipsoid','_mountedHook','udata','Pass','globalAlpha','camera','min','outputTexture','lineWidth','now','pow','worker','latRange','scene','ClearCommand','framebuffer','fromDegrees','viewerParameters','destroyParticlesTextures','red','clearFramebuffers','once','OPAQUE','particles','//\x20the\x20size\x20of\x20UV\x20textures:\x20width\x20=\x20lon,\x20height\x20=\x20lat*lev\x0auniform\x20sampler2D\x20U;\x20//\x20eastward\x20wind\x0auniform\x20sampler2D\x20V;\x20//\x20northward\x20wind\x0a\x0auniform\x20sampler2D\x20currentParticlesPosition;\x20//\x20(lon,\x20lat,\x20lev)\x0a\x0auniform\x20vec3\x20dimension;\x20//\x20(lon,\x20lat,\x20lev)\x0auniform\x20vec3\x20minimum;\x20//\x20minimum\x20of\x20each\x20dimension\x0auniform\x20vec3\x20maximum;\x20//\x20maximum\x20of\x20each\x20dimension\x0auniform\x20vec3\x20interval;\x20//\x20interval\x20of\x20each\x20dimension\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0avec2\x20mapPositionToNormalizedIndex2D(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20ensure\x20the\x20range\x20of\x20longitude\x20and\x20latitude\x0a\x20\x20\x20\x20lonLatLev.x\x20=\x20mod(lonLatLev.x,\x20360.0);\x0a\x20\x20\x20\x20lonLatLev.y\x20=\x20clamp(lonLatLev.y,\x20-90.0,\x2090.0);\x0a\x0a\x20\x20\x20\x20vec3\x20index3D\x20=\x20vec3(0.0);\x0a\x20\x20\x20\x20index3D.x\x20=\x20(lonLatLev.x\x20-\x20minimum.x)\x20/\x20interval.x;\x0a\x20\x20\x20\x20index3D.y\x20=\x20(lonLatLev.y\x20-\x20minimum.y)\x20/\x20interval.y;\x0a\x20\x20\x20\x20index3D.z\x20=\x20(lonLatLev.z\x20-\x20minimum.z)\x20/\x20interval.z;\x0a\x0a\x20\x20\x20\x20//\x20the\x20st\x20texture\x20coordinate\x20corresponding\x20to\x20(col,\x20row)\x20index\x0a\x20\x20\x20\x20//\x20example\x0a\x20\x20\x20\x20//\x20data\x20array\x20is\x20[0,\x201,\x202,\x203,\x204,\x205],\x20width\x20=\x203,\x20height\x20=\x202\x0a\x20\x20\x20\x20//\x20the\x20content\x20of\x20texture\x20will\x20be\x0a\x20\x20\x20\x20//\x20t\x201.0\x0a\x20\x20\x20\x20//\x20\x20\x20\x20|\x20\x203\x204\x205\x0a\x20\x20\x20\x20//\x20\x20\x20\x20|\x0a\x20\x20\x20\x20//\x20\x20\x20\x20|\x20\x200\x201\x202\x0a\x20\x20\x20\x20//\x20\x20\x200.0------1.0\x20s\x0a\x0a\x20\x20\x20\x20vec2\x20index2D\x20=\x20vec2(index3D.x,\x20index3D.z\x20*\x20dimension.y\x20+\x20index3D.y);\x0a\x20\x20\x20\x20vec2\x20normalizedIndex2D\x20=\x20vec2(index2D.x\x20/\x20dimension.x,\x20index2D.y\x20/\x20(dimension.y\x20*\x20dimension.z));\x0a\x20\x20\x20\x20return\x20normalizedIndex2D;\x0a}\x0a\x0afloat\x20getWind(sampler2D\x20windTexture,\x20vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20vec2\x20normalizedIndex2D\x20=\x20mapPositionToNormalizedIndex2D(lonLatLev);\x0a\x20\x20\x20\x20float\x20result\x20=\x20texture(windTexture,\x20normalizedIndex2D).r;\x0a\x20\x20\x20\x20return\x20result;\x0a}\x0a\x0aconst\x20mat4\x20kernelMatrix\x20=\x20mat4(\x0a\x20\x20\x20\x200.0,\x20-1.0,\x202.0,\x20-1.0,\x20//\x20first\x20column\x0a\x20\x20\x20\x202.0,\x200.0,\x20-5.0,\x203.0,\x20//\x20second\x20column\x0a\x20\x20\x20\x200.0,\x201.0,\x204.0,\x20-3.0,\x20//\x20third\x20column\x0a\x20\x20\x20\x200.0,\x200.0,\x20-1.0,\x201.0\x20//\x20fourth\x20column\x0a);\x0afloat\x20oneDimensionInterpolation(float\x20t,\x20float\x20p0,\x20float\x20p1,\x20float\x20p2,\x20float\x20p3)\x20{\x0a\x20\x20\x20\x20vec4\x20tVec4\x20=\x20vec4(1.0,\x20t,\x20t\x20*\x20t,\x20t\x20*\x20t\x20*\x20t);\x0a\x20\x20\x20\x20tVec4\x20=\x20tVec4\x20/\x202.0;\x0a\x20\x20\x20\x20vec4\x20pVec4\x20=\x20vec4(p0,\x20p1,\x20p2,\x20p3);\x0a\x20\x20\x20\x20return\x20dot((tVec4\x20*\x20kernelMatrix),\x20pVec4);\x0a}\x0a\x0afloat\x20calculateB(sampler2D\x20windTexture,\x20float\x20t,\x20float\x20lon,\x20float\x20lat,\x20float\x20lev)\x20{\x0a\x20\x20\x20\x20float\x20lon0\x20=\x20floor(lon)\x20-\x201.0\x20*\x20interval.x;\x0a\x20\x20\x20\x20float\x20lon1\x20=\x20floor(lon);\x0a\x20\x20\x20\x20float\x20lon2\x20=\x20floor(lon)\x20+\x201.0\x20*\x20interval.x;\x0a\x20\x20\x20\x20float\x20lon3\x20=\x20floor(lon)\x20+\x202.0\x20*\x20interval.x;\x0a\x0a\x20\x20\x20\x20float\x20p0\x20=\x20getWind(windTexture,\x20vec3(lon0,\x20lat,\x20lev));\x0a\x20\x20\x20\x20float\x20p1\x20=\x20getWind(windTexture,\x20vec3(lon1,\x20lat,\x20lev));\x0a\x20\x20\x20\x20float\x20p2\x20=\x20getWind(windTexture,\x20vec3(lon2,\x20lat,\x20lev));\x0a\x20\x20\x20\x20float\x20p3\x20=\x20getWind(windTexture,\x20vec3(lon3,\x20lat,\x20lev));\x0a\x0a\x20\x20\x20\x20return\x20oneDimensionInterpolation(t,\x20p0,\x20p1,\x20p2,\x20p3);\x0a}\x0a\x0afloat\x20interpolateOneTexture(sampler2D\x20windTexture,\x20vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20float\x20lon\x20=\x20lonLatLev.x;\x0a\x20\x20\x20\x20float\x20lat\x20=\x20lonLatLev.y;\x0a\x20\x20\x20\x20float\x20lev\x20=\x20lonLatLev.z;\x0a\x0a\x20\x20\x20\x20float\x20lat0\x20=\x20floor(lat)\x20-\x201.0\x20*\x20interval.y;\x0a\x20\x20\x20\x20float\x20lat1\x20=\x20floor(lat);\x0a\x20\x20\x20\x20float\x20lat2\x20=\x20floor(lat)\x20+\x201.0\x20*\x20interval.y;\x0a\x20\x20\x20\x20float\x20lat3\x20=\x20floor(lat)\x20+\x202.0\x20*\x20interval.y;\x0a\x0a\x20\x20\x20\x20vec2\x20coefficient\x20=\x20lonLatLev.xy\x20-\x20floor(lonLatLev.xy);\x0a\x20\x20\x20\x20float\x20b0\x20=\x20calculateB(windTexture,\x20coefficient.x,\x20lon,\x20lat0,\x20lev);\x0a\x20\x20\x20\x20float\x20b1\x20=\x20calculateB(windTexture,\x20coefficient.x,\x20lon,\x20lat1,\x20lev);\x0a\x20\x20\x20\x20float\x20b2\x20=\x20calculateB(windTexture,\x20coefficient.x,\x20lon,\x20lat2,\x20lev);\x0a\x20\x20\x20\x20float\x20b3\x20=\x20calculateB(windTexture,\x20coefficient.x,\x20lon,\x20lat3,\x20lev);\x0a\x0a\x20\x20\x20\x20return\x20oneDimensionInterpolation(coefficient.y,\x20b0,\x20b1,\x20b2,\x20b3);\x0a}\x0a\x0avec3\x20bicubic(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20https://en.wikipedia.org/wiki/Bicubic_interpolation#Bicubic_convolution_algorithm\x0a\x20\x20\x20\x20float\x20u\x20=\x20interpolateOneTexture(U,\x20lonLatLev);\x0a\x20\x20\x20\x20float\x20v\x20=\x20interpolateOneTexture(V,\x20lonLatLev);\x0a\x20\x20\x20\x20float\x20w\x20=\x200.0;\x0a\x20\x20\x20\x20return\x20vec3(u,\x20v,\x20w);\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20//\x20texture\x20coordinate\x20must\x20be\x20normalized\x0a\x20\x20\x20\x20vec3\x20lonLatLev\x20=\x20texture(currentParticlesPosition,\x20v_textureCoordinates).rgb;\x0a\x20\x20\x20\x20vec3\x20windVector\x20=\x20bicubic(lonLatLev);\x0a\x20\x20\x20\x20out_FragColor\x20=\x20vec4(windVector,\x200.0);\x0a}\x0a','initWorker','createWindTextures','mouse_move','windData','lon','__esModule','color','_onMouseUpEvent','length','mode','lat','windTextures','currentParticlesPosition','reverse','reverseY','IDENTITY','clampToLatitudeRange','LayerUtil','rows','fromCache','getParticles','defined','push','mouseUp','resize','cols','Draw','EventType','_onMouseMoveEvent','commandType','PixelDatatype','getUVByPoint','particleSystem','_map','mars3d-canvasWind','getUVByXY','left','Math','pointer-events','tlat','options','13656032eKwDhV','height','update','_removedHook','Cartesian2','TRIANGLES','drawingBufferWidth','getExtent','postProcessingSpeed','destroy','framebuffers','frameTime','animateFrame','speed','uniform\x20sampler2D\x20currentParticlesPosition;\x20//\x20(lon,\x20lat,\x20lev)\x0auniform\x20sampler2D\x20currentParticlesSpeed;\x20//\x20(u,\x20v,\x20w,\x20normalization)\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0avec2\x20lengthOfLonLat(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20unit\x20conversion:\x20meters\x20->\x20longitude\x20latitude\x20degrees\x0a\x20\x20\x20\x20//\x20see\x20https://en.wikipedia.org/wiki/Geographic_coordinate_system#Length_of_a_degree\x20for\x20detail\x0a\x0a\x20\x20\x20\x20//\x20Calculate\x20the\x20length\x20of\x20a\x20degree\x20of\x20latitude\x20and\x20longitude\x20in\x20meters\x0a\x20\x20\x20\x20float\x20latitude\x20=\x20radians(lonLatLev.y);\x0a\x0a\x20\x20\x20\x20float\x20term1\x20=\x20111132.92;\x0a\x20\x20\x20\x20float\x20term2\x20=\x20559.82\x20*\x20cos(2.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20term3\x20=\x201.175\x20*\x20cos(4.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20term4\x20=\x200.0023\x20*\x20cos(6.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20latLength\x20=\x20term1\x20-\x20term2\x20+\x20term3\x20-\x20term4;\x0a\x0a\x20\x20\x20\x20float\x20term5\x20=\x20111412.84\x20*\x20cos(latitude);\x0a\x20\x20\x20\x20float\x20term6\x20=\x2093.5\x20*\x20cos(3.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20term7\x20=\x200.118\x20*\x20cos(5.0\x20*\x20latitude);\x0a\x20\x20\x20\x20float\x20longLength\x20=\x20term5\x20-\x20term6\x20+\x20term7;\x0a\x0a\x20\x20\x20\x20return\x20vec2(longLength,\x20latLength);\x0a}\x0a\x0avoid\x20updatePosition(vec3\x20lonLatLev,\x20vec3\x20speed)\x20{\x0a\x20\x20\x20\x20vec2\x20lonLatLength\x20=\x20lengthOfLonLat(lonLatLev);\x0a\x20\x20\x20\x20float\x20u\x20=\x20speed.x\x20/\x20lonLatLength.x;\x0a\x20\x20\x20\x20float\x20v\x20=\x20speed.y\x20/\x20lonLatLength.y;\x0a\x20\x20\x20\x20float\x20w\x20=\x200.0;\x0a\x20\x20\x20\x20vec3\x20windVectorInLonLatLev\x20=\x20vec3(u,\x20v,\x20w);\x0a\x0a\x20\x20\x20\x20vec3\x20nextParticle\x20=\x20lonLatLev\x20+\x20windVectorInLonLatLev;\x0a\x0a\x20\x20\x20\x20out_FragColor\x20=\x20vec4(nextParticle,\x200.0);\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20//\x20texture\x20coordinate\x20must\x20be\x20normalized\x0a\x20\x20\x20\x20vec3\x20lonLatLev\x20=\x20texture(currentParticlesPosition,\x20v_textureCoordinates).rgb;\x0a\x20\x20\x20\x20vec3\x20speed\x20=\x20texture(currentParticlesSpeed,\x20v_textureCoordinates).rgb;\x0a\x0a\x20\x20\x20\x20updatePosition(lonLatLev,\x20speed);\x0a}\x0a','canvasWidth','windField','updatePosition','mod','PrimitiveType','age','createTexture','textures','cos','clear','maxParticles','uniformMap','blue','Compute','10pdPJYh','WindUtil','SceneMode','maxAge','trails','canvas','currentTrailsDepth','createRawRenderState','create','getOptions','vdata','log','createRenderingFramebuffers','canvasResize','particlesNumber','ZERO','clearCommand','particlesRendering','addPrimitives','updateSpeed','setDate','vmax','Cartesian3','grid','createSegmentsGeometry','PrimitiveCollection','removeChild','nextTrails','visibility','GeometryAttributes','ceil','_createCanvas','_updateIng','register','forEach','init','removeEventListener','pixelSize','tlng','data','add','STATIC_DRAW','_speedRate','NEAREST','shaderProgram','Sampler','ymin','uniform\x20sampler2D\x20nextParticlesPosition;\x0auniform\x20sampler2D\x20nextParticlesSpeed;\x20//\x20(u,\x20v,\x20w,\x20normalization)\x0a\x0a//\x20range\x20(min,\x20max)\x0auniform\x20vec2\x20lonRange;\x0auniform\x20vec2\x20latRange;\x0a\x0auniform\x20float\x20randomCoefficient;\x20//\x20use\x20to\x20improve\x20the\x20pseudo-random\x20generator\x0auniform\x20float\x20dropRate;\x20//\x20drop\x20rate\x20is\x20a\x20chance\x20a\x20particle\x20will\x20restart\x20at\x20random\x20position\x20to\x20avoid\x20degeneration\x0auniform\x20float\x20dropRateBump;\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0a//\x20pseudo-random\x20generator\x0aconst\x20vec3\x20randomConstants\x20=\x20vec3(12.9898,\x2078.233,\x204375.85453);\x0aconst\x20vec2\x20normalRange\x20=\x20vec2(0.0,\x201.0);\x0afloat\x20rand(vec2\x20seed,\x20vec2\x20range)\x20{\x0a\x20\x20\x20\x20vec2\x20randomSeed\x20=\x20randomCoefficient\x20*\x20seed;\x0a\x20\x20\x20\x20float\x20temp\x20=\x20dot(randomConstants.xy,\x20randomSeed);\x0a\x20\x20\x20\x20temp\x20=\x20fract(sin(temp)\x20*\x20(randomConstants.z\x20+\x20temp));\x0a\x20\x20\x20\x20return\x20temp\x20*\x20(range.y\x20-\x20range.x)\x20+\x20range.x;\x0a}\x0a\x0avec3\x20generateRandomParticle(vec2\x20seed,\x20float\x20lev)\x20{\x0a\x20\x20\x20\x20//\x20ensure\x20the\x20longitude\x20is\x20in\x20[0,\x20360]\x0a\x20\x20\x20\x20float\x20randomLon\x20=\x20mod(rand(seed,\x20lonRange),\x20360.0);\x0a\x20\x20\x20\x20float\x20randomLat\x20=\x20rand(-seed,\x20latRange);\x0a\x0a\x20\x20\x20\x20return\x20vec3(randomLon,\x20randomLat,\x20lev);\x0a}\x0a\x0abool\x20particleOutbound(vec3\x20particle)\x20{\x0a\x20\x20\x20\x20return\x20particle.y\x20<\x20-90.0\x20||\x20particle.y\x20>\x2090.0;\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec3\x20nextParticle\x20=\x20texture(nextParticlesPosition,\x20v_textureCoordinates).rgb;\x0a\x20\x20\x20\x20vec4\x20nextSpeed\x20=\x20texture(nextParticlesSpeed,\x20v_textureCoordinates);\x0a\x20\x20\x20\x20float\x20particleDropRate\x20=\x20dropRate\x20+\x20dropRateBump\x20*\x20nextSpeed.a;\x0a\x0a\x20\x20\x20\x20vec2\x20seed1\x20=\x20nextParticle.xy\x20+\x20v_textureCoordinates;\x0a\x20\x20\x20\x20vec2\x20seed2\x20=\x20nextSpeed.xy\x20+\x20v_textureCoordinates;\x0a\x20\x20\x20\x20vec3\x20randomParticle\x20=\x20generateRandomParticle(seed1,\x20nextParticle.z);\x0a\x20\x20\x20\x20float\x20randomNumber\x20=\x20rand(seed2,\x20normalRange);\x0a\x0a\x20\x20\x20\x20if\x20(randomNumber\x20<\x20particleDropRate\x20||\x20particleOutbound(nextParticle))\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20vec4(randomParticle,\x201.0);\x20//\x201.0\x20means\x20this\x20is\x20a\x20random\x20particle\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20vec4(nextParticle,\x200.0);\x0a\x20\x20\x20\x20}\x0a}\x0a','postMessage','Cesium','FLOAT','PixelFormat','clientHeight','keys','_data','particlesTextureSize','_calc_speedRate','ymax','currentParticlesSpeed','vertexArray','_tomap','_onMap_preRenderEvent','DEPTH_COMPONENT','in\x20vec2\x20st;\x0a//\x20it\x20is\x20not\x20normal\x20itself,\x20but\x20used\x20to\x20control\x20normal\x0ain\x20vec3\x20normal;\x20//\x20(point\x20to\x20use,\x20offset\x20sign,\x20not\x20used\x20component)\x0a\x0auniform\x20sampler2D\x20currentParticlesPosition;\x0auniform\x20sampler2D\x20postProcessingPosition;\x0auniform\x20sampler2D\x20postProcessingSpeed;\x0a\x0auniform\x20float\x20particleHeight;\x0a\x0auniform\x20float\x20aspect;\x0auniform\x20float\x20pixelSize;\x0auniform\x20float\x20lineWidth;\x0a\x0aout\x20float\x20speedNormalization;\x0a\x0avec3\x20convertCoordinate(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20WGS84\x20(lon,\x20lat,\x20lev)\x20->\x20ECEF\x20(x,\x20y,\x20z)\x0a\x20\x20\x20\x20//\x20see\x20https://en.wikipedia.org/wiki/Geographic_coordinate_conversion#From_geodetic_to_ECEF_coordinates\x20for\x20detail\x0a\x0a\x20\x20\x20\x20//\x20WGS\x2084\x20geometric\x20constants\x0a\x20\x20\x20\x20float\x20a\x20=\x206378137.0;\x20//\x20Semi-major\x20axis\x0a\x20\x20\x20\x20float\x20b\x20=\x206356752.3142;\x20//\x20Semi-minor\x20axis\x0a\x20\x20\x20\x20float\x20e2\x20=\x206.69437999014e-3;\x20//\x20First\x20eccentricity\x20squared\x0a\x0a\x20\x20\x20\x20float\x20latitude\x20=\x20radians(lonLatLev.y);\x0a\x20\x20\x20\x20float\x20longitude\x20=\x20radians(lonLatLev.x);\x0a\x0a\x20\x20\x20\x20float\x20cosLat\x20=\x20cos(latitude);\x0a\x20\x20\x20\x20float\x20sinLat\x20=\x20sin(latitude);\x0a\x20\x20\x20\x20float\x20cosLon\x20=\x20cos(longitude);\x0a\x20\x20\x20\x20float\x20sinLon\x20=\x20sin(longitude);\x0a\x0a\x20\x20\x20\x20float\x20N_Phi\x20=\x20a\x20/\x20sqrt(1.0\x20-\x20e2\x20*\x20sinLat\x20*\x20sinLat);\x0a\x20\x20\x20\x20float\x20h\x20=\x20particleHeight;\x20//\x20it\x20should\x20be\x20high\x20enough\x20otherwise\x20the\x20particle\x20may\x20not\x20pass\x20the\x20terrain\x20depth\x20test\x0a\x0a\x20\x20\x20\x20vec3\x20cartesian\x20=\x20vec3(0.0);\x0a\x20\x20\x20\x20cartesian.x\x20=\x20(N_Phi\x20+\x20h)\x20*\x20cosLat\x20*\x20cosLon;\x0a\x20\x20\x20\x20cartesian.y\x20=\x20(N_Phi\x20+\x20h)\x20*\x20cosLat\x20*\x20sinLon;\x0a\x20\x20\x20\x20cartesian.z\x20=\x20((b\x20*\x20b)\x20/\x20(a\x20*\x20a)\x20*\x20N_Phi\x20+\x20h)\x20*\x20sinLat;\x0a\x20\x20\x20\x20return\x20cartesian;\x0a}\x0a\x0avec4\x20calcProjectedCoordinate(vec3\x20lonLatLev)\x20{\x0a\x20\x20\x20\x20//\x20the\x20range\x20of\x20longitude\x20in\x20Cesium\x20is\x20[-180,\x20180]\x20but\x20the\x20range\x20of\x20longitude\x20in\x20the\x20NetCDF\x20file\x20is\x20[0,\x20360]\x0a\x20\x20\x20\x20//\x20[0,\x20180]\x20is\x20corresponding\x20to\x20[0,\x20180]\x20and\x20[180,\x20360]\x20is\x20corresponding\x20to\x20[-180,\x200]\x0a\x20\x20\x20\x20lonLatLev.x\x20=\x20mod(lonLatLev.x\x20+\x20180.0,\x20360.0)\x20-\x20180.0;\x0a\x20\x20\x20\x20vec3\x20particlePosition\x20=\x20convertCoordinate(lonLatLev);\x0a\x20\x20\x20\x20vec4\x20projectedCoordinate\x20=\x20czm_modelViewProjection\x20*\x20vec4(particlePosition,\x201.0);\x0a\x20\x20\x20\x20return\x20projectedCoordinate;\x0a}\x0a\x0avec4\x20calcOffset(vec4\x20currentProjectedCoordinate,\x20vec4\x20nextProjectedCoordinate,\x20float\x20offsetSign)\x20{\x0a\x20\x20\x20\x20vec2\x20aspectVec2\x20=\x20vec2(aspect,\x201.0);\x0a\x20\x20\x20\x20vec2\x20currentXY\x20=\x20(currentProjectedCoordinate.xy\x20/\x20currentProjectedCoordinate.w)\x20*\x20aspectVec2;\x0a\x20\x20\x20\x20vec2\x20nextXY\x20=\x20(nextProjectedCoordinate.xy\x20/\x20nextProjectedCoordinate.w)\x20*\x20aspectVec2;\x0a\x0a\x20\x20\x20\x20float\x20offsetLength\x20=\x20lineWidth\x20/\x202.0;\x0a\x20\x20\x20\x20vec2\x20direction\x20=\x20normalize(nextXY\x20-\x20currentXY);\x0a\x20\x20\x20\x20vec2\x20normalVector\x20=\x20vec2(-direction.y,\x20direction.x);\x0a\x20\x20\x20\x20normalVector.x\x20=\x20normalVector.x\x20/\x20aspect;\x0a\x20\x20\x20\x20normalVector\x20=\x20offsetLength\x20*\x20normalVector;\x0a\x0a\x20\x20\x20\x20vec4\x20offset\x20=\x20vec4(offsetSign\x20*\x20normalVector,\x200.0,\x200.0);\x0a\x20\x20\x20\x20return\x20offset;\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec2\x20particleIndex\x20=\x20st;\x0a\x0a\x20\x20\x20\x20vec3\x20currentPosition\x20=\x20texture(currentParticlesPosition,\x20particleIndex).rgb;\x0a\x20\x20\x20\x20vec4\x20nextPosition\x20=\x20texture(postProcessingPosition,\x20particleIndex);\x0a\x0a\x20\x20\x20\x20vec4\x20currentProjectedCoordinate\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20vec4\x20nextProjectedCoordinate\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20if\x20(nextPosition.w\x20>\x200.0)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20currentProjectedCoordinate\x20=\x20calcProjectedCoordinate(currentPosition);\x0a\x20\x20\x20\x20\x20\x20\x20\x20nextProjectedCoordinate\x20=\x20calcProjectedCoordinate(currentPosition);\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20currentProjectedCoordinate\x20=\x20calcProjectedCoordinate(currentPosition);\x0a\x20\x20\x20\x20\x20\x20\x20\x20nextProjectedCoordinate\x20=\x20calcProjectedCoordinate(nextPosition.xyz);\x0a\x20\x20\x20\x20}\x0a\x0a\x20\x20\x20\x20float\x20pointToUse\x20=\x20normal.x;\x20//\x20-1\x20is\x20currentProjectedCoordinate\x20and\x20+1\x20is\x20nextProjectedCoordinate\x0a\x20\x20\x20\x20float\x20offsetSign\x20=\x20normal.y;\x0a\x0a\x20\x20\x20\x20vec4\x20offset\x20=\x20pixelSize\x20*\x20calcOffset(currentProjectedCoordinate,\x20nextProjectedCoordinate,\x20offsetSign);\x0a\x20\x20\x20\x20if\x20(pointToUse\x20<\x200.0)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20gl_Position\x20=\x20currentProjectedCoordinate\x20+\x20offset;\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20gl_Position\x20=\x20nextProjectedCoordinate\x20+\x20offset;\x0a\x20\x20\x20\x20}\x0a\x0a\x20\x20\x20\x20speedNormalization\x20=\x20texture(postProcessingSpeed,\x20particleIndex).a;\x0a}\x0a','lng','style','createParticlesTextures','setOptions','colors','onmessage','CanvasWindLayer','createRenderingTextures','visible','speedRate','commandToExecute','umin','globeBoundingSphere','hidden','show','getFullscreenQuad','levmin','strokeStyle','off','_onMouseDownEvent','2120476GaHNWJ','createRenderingPrimitives','739235nyBfVK','3034050rkCugw','1710404ZAiJqh','dimensions','fixedHeight','ShaderSource','BufferUsage','layer','xmin','fromGeometry','south','xmax','_calcUV','toDegrees','arrayBufferView','_maxAge','_onMapWhellEvent','atan2','colorTable','RenderState','currentTrailsColor','destination-in','canvasContext','particlesComputing','drawingBufferHeight','attributeLocations','postProcessingPosition','_pointerEvents','steps','1418724kitOkh','_bilinearInterpolation','all','primitiveType','preExecute','refreshTimer','segments','TWO_PI','_randomParticle','BaseLayer','zIndex','GeometryAttribute','RGBA','89862pmrOTL','random','getWind','mouseMove','nextTrailsColor'];_0x539b=function(){return _0x3c7ec1;};return _0x539b();}class CustomPrimitive{constructor(_0x2b7341){const _0x484f27=_0x327d5f;this[_0x484f27(0x1d3)]=_0x2b7341['commandType'],this['geometry']=_0x2b7341['geometry'],this['attributeLocations']=_0x2b7341[_0x484f27(0x179)],this['primitiveType']=_0x2b7341[_0x484f27(0x180)],this['uniformMap']=_0x2b7341['uniformMap'],this['vertexShaderSource']=_0x2b7341['vertexShaderSource'],this[_0x484f27(0x192)]=_0x2b7341[_0x484f27(0x192)],this['rawRenderState']=_0x2b7341['rawRenderState'],this['framebuffer']=_0x2b7341['framebuffer'],this[_0x484f27(0x1a4)]=_0x2b7341['outputTexture'],this[_0x484f27(0x196)]=_0x2b7341['autoClear']??![],this['preExecute']=_0x2b7341[_0x484f27(0x181)],this['show']=!![],this['commandToExecute']=undefined,this[_0x484f27(0x20c)]=undefined,this[_0x484f27(0x196)]&&(this['clearCommand']=new Cesium$6[(_0x484f27(0x1ab))]({'color':new Cesium$6['Color'](0x0,0x0,0x0,0x0),'depth':0x1,'framebuffer':this[_0x484f27(0x1ac)],'pass':Cesium$6[_0x484f27(0x1a0)]['OPAQUE']}));}['createCommand'](_0x1fcd74){const _0x490e64=_0x327d5f;switch(this[_0x490e64(0x1d3)]){case'Draw':{const _0x36b62a=Cesium$6['VertexArray']['fromGeometry']({'context':_0x1fcd74,'geometry':this['geometry'],'attributeLocations':this[_0x490e64(0x179)],'bufferUsage':Cesium$6['BufferUsage']['STATIC_DRAW']}),_0x4288ea=Cesium$6['ShaderProgram']['fromCache']({'context':_0x1fcd74,'attributeLocations':this['attributeLocations'],'vertexShaderSource':this['vertexShaderSource'],'fragmentShaderSource':this['fragmentShaderSource']}),_0x3e839e=Cesium$6[_0x490e64(0x173)][_0x490e64(0x1c9)](this['rawRenderState']);return new Cesium$6['DrawCommand']({'primitiveType':this[_0x490e64(0x180)],'shaderProgram':_0x4288ea,'vertexArray':_0x36b62a,'modelMatrix':Cesium$6['Matrix4'][_0x490e64(0x1c5)],'renderState':_0x3e839e,'uniformMap':this[_0x490e64(0x1f9)],'castShadows':![],'receiveShadows':![],'framebuffer':this['framebuffer'],'pass':Cesium$6[_0x490e64(0x1a0)]['OPAQUE'],'pickOnly':!![],'owner':this});}case'Compute':{return new Cesium$6['ComputeCommand']({'owner':this,'fragmentShaderSource':this['fragmentShaderSource'],'uniformMap':this[_0x490e64(0x1f9)],'outputTexture':this[_0x490e64(0x1a4)],'persists':!![]});}}}['setGeometry'](_0x5a48de,_0x39df69){const _0x1578fc=_0x327d5f;this['geometry']=_0x39df69;const _0x3e2ceb=Cesium$6['VertexArray'][_0x1578fc(0x25b)]({'context':_0x5a48de,'geometry':this['geometry'],'attributeLocations':this['attributeLocations'],'bufferUsage':Cesium$6['BufferUsage'][_0x1578fc(0x225)]});this['commandToExecute']['vertexArray']=_0x3e2ceb;}[_0x327d5f(0x1e1)](_0x138103){const _0x12bbf4=_0x327d5f;if(!this['show'])return;if(_0x138103['mode']!==Cesium$6[_0x12bbf4(0x1fe)]['SCENE3D'])return;!Cesium$6['defined'](this[_0x12bbf4(0x246)])&&(this['commandToExecute']=this['createCommand'](_0x138103['context'])),Cesium$6['defined'](this['preExecute'])&&this['preExecute'](),Cesium$6[_0x12bbf4(0x1cb)](this['clearCommand'])&&_0x138103['commandList']['push'](this[_0x12bbf4(0x20c)]),_0x138103['commandList']['push'](this['commandToExecute']);}['isDestroyed'](){return![];}['destroy'](){const _0x5996b5=_0x327d5f;if(this['clearCommand']){var _0x21fecc,_0x194855;(_0x21fecc=this['clearCommand'])!==null&&_0x21fecc!==void 0x0&&_0x21fecc[_0x5996b5(0x237)]&&this['clearCommand'][_0x5996b5(0x237)]['destroy'](),(_0x194855=this['clearCommand'])!==null&&_0x194855!==void 0x0&&_0x194855['shaderProgram']&&this['clearCommand'][_0x5996b5(0x228)]['destroy'](),delete this['clearCommand'];}return this['commandToExecute']&&(this['commandToExecute']['vertexArray']&&this['commandToExecute']['vertexArray']['destroy'](),this[_0x5996b5(0x246)][_0x5996b5(0x228)]&&this['commandToExecute'][_0x5996b5(0x228)]['destroy'](),delete this['commandToExecute']),Cesium$6['destroyObject'](this);}}const Cesium$5=mars3d__namespace['Cesium'],Util=(function(){const _0xbbe4a4=function(){const _0x1cd4d9=_0x3887,_0x2daf34=new Cesium$5['Geometry']({'attributes':new Cesium$5['GeometryAttributes']({'position':new Cesium$5[(_0x1cd4d9(0x188))]({'componentDatatype':Cesium$5['ComponentDatatype']['FLOAT'],'componentsPerAttribute':0x3,'values':new Float32Array([-0x1,-0x1,0x0,0x1,-0x1,0x0,0x1,0x1,0x0,-0x1,0x1,0x0])}),'st':new Cesium$5['GeometryAttribute']({'componentDatatype':Cesium$5['ComponentDatatype']['FLOAT'],'componentsPerAttribute':0x2,'values':new Float32Array([0x0,0x0,0x1,0x0,0x1,0x1,0x0,0x1])})}),'indices':new Uint32Array([0x3,0x2,0x0,0x0,0x2,0x1])});return _0x2daf34;},_0x444ed9=function(_0x1a4bec,_0x15176a){const _0x58cfd0=_0x3887;if(Cesium$5['defined'](_0x15176a)){const _0x210fb9={};_0x210fb9[_0x58cfd0(0x260)]=_0x15176a,_0x1a4bec['source']=_0x210fb9;}const _0x440e17=new Cesium$5['Texture'](_0x1a4bec);return _0x440e17;},_0x21fc25=function(_0x5bc9d0,_0x470c6b,_0x50b649){const _0x5f17f9=new Cesium$5['Framebuffer']({'context':_0x5bc9d0,'colorTextures':[_0x470c6b],'depthTexture':_0x50b649});return _0x5f17f9;},_0x25025c=function(_0x5ee530){const _0x5c6548=!![],_0x2cadfa=![],_0x29cd55={'viewport':_0x5ee530['viewport'],'depthTest':_0x5ee530['depthTest'],'depthMask':_0x5ee530['depthMask'],'blending':_0x5ee530['blending']},_0x191dd4=Cesium$5['Appearance']['getDefaultRenderState'](_0x5c6548,_0x2cadfa,_0x29cd55);return _0x191dd4;},_0x13287e=function(_0x8edc57){const _0x10cc7d=_0x3887,_0x4633d7={},_0x290dd2=Cesium$5['Math'][_0x10cc7d(0x1f1)](_0x8edc57['west'],Cesium$5[_0x10cc7d(0x1db)]['TWO_PI']),_0xe98fb7=Cesium$5['Math'][_0x10cc7d(0x1f1)](_0x8edc57['east'],Cesium$5['Math'][_0x10cc7d(0x184)]),_0x2a24c3=_0x8edc57['width'];let _0x380bc4,_0x2a41b1;_0x2a24c3>Cesium$5['Math']['THREE_PI_OVER_TWO']?(_0x380bc4=0x0,_0x2a41b1=Cesium$5[_0x10cc7d(0x1db)]['TWO_PI']):_0xe98fb7-_0x290dd2<_0x2a24c3?(_0x380bc4=_0x290dd2,_0x2a41b1=_0x290dd2+_0x2a24c3):(_0x380bc4=_0x290dd2,_0x2a41b1=_0xe98fb7);_0x4633d7['lon']={'min':Cesium$5['Math'][_0x10cc7d(0x25f)](_0x380bc4),'max':Cesium$5['Math']['toDegrees'](_0x2a41b1)};const _0x2a61fb=_0x8edc57[_0x10cc7d(0x25c)],_0x149050=_0x8edc57['north'],_0x1df256=_0x8edc57[_0x10cc7d(0x1e0)],_0x153af0=_0x1df256>Cesium$5['Math']['PI']/0xc?_0x1df256/0x2:0x0;let _0x3f3198=Cesium$5['Math'][_0x10cc7d(0x1c6)](_0x2a61fb-_0x153af0),_0x4442b7=Cesium$5['Math'][_0x10cc7d(0x1c6)](_0x149050+_0x153af0);return _0x3f3198<-Cesium$5['Math']['PI_OVER_THREE']&&(_0x3f3198=-Cesium$5['Math']['PI_OVER_TWO']),_0x4442b7>Cesium$5[_0x10cc7d(0x1db)]['PI_OVER_THREE']&&(_0x4442b7=Cesium$5[_0x10cc7d(0x1db)]['PI_OVER_TWO']),_0x4633d7[_0x10cc7d(0x1c0)]={'min':Cesium$5[_0x10cc7d(0x1db)]['toDegrees'](_0x3f3198),'max':Cesium$5['Math'][_0x10cc7d(0x25f)](_0x4442b7)},_0x4633d7;};return{'getFullscreenQuad':_0xbbe4a4,'createTexture':_0x444ed9,'createFramebuffer':_0x21fc25,'createRawRenderState':_0x25025c,'viewRectangleToLonLatRange':_0x13287e};}());var segmentDraw_vert=_0x327d5f(0x23b),segmentDraw_frag='uniform\x20sampler2D\x20colorTable;\x0a\x0ain\x20float\x20speedNormalization;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20out_FragColor\x20=\x20texture(colorTable,\x20vec2(speedNormalization,\x200.0));\x0a}\x0a',fullscreen_vert='in\x20vec3\x20position;\x0ain\x20vec2\x20st;\x0a\x0aout\x20vec2\x20textureCoordinate;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20textureCoordinate\x20=\x20st;\x0a\x20\x20\x20\x20gl_Position\x20=\x20vec4(position,\x201.0);\x0a}\x0a',trailDraw_frag='uniform\x20sampler2D\x20segmentsColorTexture;\x0auniform\x20sampler2D\x20segmentsDepthTexture;\x0a\x0auniform\x20sampler2D\x20currentTrailsColor;\x0auniform\x20sampler2D\x20trailsDepthTexture;\x0a\x0auniform\x20float\x20fadeOpacity;\x0a\x0ain\x20vec2\x20textureCoordinate;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec4\x20pointsColor\x20=\x20texture(segmentsColorTexture,\x20textureCoordinate);\x0a\x20\x20\x20\x20vec4\x20trailsColor\x20=\x20texture(currentTrailsColor,\x20textureCoordinate);\x0a\x0a\x20\x20\x20\x20trailsColor\x20=\x20floor(fadeOpacity\x20*\x20255.0\x20*\x20trailsColor)\x20/\x20255.0;\x20//\x20make\x20sure\x20the\x20trailsColor\x20will\x20be\x20strictly\x20decreased\x0a\x0a\x20\x20\x20\x20float\x20pointsDepth\x20=\x20texture(segmentsDepthTexture,\x20textureCoordinate).r;\x0a\x20\x20\x20\x20float\x20trailsDepth\x20=\x20texture(trailsDepthTexture,\x20textureCoordinate).r;\x0a\x20\x20\x20\x20float\x20globeDepth\x20=\x20czm_unpackDepth(texture(czm_globeDepthTexture,\x20textureCoordinate));\x0a\x0a\x20\x20\x20\x20out_FragColor\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20if\x20(pointsDepth\x20<\x20globeDepth)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20out_FragColor\x20+\x20pointsColor;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20if\x20(trailsDepth\x20<\x20globeDepth)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20out_FragColor\x20+\x20trailsColor;\x0a\x20\x20\x20\x20}\x0a\x20\x20\x20\x20gl_FragDepth\x20=\x20min(pointsDepth,\x20trailsDepth);\x0a}\x0a',screenDraw_frag='uniform\x20sampler2D\x20trailsColorTexture;\x0auniform\x20sampler2D\x20trailsDepthTexture;\x0a\x0ain\x20vec2\x20textureCoordinate;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec4\x20trailsColor\x20=\x20texture(trailsColorTexture,\x20textureCoordinate);\x0a\x20\x20\x20\x20float\x20trailsDepth\x20=\x20texture(trailsDepthTexture,\x20textureCoordinate).r;\x0a\x20\x20\x20\x20float\x20globeDepth\x20=\x20czm_unpackDepth(texture(czm_globeDepthTexture,\x20textureCoordinate));\x0a\x0a\x20\x20\x20\x20if\x20(trailsDepth\x20<\x20globeDepth)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20trailsColor;\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20}\x0a}\x0a';const Cesium$4=mars3d__namespace['Cesium'];class ParticlesRendering{constructor(_0xcf0775,_0x54ad17,_0x598b3f,_0x4d9997,_0x4123af){const _0x59364b=_0x327d5f;this['createRenderingTextures'](_0xcf0775,_0x54ad17,_0x598b3f['colors']),this[_0x59364b(0x208)](_0xcf0775),this[_0x59364b(0x251)](_0xcf0775,_0x598b3f,_0x4d9997,_0x4123af);}[_0x327d5f(0x243)](_0x2a7fad,_0x13cc44,_0x2657a6){const _0x7c083f=_0x327d5f,_0x4d008e={'context':_0x2a7fad,'width':_0x2a7fad['drawingBufferWidth'],'height':_0x2a7fad['drawingBufferHeight'],'pixelFormat':Cesium$4['PixelFormat'][_0x7c083f(0x189)],'pixelDatatype':Cesium$4[_0x7c083f(0x1d4)]['UNSIGNED_BYTE']},_0x13d1f8={'context':_0x2a7fad,'width':_0x2a7fad[_0x7c083f(0x1e5)],'height':_0x2a7fad[_0x7c083f(0x178)],'pixelFormat':Cesium$4[_0x7c083f(0x22f)][_0x7c083f(0x23a)],'pixelDatatype':Cesium$4[_0x7c083f(0x1d4)]['UNSIGNED_INT']},_0x14cd78=_0x2657a6['length'],_0x56685d=new Float32Array(_0x14cd78*0x3);for(let _0x1c12b6=0x0;_0x1c12b6<_0x14cd78;_0x1c12b6++){const _0x58a280=Cesium$4['Color']['fromCssColorString'](_0x2657a6[_0x1c12b6]);_0x56685d[0x3*_0x1c12b6]=_0x58a280[_0x7c083f(0x1b0)],_0x56685d[0x3*_0x1c12b6+0x1]=_0x58a280['green'],_0x56685d[0x3*_0x1c12b6+0x2]=_0x58a280[_0x7c083f(0x1fa)];}const _0x54f643={'context':_0x2a7fad,'width':_0x14cd78,'height':0x1,'pixelFormat':Cesium$4['PixelFormat']['RGB'],'pixelDatatype':Cesium$4['PixelDatatype'][_0x7c083f(0x22e)],'sampler':new Cesium$4[(_0x7c083f(0x229))]({'minificationFilter':Cesium$4['TextureMinificationFilter']['LINEAR'],'magnificationFilter':Cesium$4['TextureMagnificationFilter']['LINEAR']})};this['textures']={'segmentsColor':Util['createTexture'](_0x4d008e),'segmentsDepth':Util['createTexture'](_0x13d1f8),'currentTrailsColor':Util['createTexture'](_0x4d008e),'currentTrailsDepth':Util['createTexture'](_0x13d1f8),'nextTrailsColor':Util[_0x7c083f(0x1f4)](_0x4d008e),'nextTrailsDepth':Util[_0x7c083f(0x1f4)](_0x13d1f8),'colorTable':Util['createTexture'](_0x54f643,_0x56685d)};}[_0x327d5f(0x208)](_0x893510){const _0x3c9693=_0x327d5f;this['framebuffers']={'segments':Util['createFramebuffer'](_0x893510,this['textures']['segmentsColor'],this['textures']['segmentsDepth']),'currentTrails':Util['createFramebuffer'](_0x893510,this[_0x3c9693(0x1f5)][_0x3c9693(0x174)],this[_0x3c9693(0x1f5)][_0x3c9693(0x202)]),'nextTrails':Util['createFramebuffer'](_0x893510,this['textures'][_0x3c9693(0x18e)],this['textures']['nextTrailsDepth'])};}['createSegmentsGeometry'](_0x409d7a){const _0x496603=_0x327d5f,_0x47703d=0x4;let _0x88a876=[];for(let _0x292725=0x0;_0x292725<_0x409d7a[_0x496603(0x233)];_0x292725++){for(let _0x5383d5=0x0;_0x5383d5<_0x409d7a['particlesTextureSize'];_0x5383d5++){for(let _0x122fdb=0x0;_0x122fdb<_0x47703d;_0x122fdb++){_0x88a876[_0x496603(0x1cc)](_0x292725/_0x409d7a[_0x496603(0x233)]),_0x88a876[_0x496603(0x1cc)](_0x5383d5/_0x409d7a['particlesTextureSize']);}}}_0x88a876=new Float32Array(_0x88a876);let _0x4eb047=[];const _0x150a4b=[-0x1,0x1],_0x47ce7c=[-0x1,0x1];for(let _0x1b7e06=0x0;_0x1b7e06<_0x409d7a['maxParticles'];_0x1b7e06++){for(let _0x2e759e=0x0;_0x2e759e<_0x47703d/0x2;_0x2e759e++){for(let _0x144177=0x0;_0x144177<_0x47703d/0x2;_0x144177++){_0x4eb047[_0x496603(0x1cc)](_0x150a4b[_0x2e759e]),_0x4eb047['push'](_0x47ce7c[_0x144177]),_0x4eb047['push'](0x0);}}}_0x4eb047=new Float32Array(_0x4eb047);const _0x2ae626=0x6*_0x409d7a['maxParticles'],_0x282d2e=new Uint32Array(_0x2ae626);for(let _0x243a54=0x0,_0x1ab5d1=0x0,_0x507d96=0x0;_0x243a54<_0x409d7a['maxParticles'];_0x243a54++){_0x282d2e[_0x1ab5d1++]=_0x507d96+0x0,_0x282d2e[_0x1ab5d1++]=_0x507d96+0x1,_0x282d2e[_0x1ab5d1++]=_0x507d96+0x2,_0x282d2e[_0x1ab5d1++]=_0x507d96+0x2,_0x282d2e[_0x1ab5d1++]=_0x507d96+0x1,_0x282d2e[_0x1ab5d1++]=_0x507d96+0x3,_0x507d96+=0x4;}const _0x1e6af2=new Cesium$4['Geometry']({'attributes':new Cesium$4[(_0x496603(0x219))]({'st':new Cesium$4['GeometryAttribute']({'componentDatatype':Cesium$4['ComponentDatatype']['FLOAT'],'componentsPerAttribute':0x2,'values':_0x88a876}),'normal':new Cesium$4['GeometryAttribute']({'componentDatatype':Cesium$4['ComponentDatatype']['FLOAT'],'componentsPerAttribute':0x3,'values':_0x4eb047})}),'indices':_0x282d2e});return _0x1e6af2;}['createRenderingPrimitives'](_0x36068f,_0x333fc5,_0x29b1c4,_0x1369bb){const _0x538204=_0x327d5f,_0x20179b=this;this[_0x538204(0x193)]={'segments':new CustomPrimitive({'commandType':_0x538204(0x1d0),'attributeLocations':{'st':0x0,'normal':0x1},'geometry':this['createSegmentsGeometry'](_0x333fc5),'primitiveType':Cesium$4['PrimitiveType'][_0x538204(0x1e4)],'uniformMap':{'currentParticlesPosition':function(){return _0x1369bb['particlesTextures']['currentParticlesPosition'];},'postProcessingPosition':function(){return _0x1369bb['particlesTextures']['postProcessingPosition'];},'postProcessingSpeed':function(){return _0x1369bb['particlesTextures']['postProcessingSpeed'];},'colorTable':function(){const _0x121443=_0x538204;return _0x20179b[_0x121443(0x1f5)]['colorTable'];},'aspect':function(){return _0x36068f['drawingBufferWidth']/_0x36068f['drawingBufferHeight'];},'pixelSize':function(){const _0xf94b9e=_0x538204;return _0x29b1c4[_0xf94b9e(0x221)];},'lineWidth':function(){return _0x333fc5['lineWidth'];},'particleHeight':function(){return _0x333fc5['particleHeight'];}},'vertexShaderSource':new Cesium$4['ShaderSource']({'sources':[segmentDraw_vert]}),'fragmentShaderSource':new Cesium$4[(_0x538204(0x257))]({'sources':[segmentDraw_frag]}),'rawRenderState':Util['createRawRenderState']({'viewport':undefined,'depthTest':{'enabled':!![]},'depthMask':!![]}),'framebuffer':this[_0x538204(0x1e9)][_0x538204(0x183)],'autoClear':!![]}),'trails':new CustomPrimitive({'commandType':'Draw','attributeLocations':{'position':0x0,'st':0x1},'geometry':Util[_0x538204(0x24b)](),'primitiveType':Cesium$4[_0x538204(0x1f2)]['TRIANGLES'],'uniformMap':{'segmentsColorTexture':function(){const _0x3ba674=_0x538204;return _0x20179b[_0x3ba674(0x1f5)]['segmentsColor'];},'segmentsDepthTexture':function(){return _0x20179b['textures']['segmentsDepth'];},'currentTrailsColor':function(){return _0x20179b['framebuffers']['currentTrails']['getColorTexture'](0x0);},'trailsDepthTexture':function(){return _0x20179b['framebuffers']['currentTrails']['depthTexture'];},'fadeOpacity':function(){const _0xd028b4=_0x538204;return _0x333fc5[_0xd028b4(0x19c)];}},'vertexShaderSource':new Cesium$4[(_0x538204(0x257))]({'defines':['DISABLE_GL_POSITION_LOG_DEPTH'],'sources':[fullscreen_vert]}),'fragmentShaderSource':new Cesium$4['ShaderSource']({'defines':['DISABLE_LOG_DEPTH_FRAGMENT_WRITE'],'sources':[trailDraw_frag]}),'rawRenderState':Util[_0x538204(0x203)]({'viewport':undefined,'depthTest':{'enabled':!![],'func':Cesium$4['DepthFunction']['ALWAYS']},'depthMask':!![]}),'framebuffer':this['framebuffers']['nextTrails'],'autoClear':!![],'preExecute':function(){const _0x5db82d=_0x538204,_0x5063df=_0x20179b[_0x5db82d(0x1e9)]['currentTrails'];_0x20179b['framebuffers']['currentTrails']=_0x20179b['framebuffers'][_0x5db82d(0x217)],_0x20179b['framebuffers']['nextTrails']=_0x5063df,_0x20179b['primitives'][_0x5db82d(0x200)][_0x5db82d(0x246)][_0x5db82d(0x1ac)]=_0x20179b['framebuffers'][_0x5db82d(0x217)],_0x20179b['primitives']['trails']['clearCommand']['framebuffer']=_0x20179b['framebuffers']['nextTrails'];}}),'screen':new CustomPrimitive({'commandType':'Draw','attributeLocations':{'position':0x0,'st':0x1},'geometry':Util['getFullscreenQuad'](),'primitiveType':Cesium$4['PrimitiveType']['TRIANGLES'],'uniformMap':{'trailsColorTexture':function(){return _0x20179b['framebuffers']['nextTrails']['getColorTexture'](0x0);},'trailsDepthTexture':function(){const _0x2604f6=_0x538204;return _0x20179b['framebuffers'][_0x2604f6(0x217)]['depthTexture'];}},'vertexShaderSource':new Cesium$4['ShaderSource']({'defines':['DISABLE_GL_POSITION_LOG_DEPTH'],'sources':[fullscreen_vert]}),'fragmentShaderSource':new Cesium$4['ShaderSource']({'defines':['DISABLE_LOG_DEPTH_FRAGMENT_WRITE'],'sources':[screenDraw_frag]}),'rawRenderState':Util['createRawRenderState']({'viewport':undefined,'depthTest':{'enabled':![]},'depthMask':!![],'blending':{'enabled':!![]}}),'framebuffer':undefined})};}}var getWind_frag=_0x327d5f(0x1b5),updateSpeed_frag='uniform\x20sampler2D\x20currentParticlesSpeed;\x20//\x20(u,\x20v,\x20w,\x20normalization)\x0auniform\x20sampler2D\x20particlesWind;\x0a\x0a//\x20used\x20to\x20calculate\x20the\x20wind\x20norm\x0auniform\x20vec2\x20uSpeedRange;\x20//\x20(min,\x20max);\x0auniform\x20vec2\x20vSpeedRange;\x0auniform\x20float\x20pixelSize;\x0auniform\x20float\x20speedFactor;\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0afloat\x20calculateWindNorm(vec3\x20speed)\x20{\x0a\x20\x20\x20\x20vec3\x20percent\x20=\x20vec3(0.0);\x0a\x20\x20\x20\x20percent.x\x20=\x20(speed.x\x20-\x20uSpeedRange.x)\x20/\x20(uSpeedRange.y\x20-\x20uSpeedRange.x);\x0a\x20\x20\x20\x20percent.y\x20=\x20(speed.y\x20-\x20vSpeedRange.x)\x20/\x20(vSpeedRange.y\x20-\x20vSpeedRange.x);\x0a\x20\x20\x20\x20float\x20normalization\x20=\x20length(percent);\x0a\x0a\x20\x20\x20\x20return\x20normalization;\x0a}\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20//\x20texture\x20coordinate\x20must\x20be\x20normalized\x0a\x20\x20\x20\x20//\x20vec3\x20currentSpeed\x20=\x20texture(currentParticlesSpeed,\x20v_textureCoordinates).rgb;\x0a\x20\x20\x20\x20vec3\x20windVector\x20=\x20texture(particlesWind,\x20v_textureCoordinates).rgb;\x0a\x0a\x20\x20\x20\x20vec4\x20nextSpeed\x20=\x20vec4(speedFactor\x20*\x20pixelSize\x20*\x20windVector,\x20calculateWindNorm(windVector));\x0a\x20\x20\x20\x20out_FragColor\x20=\x20nextSpeed;\x0a}\x0a',updatePosition_frag=_0x327d5f(0x1ed),postProcessingPosition_frag=_0x327d5f(0x22b),postProcessingSpeed_frag='uniform\x20sampler2D\x20postProcessingPosition;\x0auniform\x20sampler2D\x20nextParticlesSpeed;\x0a\x0ain\x20vec2\x20v_textureCoordinates;\x0a\x0avoid\x20main()\x20{\x0a\x20\x20\x20\x20vec4\x20randomParticle\x20=\x20texture(postProcessingPosition,\x20v_textureCoordinates);\x0a\x20\x20\x20\x20vec4\x20particleSpeed\x20=\x20texture(nextParticlesSpeed,\x20v_textureCoordinates);\x0a\x0a\x20\x20\x20\x20if\x20(randomParticle.a\x20>\x200.0)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20vec4(0.0);\x0a\x20\x20\x20\x20}\x20else\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20out_FragColor\x20=\x20particleSpeed;\x0a\x20\x20\x20\x20}\x0a}\x0a';const Cesium$3=mars3d__namespace['Cesium'];class ParticlesComputing{constructor(_0x3bcdf4,_0x38844e,_0x1dc705,_0x5aaf30){const _0x4fec87=_0x327d5f;this['data']=_0x38844e,this[_0x4fec87(0x1b7)](_0x3bcdf4,_0x38844e),this[_0x4fec87(0x23e)](_0x3bcdf4,_0x1dc705,_0x5aaf30),this['createComputingPrimitives'](_0x38844e,_0x1dc705,_0x5aaf30);}['createWindTextures'](_0x943b5a,_0x31a5d5){const _0x5de336=_0x327d5f,_0x9af38d={'context':_0x943b5a,'width':_0x31a5d5[_0x5de336(0x255)]['lon'],'height':_0x31a5d5[_0x5de336(0x255)]['lat']*(_0x31a5d5['dimensions']['lev']||0x1),'pixelFormat':Cesium$3[_0x5de336(0x22f)]['LUMINANCE'],'pixelDatatype':Cesium$3['PixelDatatype']['FLOAT'],'flipY':![],'sampler':new Cesium$3[(_0x5de336(0x229))]({'minificationFilter':Cesium$3['TextureMinificationFilter']['NEAREST'],'magnificationFilter':Cesium$3['TextureMagnificationFilter']['NEAREST']})};this[_0x5de336(0x1c1)]={'U':Util['createTexture'](_0x9af38d,_0x31a5d5['U']['array']),'V':Util['createTexture'](_0x9af38d,_0x31a5d5['V']['array'])};}['createParticlesTextures'](_0x5442c1,_0x17be8e,_0x1c35fe){const _0x3fc710=_0x327d5f,_0x1605fe={'context':_0x5442c1,'width':_0x17be8e['particlesTextureSize'],'height':_0x17be8e[_0x3fc710(0x233)],'pixelFormat':Cesium$3['PixelFormat']['RGBA'],'pixelDatatype':Cesium$3['PixelDatatype']['FLOAT'],'flipY':![],'sampler':new Cesium$3['Sampler']({'minificationFilter':Cesium$3['TextureMinificationFilter'][_0x3fc710(0x227)],'magnificationFilter':Cesium$3['TextureMagnificationFilter'][_0x3fc710(0x227)]})},_0x240207=this['randomizeParticles'](_0x17be8e[_0x3fc710(0x1f8)],_0x1c35fe),_0x3e6345=new Float32Array(0x4*_0x17be8e['maxParticles'])['fill'](0x0);this['particlesTextures']={'particlesWind':Util['createTexture'](_0x1605fe),'currentParticlesPosition':Util['createTexture'](_0x1605fe,_0x240207),'nextParticlesPosition':Util[_0x3fc710(0x1f4)](_0x1605fe,_0x240207),'currentParticlesSpeed':Util[_0x3fc710(0x1f4)](_0x1605fe,_0x3e6345),'nextParticlesSpeed':Util['createTexture'](_0x1605fe,_0x3e6345),'postProcessingPosition':Util[_0x3fc710(0x1f4)](_0x1605fe,_0x240207),'postProcessingSpeed':Util['createTexture'](_0x1605fe,_0x3e6345)};}['randomizeParticles'](_0x4cd67f,_0x26b400){const _0x51a8a2=_0x327d5f,_0x21164b=new Float32Array(0x4*_0x4cd67f);for(let _0x5768de=0x0;_0x5768de<_0x4cd67f;_0x5768de++){_0x21164b[0x4*_0x5768de]=Cesium$3['Math']['randomBetween'](_0x26b400['lonRange']['x'],_0x26b400['lonRange']['y']),_0x21164b[0x4*_0x5768de+0x1]=Cesium$3['Math']['randomBetween'](_0x26b400[_0x51a8a2(0x1a9)]['x'],_0x26b400['latRange']['y']),_0x21164b[0x4*_0x5768de+0x2]=Cesium$3[_0x51a8a2(0x1db)]['randomBetween'](this['data']['lev']['min'],this['data']['lev']['max']),_0x21164b[0x4*_0x5768de+0x3]=0x0;}return _0x21164b;}['destroyParticlesTextures'](){const _0x2345f9=_0x327d5f;Object['keys'](this[_0x2345f9(0x18f)])['forEach'](_0x1bb449=>{const _0x562226=_0x2345f9;this[_0x562226(0x18f)][_0x1bb449][_0x562226(0x1e8)]();});}['createComputingPrimitives'](_0x18862b,_0x3f4c11,_0x3a74cb){const _0x3d13be=_0x327d5f,_0x1c6fa8=new Cesium$3[(_0x3d13be(0x212))](_0x18862b['dimensions']['lon'],_0x18862b[_0x3d13be(0x255)][_0x3d13be(0x1c0)],_0x18862b['dimensions']['lev']),_0x47570c=new Cesium$3[(_0x3d13be(0x212))](_0x18862b[_0x3d13be(0x1ba)]['min'],_0x18862b[_0x3d13be(0x1c0)]['min'],_0x18862b[_0x3d13be(0x19a)]['min']),_0x4de53b=new Cesium$3['Cartesian3'](_0x18862b[_0x3d13be(0x1ba)][_0x3d13be(0x197)],_0x18862b[_0x3d13be(0x1c0)]['max'],_0x18862b['lev']['max']),_0x49102c=new Cesium$3['Cartesian3']((_0x4de53b['x']-_0x47570c['x'])/(_0x1c6fa8['x']-0x1),(_0x4de53b['y']-_0x47570c['y'])/(_0x1c6fa8['y']-0x1),_0x1c6fa8['z']>0x1?(_0x4de53b['z']-_0x47570c['z'])/(_0x1c6fa8['z']-0x1):0x1),_0x1dbf61=new Cesium$3['Cartesian2'](_0x18862b['U'][_0x3d13be(0x1a3)],_0x18862b['U']['max']),_0x192e23=new Cesium$3['Cartesian2'](_0x18862b['V']['min'],_0x18862b['V'][_0x3d13be(0x197)]),_0x2d01e2=this;this['primitives']={'getWind':new CustomPrimitive({'commandType':'Compute','uniformMap':{'U':function(){return _0x2d01e2['windTextures']['U'];},'V':function(){return _0x2d01e2['windTextures']['V'];},'currentParticlesPosition':function(){return _0x2d01e2['particlesTextures']['currentParticlesPosition'];},'dimension':function(){return _0x1c6fa8;},'minimum':function(){return _0x47570c;},'maximum':function(){return _0x4de53b;},'interval':function(){return _0x49102c;}},'fragmentShaderSource':new Cesium$3['ShaderSource']({'sources':[getWind_frag]}),'outputTexture':this['particlesTextures']['particlesWind'],'preExecute':function(){const _0x336de0=_0x3d13be;_0x2d01e2[_0x336de0(0x193)]['getWind']['commandToExecute']['outputTexture']=_0x2d01e2['particlesTextures']['particlesWind'];}}),'updateSpeed':new CustomPrimitive({'commandType':'Compute','uniformMap':{'currentParticlesSpeed':function(){const _0x3e8fbe=_0x3d13be;return _0x2d01e2[_0x3e8fbe(0x18f)]['currentParticlesSpeed'];},'particlesWind':function(){return _0x2d01e2['particlesTextures']['particlesWind'];},'uSpeedRange':function(){return _0x1dbf61;},'vSpeedRange':function(){return _0x192e23;},'pixelSize':function(){return _0x3a74cb['pixelSize'];},'speedFactor':function(){return _0x3f4c11['speedFactor'];}},'fragmentShaderSource':new Cesium$3[(_0x3d13be(0x257))]({'sources':[updateSpeed_frag]}),'outputTexture':this[_0x3d13be(0x18f)]['nextParticlesSpeed'],'preExecute':function(){const _0x32c2ff=_0x3d13be,_0x238df5=_0x2d01e2['particlesTextures']['currentParticlesSpeed'];_0x2d01e2['particlesTextures'][_0x32c2ff(0x236)]=_0x2d01e2['particlesTextures']['postProcessingSpeed'],_0x2d01e2[_0x32c2ff(0x18f)]['postProcessingSpeed']=_0x238df5,_0x2d01e2['primitives']['updateSpeed']['commandToExecute'][_0x32c2ff(0x1a4)]=_0x2d01e2[_0x32c2ff(0x18f)]['nextParticlesSpeed'];}}),'updatePosition':new CustomPrimitive({'commandType':_0x3d13be(0x1fb),'uniformMap':{'currentParticlesPosition':function(){return _0x2d01e2['particlesTextures']['currentParticlesPosition'];},'currentParticlesSpeed':function(){const _0x5c840c=_0x3d13be;return _0x2d01e2[_0x5c840c(0x18f)]['currentParticlesSpeed'];}},'fragmentShaderSource':new Cesium$3[(_0x3d13be(0x257))]({'sources':[updatePosition_frag]}),'outputTexture':this[_0x3d13be(0x18f)]['nextParticlesPosition'],'preExecute':function(){const _0x315e4f=_0x3d13be,_0x19fcd5=_0x2d01e2['particlesTextures'][_0x315e4f(0x1c2)];_0x2d01e2['particlesTextures']['currentParticlesPosition']=_0x2d01e2['particlesTextures']['postProcessingPosition'],_0x2d01e2[_0x315e4f(0x18f)]['postProcessingPosition']=_0x19fcd5,_0x2d01e2[_0x315e4f(0x193)][_0x315e4f(0x1f0)]['commandToExecute'][_0x315e4f(0x1a4)]=_0x2d01e2['particlesTextures']['nextParticlesPosition'];}}),'postProcessingPosition':new CustomPrimitive({'commandType':'Compute','uniformMap':{'nextParticlesPosition':function(){return _0x2d01e2['particlesTextures']['nextParticlesPosition'];},'nextParticlesSpeed':function(){return _0x2d01e2['particlesTextures']['nextParticlesSpeed'];},'lonRange':function(){return _0x3a74cb['lonRange'];},'latRange':function(){const _0x32caf8=_0x3d13be;return _0x3a74cb[_0x32caf8(0x1a9)];},'randomCoefficient':function(){const _0x1ea996=Math['random']();return _0x1ea996;},'dropRate':function(){return _0x3f4c11['dropRate'];},'dropRateBump':function(){return _0x3f4c11['dropRateBump'];}},'fragmentShaderSource':new Cesium$3[(_0x3d13be(0x257))]({'sources':[postProcessingPosition_frag]}),'outputTexture':this['particlesTextures']['postProcessingPosition'],'preExecute':function(){const _0x54f635=_0x3d13be;_0x2d01e2['primitives'][_0x54f635(0x17a)]['commandToExecute'][_0x54f635(0x1a4)]=_0x2d01e2['particlesTextures'][_0x54f635(0x17a)];}}),'postProcessingSpeed':new CustomPrimitive({'commandType':'Compute','uniformMap':{'postProcessingPosition':function(){const _0x7286b2=_0x3d13be;return _0x2d01e2[_0x7286b2(0x18f)]['postProcessingPosition'];},'nextParticlesSpeed':function(){return _0x2d01e2['particlesTextures']['nextParticlesSpeed'];}},'fragmentShaderSource':new Cesium$3['ShaderSource']({'sources':[postProcessingSpeed_frag]}),'outputTexture':this[_0x3d13be(0x18f)][_0x3d13be(0x1e7)],'preExecute':function(){_0x2d01e2['primitives']['postProcessingSpeed']['commandToExecute']['outputTexture']=_0x2d01e2['particlesTextures']['postProcessingSpeed'];}})};}}const Cesium$2=mars3d__namespace[_0x327d5f(0x22d)];function _0x3887(_0x505a9e,_0x9efc7c){const _0x539bd6=_0x539b();return _0x3887=function(_0x3887f9,_0x104667){_0x3887f9=_0x3887f9-0x173;let _0x21c11a=_0x539bd6[_0x3887f9];return _0x21c11a;},_0x3887(_0x505a9e,_0x9efc7c);}class ParticleSystem{constructor(_0x2a599d,_0x4be259,_0x3cdcb3,_0x176cbc){const _0x50658c=_0x327d5f;this['context']=_0x2a599d,_0x4be259={..._0x4be259},_0x4be259['udata']&&_0x4be259[_0x50658c(0x206)]&&(_0x4be259[_0x50658c(0x255)]={},_0x4be259['dimensions']['lon']=_0x4be259[_0x50658c(0x1cf)],_0x4be259['dimensions']['lat']=_0x4be259['rows'],_0x4be259['dimensions']['lev']=_0x4be259['lev']||0x1,_0x4be259[_0x50658c(0x1ba)]={},_0x4be259[_0x50658c(0x1ba)][_0x50658c(0x1a3)]=_0x4be259['xmin'],_0x4be259['lon']['max']=_0x4be259['xmax'],_0x4be259['lat']={},_0x4be259['lat']['min']=_0x4be259['ymin'],_0x4be259[_0x50658c(0x1c0)][_0x50658c(0x197)]=_0x4be259['ymax'],_0x4be259['lev']={},_0x4be259[_0x50658c(0x19a)][_0x50658c(0x1a3)]=_0x4be259[_0x50658c(0x24c)]??0x1,_0x4be259['lev']['max']=_0x4be259['levmax']??0x1,_0x4be259['U']={},_0x4be259['U']['array']=new Float32Array(_0x4be259[_0x50658c(0x19f)]),_0x4be259['U']['min']=_0x4be259[_0x50658c(0x247)]??Math['min'](..._0x4be259[_0x50658c(0x19f)]),_0x4be259['U'][_0x50658c(0x197)]=_0x4be259['umax']??Math[_0x50658c(0x197)](..._0x4be259['udata']),_0x4be259['V']={},_0x4be259['V']['array']=new Float32Array(_0x4be259['vdata']),_0x4be259['V']['min']=_0x4be259['vmin']??Math[_0x50658c(0x1a3)](..._0x4be259['vdata']),_0x4be259['V']['max']=_0x4be259[_0x50658c(0x211)]??Math['max'](..._0x4be259['vdata'])),this['data']=_0x4be259,this[_0x50658c(0x1de)]=_0x3cdcb3,this['viewerParameters']=_0x176cbc,this['particlesComputing']=new ParticlesComputing(this['context'],this['data'],this['options'],this['viewerParameters']),this['particlesRendering']=new ParticlesRendering(this['context'],this['data'],this['options'],this[_0x50658c(0x1ae)],this['particlesComputing']);}['canvasResize'](_0xb26b0c){const _0xa85f75=_0x327d5f;this['particlesComputing'][_0xa85f75(0x1af)](),Object[_0xa85f75(0x231)](this['particlesComputing']['windTextures'])[_0xa85f75(0x21e)](_0x20918d=>{this['particlesComputing']['windTextures'][_0x20918d]['destroy']();}),this['particlesRendering']['textures']['colorTable'][_0xa85f75(0x1e8)](),Object['keys'](this['particlesRendering'][_0xa85f75(0x1e9)])['forEach'](_0x346363=>{const _0x225f17=_0xa85f75;this[_0x225f17(0x20d)][_0x225f17(0x1e9)][_0x346363][_0x225f17(0x1e8)]();}),this[_0xa85f75(0x191)]=_0xb26b0c,this['particlesComputing']=new ParticlesComputing(this['context'],this['data'],this[_0xa85f75(0x1de)],this['viewerParameters']),this['particlesRendering']=new ParticlesRendering(this['context'],this[_0xa85f75(0x223)],this['options'],this['viewerParameters'],this[_0xa85f75(0x177)]);}[_0x327d5f(0x1b1)](){const _0x35aa3c=_0x327d5f,_0x366384=new Cesium$2['ClearCommand']({'color':new Cesium$2['Color'](0x0,0x0,0x0,0x0),'depth':0x1,'framebuffer':undefined,'pass':Cesium$2['Pass'][_0x35aa3c(0x1b3)]});Object['keys'](this[_0x35aa3c(0x20d)][_0x35aa3c(0x1e9)])['forEach'](_0x48dd3c=>{const _0x14e2d6=_0x35aa3c;_0x366384[_0x14e2d6(0x1ac)]=this[_0x14e2d6(0x20d)]['framebuffers'][_0x48dd3c],_0x366384['execute'](this['context']);});}['refreshParticles'](_0x161ef3){const _0x551fce=_0x327d5f;this['clearFramebuffers'](),this['particlesComputing']['destroyParticlesTextures'](),this[_0x551fce(0x177)]['createParticlesTextures'](this['context'],this[_0x551fce(0x1de)],this[_0x551fce(0x1ae)]);if(_0x161ef3){var _0x3d304b;const _0x2f6293=this['particlesRendering'][_0x551fce(0x214)](this[_0x551fce(0x1de)]);this['particlesRendering']['primitives'][_0x551fce(0x183)]['geometry']=_0x2f6293;const _0x52a6fb=Cesium$2['VertexArray'][_0x551fce(0x25b)]({'context':this[_0x551fce(0x191)],'geometry':_0x2f6293,'attributeLocations':this['particlesRendering']['primitives']['segments'][_0x551fce(0x179)],'bufferUsage':Cesium$2[_0x551fce(0x258)]['STATIC_DRAW']});(_0x3d304b=this[_0x551fce(0x20d)]['primitives'])!==null&&_0x3d304b!==void 0x0&&(_0x3d304b=_0x3d304b['segments'])!==null&&_0x3d304b!==void 0x0&&_0x3d304b[_0x551fce(0x246)]&&(this['particlesRendering']['primitives']['segments'][_0x551fce(0x246)][_0x551fce(0x237)]=_0x52a6fb);}}['setOptions'](_0x2869f7){const _0x32aaed=_0x327d5f;let _0x4a49cc=![];this['options']['maxParticles']!==_0x2869f7[_0x32aaed(0x1f8)]&&(_0x4a49cc=!![]),Object[_0x32aaed(0x231)](_0x2869f7)['forEach'](_0x352980=>{const _0x46caad=_0x32aaed;this[_0x46caad(0x1de)][_0x352980]=_0x2869f7[_0x352980];}),this['refreshParticles'](_0x4a49cc);}['applyViewerParameters'](_0x1e8f71){const _0x22c66a=_0x327d5f;Object[_0x22c66a(0x231)](_0x1e8f71)['forEach'](_0x200677=>{this['viewerParameters'][_0x200677]=_0x1e8f71[_0x200677];}),this['refreshParticles'](![]);}['destroy'](){const _0x183199=_0x327d5f;clearTimeout(this['canrefresh']),this['particlesComputing']['destroyParticlesTextures'](),Object[_0x183199(0x231)](this['particlesComputing'][_0x183199(0x1c1)])[_0x183199(0x21e)](_0x209e86=>{const _0x3add3b=_0x183199;this['particlesComputing'][_0x3add3b(0x1c1)][_0x209e86][_0x3add3b(0x1e8)]();}),this['particlesRendering']['textures'][_0x183199(0x264)][_0x183199(0x1e8)](),Object['keys'](this['particlesRendering']['framebuffers'])['forEach'](_0x265740=>{this['particlesRendering']['framebuffers'][_0x265740]['destroy']();});for(const _0x1d23ef in this){delete this[_0x1d23ef];}}}const Cesium$1=mars3d__namespace['Cesium'],BaseLayer$1=mars3d__namespace['layer']['BaseLayer'],DEF_OPTIONS={'particlesNumber':0x1000,'fixedHeight':0x0,'fadeOpacity':0.996,'dropRate':0.003,'dropRateBump':0.01,'speedFactor':0.5,'lineWidth':0x2,'colors':['rgb(206,255,255)']};class WindLayer extends BaseLayer$1{constructor(_0x5366cd={}){_0x5366cd={...DEF_OPTIONS,..._0x5366cd},super(_0x5366cd),this['_setOptionsHook'](_0x5366cd);}get['layer'](){return this['primitives'];}get['data'](){const _0x1bc54c=_0x327d5f;return this[_0x1bc54c(0x232)];}set[_0x327d5f(0x223)](_0x408de6){const _0x542de1=_0x327d5f;this[_0x542de1(0x190)](_0x408de6);}get['colors'](){const _0x1b5dbd=_0x327d5f;return this[_0x1b5dbd(0x1de)][_0x1b5dbd(0x240)];}set['colors'](_0x3b6ba2){const _0xc8d505=_0x327d5f;this['options']['colors']=_0x3b6ba2,this['particleSystem']&&this[_0xc8d505(0x1d6)]['setOptions']({'colors':_0x3b6ba2}),this['resize']();}['_mountedHook'](){}['_addedHook'](){const _0x192239=_0x327d5f;this['scene']=this[_0x192239(0x1d7)]['scene'],this['camera']=this['_map']['camera'],this[_0x192239(0x193)]=new Cesium$1[(_0x192239(0x215))](),this[_0x192239(0x1d7)]['scene']['primitives'][_0x192239(0x224)](this['primitives']),this['viewerParameters']={'lonRange':new Cesium$1[(_0x192239(0x1e3))](),'latRange':new Cesium$1['Cartesian2'](),'pixelSize':0x0},this[_0x192239(0x248)]=new Cesium$1['BoundingSphere'](Cesium$1['Cartesian3'][_0x192239(0x20b)],0.99*0x615299),this['updateViewerParameters'](),window['addEventListener']('resize',this['resize']['bind'](this),![]),this['mouse_down']=![],this[_0x192239(0x1b8)]=![],this['_map']['on'](mars3d__namespace[_0x192239(0x1d1)]['wheel'],this[_0x192239(0x262)],this),this['_map']['on'](mars3d__namespace['EventType']['mouseDown'],this[_0x192239(0x24f)],this),this['_map']['on'](mars3d__namespace['EventType']['mouseUp'],this['_onMouseUpEvent'],this),this['_map']['on'](mars3d__namespace['EventType']['mouseMove'],this[_0x192239(0x1d2)],this),this['_data']&&this['setData'](this[_0x192239(0x232)]);}['_removedHook'](){const _0x3e4687=_0x327d5f;window[_0x3e4687(0x220)](_0x3e4687(0x1ce),this[_0x3e4687(0x1ce)]),this['_map']['off'](mars3d__namespace['EventType']['preRender'],this['_onMap_preRenderEvent'],this),this[_0x3e4687(0x1d7)]['off'](mars3d__namespace['EventType']['wheel'],this['_onMapWhellEvent'],this),this[_0x3e4687(0x1d7)][_0x3e4687(0x24e)](mars3d__namespace['EventType']['mouseDown'],this['_onMouseDownEvent'],this),this[_0x3e4687(0x1d7)][_0x3e4687(0x24e)](mars3d__namespace[_0x3e4687(0x1d1)]['mouseUp'],this['_onMouseUpEvent'],this),this['_map'][_0x3e4687(0x24e)](mars3d__namespace['EventType'][_0x3e4687(0x18d)],this[_0x3e4687(0x1d2)],this),this['primitives']['removeAll'](),this['_map']['scene'][_0x3e4687(0x193)]['remove'](this['primitives']);}[_0x327d5f(0x1ce)](){const _0x5590c9=_0x327d5f;if(!this['show']||!this[_0x5590c9(0x1d6)])return;this['primitives'][_0x5590c9(0x24a)]=![],this[_0x5590c9(0x193)]['removeAll'](),this['_map'][_0x5590c9(0x1b2)](mars3d__namespace['EventType']['preRender'],this[_0x5590c9(0x239)],this);}[_0x327d5f(0x239)](_0x4c1ad7){const _0x2d7d65=_0x327d5f;this['particleSystem'][_0x2d7d65(0x209)](this['scene']['context']),this['addPrimitives'](),this['primitives']['show']=!![];}['_onMapWhellEvent'](_0x3a9161){const _0x57d068=_0x327d5f;clearTimeout(this['refreshTimer']);if(!this['show']||!this['particleSystem'])return;this['primitives']['show']=![],this[_0x57d068(0x182)]=setTimeout(()=>{if(!this['show'])return;this['redraw']();},0xc8);}[_0x327d5f(0x24f)](_0x351fbf){this['mouse_down']=!![];}['_onMouseMoveEvent'](_0x587b8f){const _0x3ebd1a=_0x327d5f;if(!this['show']||!this[_0x3ebd1a(0x1d6)])return;this['mouse_down']&&(this['primitives']['show']=![],this['mouse_move']=!![]);}['_onMouseUpEvent'](_0x42646d){if(!this['show']||!this['particleSystem'])return;this['mouse_down']&&this['mouse_move']&&this['redraw'](),this['primitives']['show']=!![],this['mouse_down']=![],this['mouse_move']=![];}['redraw'](){if(!this['_map']||!this['show'])return;this['updateViewerParameters'](),this['particleSystem']['applyViewerParameters'](this['viewerParameters']),this['primitives']['show']=!![];}['setData'](_0x43d43f){const _0x7050cf=_0x327d5f;this[_0x7050cf(0x232)]=_0x43d43f,this['particleSystem']&&this['particleSystem']['destroy'](),this[_0x7050cf(0x1d6)]=new ParticleSystem(this['scene'][_0x7050cf(0x191)],_0x43d43f,this[_0x7050cf(0x205)](),this['viewerParameters']),this['addPrimitives']();}['_setOptionsHook'](_0x2cf795,_0x3526df){const _0xd9c0f3=_0x327d5f;if(_0x2cf795)for(const _0x568ba7 in _0x2cf795){this[_0x568ba7]=_0x2cf795[_0x568ba7];}this[_0xd9c0f3(0x1d6)]&&this['particleSystem']['setOptions'](this['getOptions']());}[_0x327d5f(0x205)](){const _0x45ae4c=_0x327d5f,_0x369056=Math[_0x45ae4c(0x21a)](Math['sqrt'](this['particlesNumber']));return this['particlesNumber']=_0x369056*_0x369056,{'particlesTextureSize':_0x369056,'maxParticles':this[_0x45ae4c(0x20a)],'particleHeight':this['fixedHeight'],'fadeOpacity':this['fadeOpacity'],'dropRate':this['dropRate'],'dropRateBump':this['dropRateBump'],'speedFactor':this['speedFactor'],'lineWidth':this[_0x45ae4c(0x1a5)],'colors':this['colors']};}[_0x327d5f(0x20e)](){const _0x24655f=_0x327d5f;this['primitives'][_0x24655f(0x224)](this[_0x24655f(0x1d6)]['particlesComputing'][_0x24655f(0x193)][_0x24655f(0x18c)]),this['primitives']['add'](this[_0x24655f(0x1d6)][_0x24655f(0x177)]['primitives'][_0x24655f(0x20f)]),this[_0x24655f(0x193)]['add'](this[_0x24655f(0x1d6)]['particlesComputing']['primitives'][_0x24655f(0x1f0)]),this['primitives']['add'](this['particleSystem'][_0x24655f(0x177)]['primitives'][_0x24655f(0x17a)]),this['primitives'][_0x24655f(0x224)](this['particleSystem']['particlesComputing']['primitives']['postProcessingSpeed']),this['primitives'][_0x24655f(0x224)](this[_0x24655f(0x1d6)]['particlesRendering'][_0x24655f(0x193)]['segments']),this['primitives'][_0x24655f(0x224)](this['particleSystem'][_0x24655f(0x20d)][_0x24655f(0x193)][_0x24655f(0x200)]),this['primitives'][_0x24655f(0x224)](this[_0x24655f(0x1d6)]['particlesRendering']['primitives']['screen']);}['updateViewerParameters'](){const _0x468bdf=_0x327d5f;let _0xfaeef1=this[_0x468bdf(0x1a2)]['computeViewRectangle'](this[_0x468bdf(0x1aa)]['globe'][_0x468bdf(0x19d)]);if(!_0xfaeef1){const _0x66c69f=this['_map'][_0x468bdf(0x1e6)]();_0xfaeef1=Cesium$1['Rectangle']['fromDegrees'](_0x66c69f[_0x468bdf(0x25a)],_0x66c69f['ymin'],_0x66c69f['xmax'],_0x66c69f['ymax']);}const _0xe0ddf3=Util['viewRectangleToLonLatRange'](_0xfaeef1);this['viewerParameters']['lonRange']['x']=_0xe0ddf3['lon']['min'],this['viewerParameters']['lonRange']['y']=_0xe0ddf3[_0x468bdf(0x1ba)]['max'],this['viewerParameters']['latRange']['x']=_0xe0ddf3['lat']['min'],this['viewerParameters']['latRange']['y']=_0xe0ddf3['lat']['max'];const _0x53fb90=this['camera']['getPixelSize'](this[_0x468bdf(0x248)],this[_0x468bdf(0x1aa)][_0x468bdf(0x1e5)],this['scene']['drawingBufferHeight']);_0x53fb90>0x0&&(this['viewerParameters'][_0x468bdf(0x221)]=_0x53fb90);}}mars3d__namespace[_0x327d5f(0x1c7)][_0x327d5f(0x21d)]('wind',WindLayer),mars3d__namespace[_0x327d5f(0x259)]['WindLayer']=WindLayer;class CanvasParticle{constructor(){const _0x4a7bfe=_0x327d5f;this['lng']=null,this['lat']=null,this[_0x4a7bfe(0x222)]=null,this['tlat']=null,this['age']=null,this['speed']=null;}[_0x327d5f(0x1e8)](){for(const _0x8b26fd in this){delete this[_0x8b26fd];}}}class CanvasWindField{constructor(_0x3f480a){this['setOptions'](_0x3f480a);}get[_0x327d5f(0x245)](){const _0x1a3593=_0x327d5f;return this[_0x1a3593(0x226)];}set[_0x327d5f(0x245)](_0x441fa1){const _0x36f47a=_0x327d5f;this['_speedRate']=(0x64-(_0x441fa1>0x63?0x63:_0x441fa1))*0x64,this[_0x36f47a(0x234)]=[(this['xmax']-this[_0x36f47a(0x25a)])/this['_speedRate'],(this['ymax']-this[_0x36f47a(0x22a)])/this['_speedRate']];}get[_0x327d5f(0x1ff)](){return this['_maxAge'];}set[_0x327d5f(0x1ff)](_0x403a03){const _0x20be6c=_0x327d5f;this[_0x20be6c(0x261)]=_0x403a03;}['setOptions'](_0x272718){const _0x153245=_0x327d5f;this['options']=_0x272718,this['maxAge']=_0x272718[_0x153245(0x1ff)]||0x78,this['speedRate']=_0x272718['speedRate']||0x32,this[_0x153245(0x1b4)]=[];const _0x32c6d5=_0x272718[_0x153245(0x20a)]||0x1000;for(let _0x280f1b=0x0;_0x280f1b<_0x32c6d5;_0x280f1b++){const _0x4a7cfc=this['_randomParticle'](new CanvasParticle());this['particles']['push'](_0x4a7cfc);}}[_0x327d5f(0x210)](_0x3b5fbf){const _0x261ca8=_0x327d5f;this['rows']=_0x3b5fbf['rows'],this['cols']=_0x3b5fbf[_0x261ca8(0x1cf)],this['xmin']=_0x3b5fbf[_0x261ca8(0x25a)],this['xmax']=_0x3b5fbf['xmax'],this['ymin']=_0x3b5fbf[_0x261ca8(0x22a)],this[_0x261ca8(0x235)]=_0x3b5fbf['ymax'],this['grid']=[];const _0x25d358=_0x3b5fbf['udata'],_0x4f6a04=_0x3b5fbf[_0x261ca8(0x206)];let _0x5d2ddd=![];_0x25d358['length']===this['rows']&&_0x25d358[0x0]['length']===this[_0x261ca8(0x1cf)]&&(_0x5d2ddd=!![]);let _0x5b4dbd=0x0,_0x495b65=null,_0x26b18a=null;for(let _0x828293=0x0;_0x828293<this['rows'];_0x828293++){_0x495b65=[];for(let _0x387abe=0x0;_0x387abe<this['cols'];_0x387abe++,_0x5b4dbd++){_0x5d2ddd?_0x26b18a=this[_0x261ca8(0x25e)](_0x25d358[_0x828293][_0x387abe],_0x4f6a04[_0x828293][_0x387abe]):_0x26b18a=this[_0x261ca8(0x25e)](_0x25d358[_0x5b4dbd],_0x4f6a04[_0x5b4dbd]),_0x495b65['push'](_0x26b18a);}this['grid']['push'](_0x495b65);}this['options'][_0x261ca8(0x1c4)]&&this[_0x261ca8(0x213)][_0x261ca8(0x1c3)]();}['clear'](){const _0x436874=_0x327d5f;delete this['rows'],delete this['cols'],delete this[_0x436874(0x25a)],delete this['xmax'],delete this[_0x436874(0x22a)],delete this[_0x436874(0x235)],delete this[_0x436874(0x213)],delete this['particles'];}['toGridXY'](_0x7eb4ac,_0x2bfd8c){const _0x324ccd=_0x327d5f,_0x4d252e=(_0x7eb4ac-this['xmin'])/(this['xmax']-this[_0x324ccd(0x25a)])*(this['cols']-0x1),_0x2307d2=(this['ymax']-_0x2bfd8c)/(this['ymax']-this['ymin'])*(this[_0x324ccd(0x1c8)]-0x1);return[_0x4d252e,_0x2307d2];}[_0x327d5f(0x1d9)](_0x513d70,_0x63af1e){const _0x52bd22=_0x327d5f;if(_0x513d70<0x0||_0x513d70>=this['cols']||_0x63af1e>=this['rows'])return[0x0,0x0,0x0];const _0x4a6b13=Math['floor'](_0x513d70),_0x2cdce9=Math['floor'](_0x63af1e);if(_0x4a6b13===_0x513d70&&_0x2cdce9===_0x63af1e)return this[_0x52bd22(0x213)][_0x63af1e][_0x513d70];const _0x151eac=_0x4a6b13+0x1,_0xa3c21d=_0x2cdce9+0x1,_0x291e7b=this['getUVByXY'](_0x4a6b13,_0x2cdce9),_0x421288=this['getUVByXY'](_0x151eac,_0x2cdce9),_0x5ee280=this[_0x52bd22(0x1d9)](_0x4a6b13,_0xa3c21d),_0x650e61=this[_0x52bd22(0x1d9)](_0x151eac,_0xa3c21d);let _0x445e6c=null;try{_0x445e6c=this[_0x52bd22(0x17e)](_0x513d70-_0x4a6b13,_0x63af1e-_0x2cdce9,_0x291e7b,_0x421288,_0x5ee280,_0x650e61);}catch(_0x3a6c88){console[_0x52bd22(0x207)](_0x513d70,_0x63af1e);}return _0x445e6c;}['_bilinearInterpolation'](_0x15c414,_0x2e2e48,_0x4693dc,_0x6d849d,_0x45e915,_0x5a0cf1){const _0x306658=0x1-_0x15c414,_0x1996f2=0x1-_0x2e2e48,_0x126014=_0x306658*_0x1996f2,_0x4c3a00=_0x15c414*_0x1996f2,_0x2d656b=_0x306658*_0x2e2e48,_0x4307c3=_0x15c414*_0x2e2e48,_0x130961=_0x4693dc[0x0]*_0x126014+_0x6d849d[0x0]*_0x4c3a00+_0x45e915[0x0]*_0x2d656b+_0x5a0cf1[0x0]*_0x4307c3,_0x45be5b=_0x4693dc[0x1]*_0x126014+_0x6d849d[0x1]*_0x4c3a00+_0x45e915[0x1]*_0x2d656b+_0x5a0cf1[0x1]*_0x4307c3;return this['_calcUV'](_0x130961,_0x45be5b);}['_calcUV'](_0x141cc9,_0x269cc8){return[+_0x141cc9,+_0x269cc8,Math['sqrt'](_0x141cc9*_0x141cc9+_0x269cc8*_0x269cc8)];}['getUVByPoint'](_0xb5ee0b,_0x32facf){if(!this['isInExtent'](_0xb5ee0b,_0x32facf))return null;const _0x35e35f=this['toGridXY'](_0xb5ee0b,_0x32facf),_0x459119=this['getUVByXY'](_0x35e35f[0x0],_0x35e35f[0x1]);return _0x459119;}['isInExtent'](_0x4eea62,_0x11de61){const _0x18d4a2=_0x327d5f;return _0x4eea62>=this['xmin']&&_0x4eea62<=this[_0x18d4a2(0x25d)]&&_0x11de61>=this[_0x18d4a2(0x22a)]&&_0x11de61<=this['ymax']?!![]:![];}['getRandomLatLng'](){const _0x5229a5=_0x327d5f,_0x52d491=fRandomByfloat(this['xmin'],this[_0x5229a5(0x25d)]),_0x26755a=fRandomByfloat(this['ymin'],this['ymax']);return{'lat':_0x26755a,'lng':_0x52d491};}[_0x327d5f(0x1ca)](){const _0x337616=_0x327d5f;let _0x27c9b0,_0x20538f,_0xe2532a;for(let _0xe117c6=0x0,_0x2bb00c=this[_0x337616(0x1b4)]['length'];_0xe117c6<_0x2bb00c;_0xe117c6++){let _0x3ea32a=this[_0x337616(0x1b4)][_0xe117c6];_0x3ea32a[_0x337616(0x1f3)]<=0x0&&(_0x3ea32a=this[_0x337616(0x185)](_0x3ea32a));if(_0x3ea32a['age']>0x0){const _0x49834a=_0x3ea32a[_0x337616(0x222)],_0x19a417=_0x3ea32a['tlat'];_0xe2532a=this[_0x337616(0x1d5)](_0x49834a,_0x19a417),_0xe2532a?(_0x27c9b0=_0x49834a+this[_0x337616(0x234)][0x0]*_0xe2532a[0x0],_0x20538f=_0x19a417+this['_calc_speedRate'][0x1]*_0xe2532a[0x1],_0x3ea32a['lng']=_0x49834a,_0x3ea32a['lat']=_0x19a417,_0x3ea32a['tlng']=_0x27c9b0,_0x3ea32a['tlat']=_0x20538f,_0x3ea32a[_0x337616(0x1ec)]=_0xe2532a[0x2],_0x3ea32a['age']--):_0x3ea32a['age']=0x0;}}return this['particles'];}['_randomParticle'](_0x18c911){const _0x1e3f02=_0x327d5f;let _0x35cb42,_0x496607;for(let _0x1f1fbf=0x0;_0x1f1fbf<0x1e;_0x1f1fbf++){_0x35cb42=this['getRandomLatLng'](),_0x496607=this['getUVByPoint'](_0x35cb42['lng'],_0x35cb42[_0x1e3f02(0x1c0)]);if(_0x496607&&_0x496607[0x2]>0x0)break;}if(!_0x496607)return _0x18c911;const _0x51fcd5=_0x35cb42['lng']+this['_calc_speedRate'][0x0]*_0x496607[0x0],_0x5deb3b=_0x35cb42[_0x1e3f02(0x1c0)]+this['_calc_speedRate'][0x1]*_0x496607[0x1];return _0x18c911[_0x1e3f02(0x23c)]=_0x35cb42['lng'],_0x18c911[_0x1e3f02(0x1c0)]=_0x35cb42[_0x1e3f02(0x1c0)],_0x18c911[_0x1e3f02(0x222)]=_0x51fcd5,_0x18c911['tlat']=_0x5deb3b,_0x18c911['age']=Math['round'](Math[_0x1e3f02(0x18b)]()*this['maxAge']),_0x18c911[_0x1e3f02(0x1ec)]=_0x496607[0x2],_0x18c911;}[_0x327d5f(0x1e8)](){for(const _0x5a50f7 in this){delete this[_0x5a50f7];}}}function fRandomByfloat(_0x2d3d2a,_0x359ab7){return _0x2d3d2a+Math['random']()*(_0x359ab7-_0x2d3d2a);}const Cesium=mars3d__namespace[_0x327d5f(0x22d)],BaseLayer=mars3d__namespace['layer'][_0x327d5f(0x186)];class CanvasWindLayer extends BaseLayer{constructor(_0x4597de={}){const _0x16b619=_0x327d5f;super(_0x4597de),this['_setOptionsHook'](_0x4597de),this['canvas']=null,_0x4597de['colors']&&_0x4597de[_0x16b619(0x17c)]&&(this['_colorRamp']=new mars3d__namespace['ColorRamp'](_0x4597de));}['_setOptionsHook'](_0x1e06d6,_0x5d32b1){const _0x5bb498=_0x327d5f;this['frameTime']=0x3e8/(_0x1e06d6['frameRate']||0xa),this['_pointerEvents']=this['options'][_0x5bb498(0x199)]??![],this['color']=_0x1e06d6[_0x5bb498(0x1bc)]||'#ffffff',this['lineWidth']=_0x1e06d6[_0x5bb498(0x1a5)]||0x1,this[_0x5bb498(0x256)]=_0x1e06d6[_0x5bb498(0x256)]??0x0,this[_0x5bb498(0x1c4)]=_0x1e06d6[_0x5bb498(0x1c4)]??![],this['windField']&&this['windField'][_0x5bb498(0x23f)](_0x1e06d6);}get['layer'](){return this['canvas'];}get[_0x327d5f(0x1ee)](){const _0x1351fa=_0x327d5f;return this['_map']['scene'][_0x1351fa(0x201)]['clientWidth'];}get['canvasHeight'](){const _0x52b15a=_0x327d5f;return this[_0x52b15a(0x1d7)]['scene'][_0x52b15a(0x201)]['clientHeight'];}get['pointerEvents'](){const _0x1f883c=_0x327d5f;return this[_0x1f883c(0x17b)];}set['pointerEvents'](_0x2f93ad){const _0x5c855c=_0x327d5f;this['_pointerEvents']=_0x2f93ad;if(!this['canvas'])return;_0x2f93ad?this['canvas']['style'][_0x5c855c(0x1dc)]=_0x5c855c(0x17f):this['canvas']['style']['pointer-events']='none';}get['particlesNumber'](){const _0x3fdc64=_0x327d5f;return this[_0x3fdc64(0x1de)]['particlesNumber'];}set[_0x327d5f(0x20a)](_0x1633b5){const _0x324e9d=_0x327d5f;this[_0x324e9d(0x1de)][_0x324e9d(0x20a)]=_0x1633b5,clearTimeout(this['_canrefresh']),this['_canrefresh']=setTimeout(()=>{this['redraw']();},0x1f4);}get[_0x327d5f(0x245)](){const _0x53d02a=_0x327d5f;return this[_0x53d02a(0x1de)][_0x53d02a(0x245)];}set['speedRate'](_0x1fdff6){const _0x52eefa=_0x327d5f;this['options'][_0x52eefa(0x245)]=_0x1fdff6,this[_0x52eefa(0x1ef)]&&(this[_0x52eefa(0x1ef)]['speedRate']=_0x1fdff6);}get[_0x327d5f(0x1ff)](){return this['options']['maxAge'];}set['maxAge'](_0x3314f6){const _0x48e881=_0x327d5f;this['options']['maxAge']=_0x3314f6,this['windField']&&(this['windField'][_0x48e881(0x1ff)]=_0x3314f6);}get[_0x327d5f(0x223)](){const _0x184821=_0x327d5f;return this[_0x184821(0x1b9)];}set[_0x327d5f(0x223)](_0x19e7d3){this['setData'](_0x19e7d3);}['_showHook'](_0x2815a5){const _0x1596da=_0x327d5f;_0x2815a5?this['_addedHook']():(this[_0x1596da(0x1b9)]&&(this[_0x1596da(0x1de)]['data']=this['windData']),this[_0x1596da(0x1e2)]());}[_0x327d5f(0x19e)](){const _0x3c0ef4=_0x327d5f;this[_0x3c0ef4(0x1de)][_0x3c0ef4(0x1a8)]?this[_0x3c0ef4(0x1b6)]():this[_0x3c0ef4(0x1ef)]=new CanvasWindField(this[_0x3c0ef4(0x1de)]);}['_addedHook'](){const _0x4a3144=_0x327d5f;this['canvas']=this['_createCanvas'](),this['canvasContext']=this[_0x4a3144(0x201)]['getContext']('2d',{'willReadFrequently':!![]}),this['bindEvent'](),this[_0x4a3144(0x1de)][_0x4a3144(0x223)]&&this['setData'](this['options'][_0x4a3144(0x223)]);}[_0x327d5f(0x1e2)](){const _0x28a464=_0x327d5f;this[_0x28a464(0x1f7)](),this['unbindEvent'](),this['canvas']&&(this['_map']['container'][_0x28a464(0x216)](this['canvas']),delete this['canvas']);}[_0x327d5f(0x21b)](){const _0x3cfa74=_0x327d5f,_0x4c7345=mars3d__namespace['DomUtil'][_0x3cfa74(0x204)]('canvas',_0x3cfa74(0x1d8),this['_map']['container']);return _0x4c7345[_0x3cfa74(0x23d)]['position']='absolute',_0x4c7345['style'][_0x3cfa74(0x19b)]='0px',_0x4c7345[_0x3cfa74(0x23d)][_0x3cfa74(0x1da)]='0px',_0x4c7345['style']['width']=this['_map']['scene'][_0x3cfa74(0x201)]['clientWidth']+'px',_0x4c7345['style']['height']=this[_0x3cfa74(0x1d7)]['scene'][_0x3cfa74(0x201)]['clientHeight']+'px',_0x4c7345[_0x3cfa74(0x23d)][_0x3cfa74(0x199)]=this['_pointerEvents']?'auto':'none',_0x4c7345['style'][_0x3cfa74(0x187)]=this['options']['zIndex']??0x9,_0x4c7345['width']=this[_0x3cfa74(0x1d7)][_0x3cfa74(0x1aa)]['canvas']['clientWidth'],_0x4c7345['height']=this[_0x3cfa74(0x1d7)]['scene'][_0x3cfa74(0x201)][_0x3cfa74(0x230)],_0x4c7345;}['resize'](){const _0x55197a=_0x327d5f;this[_0x55197a(0x201)]&&(this['canvas']['style']['width']=this[_0x55197a(0x1d7)]['scene']['canvas']['clientWidth']+'px',this['canvas']['style']['height']=this['_map']['scene'][_0x55197a(0x201)][_0x55197a(0x230)]+'px',this['canvas']['width']=this['_map']['scene'][_0x55197a(0x201)]['clientWidth'],this[_0x55197a(0x201)]['height']=this['_map'][_0x55197a(0x1aa)]['canvas']['clientHeight']);}['bindEvent'](){const _0x1b9b6b=_0x327d5f,_0xa784c0=this;let _0x540c5c=Date[_0x1b9b6b(0x1a6)]();(function _0x29b513(){const _0x1af060=_0x1b9b6b;_0xa784c0['animateFrame']=window['requestAnimationFrame'](_0x29b513);if(_0xa784c0['show']&&_0xa784c0[_0x1af060(0x1ef)]){const _0x53640b=Date['now'](),_0x5d3a74=_0x53640b-_0x540c5c;_0x5d3a74>_0xa784c0[_0x1af060(0x1ea)]&&(_0x540c5c=_0x53640b-_0x5d3a74%_0xa784c0['frameTime'],_0xa784c0['update']());}}(),window['addEventListener'](_0x1b9b6b(0x1ce),this['resize']['bind'](this),![]),this[_0x1b9b6b(0x195)]=![],this['mouse_move']=![],this['options']['mouseHidden']&&(this['_map']['on'](mars3d__namespace[_0x1b9b6b(0x1d1)]['wheel'],this[_0x1b9b6b(0x262)],this),this['_map']['on'](mars3d__namespace['EventType']['mouseDown'],this['_onMouseDownEvent'],this),this[_0x1b9b6b(0x1d7)]['on'](mars3d__namespace['EventType']['mouseUp'],this['_onMouseUpEvent'],this)));}['unbindEvent'](){const _0x50ae0b=_0x327d5f;window['cancelAnimationFrame'](this[_0x50ae0b(0x1eb)]),delete this[_0x50ae0b(0x1eb)],window[_0x50ae0b(0x220)]('resize',this['resize']),this['options']['mouseHidden']&&(this['_map'][_0x50ae0b(0x24e)](mars3d__namespace['EventType']['wheel'],this[_0x50ae0b(0x262)],this),this[_0x50ae0b(0x1d7)]['off'](mars3d__namespace[_0x50ae0b(0x1d1)]['mouseDown'],this['_onMouseDownEvent'],this),this['_map']['off'](mars3d__namespace['EventType'][_0x50ae0b(0x1cd)],this['_onMouseUpEvent'],this),this['_map']['off'](mars3d__namespace[_0x50ae0b(0x1d1)]['mouseMove'],this['_onMouseMoveEvent'],this));}[_0x327d5f(0x262)](_0x459782){const _0x5a1511=_0x327d5f;clearTimeout(this['refreshTimer']);if(!this['show']||!this['canvas'])return;this['canvas']['style']['visibility']='hidden',this[_0x5a1511(0x182)]=setTimeout(()=>{const _0x17f4db=_0x5a1511;if(!this['show'])return;this[_0x17f4db(0x194)](),this[_0x17f4db(0x201)][_0x17f4db(0x23d)][_0x17f4db(0x218)]=_0x17f4db(0x244);},0xc8);}['_onMouseDownEvent'](_0x20e84a){const _0x761044=_0x327d5f;this[_0x761044(0x195)]=!![],this['_map'][_0x761044(0x24e)](mars3d__namespace['EventType'][_0x761044(0x18d)],this['_onMouseMoveEvent'],this),this[_0x761044(0x1d7)]['on'](mars3d__namespace['EventType'][_0x761044(0x18d)],this[_0x761044(0x1d2)],this);}['_onMouseMoveEvent'](_0x3fb82a){const _0xb4ec6a=_0x327d5f;if(!this['show']||!this['canvas'])return;this['mouse_down']&&(this['canvas']['style']['visibility']=_0xb4ec6a(0x249),this['mouse_move']=!![]);}[_0x327d5f(0x1bd)](_0x1ad136){const _0x51e0b7=_0x327d5f;if(!this[_0x51e0b7(0x24a)]||!this['canvas'])return;this['_map']['off'](mars3d__namespace['EventType']['mouseMove'],this[_0x51e0b7(0x1d2)],this),this['mouse_down']&&this['mouse_move']&&this['redraw'](),this['canvas'][_0x51e0b7(0x23d)]['visibility']='visible',this[_0x51e0b7(0x195)]=![],this['mouse_move']=![];}['setData'](_0x2253d0){const _0x8a27dc=_0x327d5f;this[_0x8a27dc(0x1f7)](),this[_0x8a27dc(0x1b9)]=_0x2253d0,this['windField'][_0x8a27dc(0x210)](_0x2253d0),this[_0x8a27dc(0x194)]();}['redraw'](){const _0x18c469=_0x327d5f;if(!this['show'])return;this['windField'][_0x18c469(0x23f)](this['options']),this[_0x18c469(0x1e1)]();}['update'](){const _0x15ba5f=_0x327d5f;if(this['_updateIng'])return;this[_0x15ba5f(0x21c)]=!![];if(this['worker'])this['windField'][_0x15ba5f(0x1e1)]();else{const _0xf00f6b=this[_0x15ba5f(0x1ef)][_0x15ba5f(0x1ca)]();this['_drawLines'](_0xf00f6b);}this['_updateIng']=![];}['_drawLines'](_0x2ee3d8){const _0x317f25=_0x327d5f;this['canvasContext']['globalCompositeOperation']=_0x317f25(0x175),this['canvasContext']['fillRect'](0x0,0x0,this[_0x317f25(0x1ee)],this['canvasHeight']),this['canvasContext']['globalCompositeOperation']='lighter',this['canvasContext'][_0x317f25(0x1a1)]=0.9;const _0x478048=this['_map'][_0x317f25(0x1aa)]['mode']!==Cesium[_0x317f25(0x1fe)]['SCENE3D'],_0x4c4a1a=this[_0x317f25(0x1ee)]*0.25;if(this['_colorRamp'])for(let _0x31b0a8=0x0,_0x1e4af0=_0x2ee3d8['length'];_0x31b0a8<_0x1e4af0;_0x31b0a8++){const _0x229802=_0x2ee3d8[_0x31b0a8],_0x4682fe=this['_tomap'](_0x229802[_0x317f25(0x23c)],_0x229802[_0x317f25(0x1c0)],_0x229802),_0xf57fc7=this['_tomap'](_0x229802['tlng'],_0x229802['tlat'],_0x229802);if(!_0x4682fe||!_0xf57fc7)continue;if(_0x478048&&Math['abs'](_0x4682fe[0x0]-_0xf57fc7[0x0])>=_0x4c4a1a)continue;this['canvasContext']['beginPath'](),this['canvasContext']['lineWidth']=this['lineWidth'],this['canvasContext'][_0x317f25(0x24d)]=this['_colorRamp']['getColor'](_0x229802['speed']),this['canvasContext']['moveTo'](_0x4682fe[0x0],_0x4682fe[0x1]),this['canvasContext']['lineTo'](_0xf57fc7[0x0],_0xf57fc7[0x1]),this['canvasContext']['stroke']();}else{this['canvasContext']['beginPath'](),this['canvasContext'][_0x317f25(0x1a5)]=this[_0x317f25(0x1a5)],this['canvasContext']['strokeStyle']=this['color'];for(let _0xb2ee38=0x0,_0xf2f198=_0x2ee3d8[_0x317f25(0x1be)];_0xb2ee38<_0xf2f198;_0xb2ee38++){const _0x3a3330=_0x2ee3d8[_0xb2ee38],_0x9e907d=this[_0x317f25(0x238)](_0x3a3330['lng'],_0x3a3330['lat'],_0x3a3330),_0xee520f=this[_0x317f25(0x238)](_0x3a3330['tlng'],_0x3a3330[_0x317f25(0x1dd)],_0x3a3330);if(!_0x9e907d||!_0xee520f)continue;if(_0x478048&&Math['abs'](_0x9e907d[0x0]-_0xee520f[0x0])>=_0x4c4a1a)continue;this[_0x317f25(0x176)]['moveTo'](_0x9e907d[0x0],_0x9e907d[0x1]),this['canvasContext']['lineTo'](_0xee520f[0x0],_0xee520f[0x1]);}this['canvasContext']['stroke']();}}['_tomap'](_0xb99157,_0x5f1e13,_0xfdf5d1){const _0x1266b8=_0x327d5f,_0x9ea0e6=Cesium['Cartesian3'][_0x1266b8(0x1ad)](_0xb99157,_0x5f1e13,this[_0x1266b8(0x256)]),_0x305cdc=this[_0x1266b8(0x1d7)]['scene'];if(_0x305cdc[_0x1266b8(0x1bf)]===Cesium['SceneMode']['SCENE3D']){const _0x24e714=new Cesium['EllipsoidalOccluder'](_0x305cdc['globe']['ellipsoid'],_0x305cdc['camera']['positionWC']),_0x4118c9=_0x24e714['isPointVisible'](_0x9ea0e6);if(!_0x4118c9)return _0xfdf5d1['age']=0x0,null;}const _0x1d7a77=Cesium['SceneTransforms']['wgs84ToWindowCoordinates'](this['_map']['scene'],_0x9ea0e6);return _0x1d7a77?[_0x1d7a77['x'],_0x1d7a77['y']]:null;}['clear'](){const _0x1e2905=_0x327d5f;this['windField'][_0x1e2905(0x1f7)](),delete this['windData'];}['initWorker'](){const _0x361aff=_0x327d5f;this['worker']=new Worker(this['options'][_0x361aff(0x1a8)]),this[_0x361aff(0x1a8)][_0x361aff(0x241)]=_0x2d361f=>{const _0x161372=_0x361aff;this['_drawLines'](_0x2d361f['data']['particles']),this[_0x161372(0x198)]=![];},this['windField']={'init':_0x69d95f=>{const _0x540721=_0x361aff;this['worker']['postMessage']({'type':_0x540721(0x21f),'options':_0x69d95f});},'setOptions':_0x1b2cd7=>{const _0x36a705=_0x361aff;this['worker'][_0x36a705(0x22c)]({'type':'setOptions','options':_0x1b2cd7});},'setDate':_0x3b7a98=>{const _0xca6885=_0x361aff;this[_0xca6885(0x1a8)][_0xca6885(0x22c)]({'type':_0xca6885(0x210),'data':_0x3b7a98});},'update':()=>{const _0x2db121=_0x361aff;if(this[_0x2db121(0x198)])return;this[_0x2db121(0x198)]=!![],this['worker']['postMessage']({'type':'update'});},'clear':()=>{const _0x229384=_0x361aff;this['worker']['postMessage']({'type':_0x229384(0x1f7)});}},this[_0x361aff(0x1ef)]['init'](this['options']);}}mars3d__namespace['LayerUtil']['register']('canvasWind',CanvasWindLayer),mars3d__namespace[_0x327d5f(0x259)][_0x327d5f(0x242)]=CanvasWindLayer,mars3d__namespace['CanvasWindField']=CanvasWindField,mars3d__namespace[_0x327d5f(0x1fd)]=WindUtil,exports['CanvasWindField']=CanvasWindField,exports['CanvasWindLayer']=CanvasWindLayer,exports['WindLayer']=WindLayer,exports[_0x327d5f(0x1fd)]=WindUtil,Object['defineProperty'](exports,'__esModule',{'value':!![]});
15
15
  }));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mars3d-wind",
3
- "version": "3.6.16",
3
+ "version": "3.6.18",
4
4
  "description": "Mars3D平台插件,支持气象 风向图 功能插件",
5
5
  "main": "dist/mars3d-wind.js",
6
6
  "files": [
@@ -8,7 +8,7 @@
8
8
  ],
9
9
  "peerDependencies": {},
10
10
  "devDependencies": {
11
- "mars3d": "~3.6.16"
11
+ "mars3d": "~3.6.18"
12
12
  },
13
13
  "scripts": {
14
14
  "lint": "eslint ./src/**/*.{js,ts} --fix"