@soonspacejs/plugin-effect 2.11.3 → 2.11.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +1 -1
- package/package.json +3 -3
package/dist/index.esm.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{Color as e,Vector4 as t,Vector3 as r,Vector2 as i,MathUtils as n,BufferGeometry as a,BufferAttribute as s,Points as o,PointsMaterial as l,Quaternion as u,Matrix4 as c,Mesh as p,PlaneGeometry as h,MeshBasicMaterial as d,TextureLoader as A,DoubleSide as g,CylinderGeometry as f,BoxGeometry as m,Clock as y,NormalBlending as v,AdditiveBlending as x,DynamicDrawUsage as w,Scene as C,PerspectiveCamera as E,ShaderMaterial as b,LinearFilter as B,ClampToEdgeWrapping as M,UniformsUtils as D,ShaderLib as S}from"three";import I from"soonspacejs";"function"==typeof SuppressedError&&SuppressedError;var O={vertexShader:"\n varying vec3 vViewPosition;\n varying vec3 vWorldPos;\n varying vec3 vNormal;\n\n #include <common>\n #include <uv_pars_vertex>\n #include <displacementmap_pars_vertex>\n #include <envmap_pars_vertex>\n #include <color_pars_vertex>\n #include <morphtarget_pars_vertex>\n #include <skinning_pars_vertex>\n #include <shadowmap_pars_vertex>\n #include <logdepthbuf_pars_vertex>\n #include <clipping_planes_pars_vertex>\n \n void main() {\n\n #include <uv_vertex>\n #include <color_vertex>\n \n //# include <begin_vertex>\n vec3 transformed = vec3( position.x, position.y, position.z );\n //<begin_vertex>\n \n #include <morphtarget_vertex>\n #include <displacementmap_vertex>\n #include <project_vertex>\n #include <logdepthbuf_vertex>\n #include <clipping_planes_vertex>\n\n vViewPosition = - mvPosition.xyz;\n\n #include <worldpos_vertex>\n\n vWorldPos = (modelMatrix * vec4(position, 1.0)).xyz;\n }",fragmentShader:"\n #include <packing>\n #include <logdepthbuf_pars_fragment>\n \n uniform vec3 color;\n uniform float time;\n uniform float seed;\n uniform mat4 invModelMatrix;\n uniform vec3 scale;\n \n uniform vec4 noiseScale;\n uniform float magnitude;\n uniform float lacunarity;\n uniform float gain;\n \n uniform sampler2D fireTex;\n \n varying vec3 vWorldPos;\n \n // GLSL simplex noise function by ashima / https://github.com/ashima/webgl-noise/blob/master/src/noise3D.glsl\n // -------- simplex noise\n vec3 mod289(vec3 x) {\n return x - floor(x * (1.0 / 289.0)) * 289.0;\n }\n \n vec4 mod289(vec4 x) {\n return x - floor(x * (1.0 / 289.0)) * 289.0;\n }\n \n vec4 permute(vec4 x) {\n return mod289(((x * 34.0) + 1.0) * x);\n }\n \n vec4 taylorInvSqrt(vec4 r) {\n return 1.79284291400159 - 0.85373472095314 * r;\n }\n \n float snoise(vec3 v) {\n const vec2 C = vec2(1.0 / 6.0, 1.0 / 3.0);\n const vec4 D = vec4(0.0, 0.5, 1.0, 2.0);\n \n // First corner\n vec3 i = floor(v + dot(v, C.yyy));\n vec3 x0 = v - i + dot(i, C.xxx);\n \n // Other corners\n vec3 g = step(x0.yzx, x0.xyz);\n vec3 l = 1.0 - g;\n vec3 i1 = min(g.xyz, l.zxy);\n vec3 i2 = max(g.xyz, l.zxy);\n \n // x0 = x0 - 0.0 + 0.0 * C.xxx;\n // x1 = x0 - i1 + 1.0 * C.xxx;\n // x2 = x0 - i2 + 2.0 * C.xxx;\n // x3 = x0 - 1.0 + 3.0 * C.xxx;\n vec3 x1 = x0 - i1 + C.xxx;\n vec3 x2 = x0 - i2 + C.yyy; // 2.0*C.x = 1/3 = C.y\n vec3 x3 = x0 - D.yyy; // -1.0+3.0*C.x = -0.5 = -D.y\n \n // Permutations\n i = mod289(i); \n vec4 p = permute(permute(permute( \n i.z + vec4(0.0, i1.z, i2.z, 1.0))\n + i.y + vec4(0.0, i1.y, i2.y, 1.0))\n + i.x + vec4(0.0, i1.x, i2.x, 1.0));\n \n // Gradients: 7x7 points over a square, mapped onto an octahedron.\n // The ring size 17*17 = 289 is close to a multiple of 49 (49*6 = 294)\n float n_ = 0.142857142857; // 1.0/7.0\n vec3 ns = n_ * D.wyz - D.xzx;\n \n vec4 j = p - 49.0 * floor(p * ns.z * ns.z); // mod(p,7*7)\n \n vec4 x_ = floor(j * ns.z);\n vec4 y_ = floor(j - 7.0 * x_); // mod(j,N)\n \n vec4 x = x_ * ns.x + ns.yyyy;\n vec4 y = y_ * ns.x + ns.yyyy;\n vec4 h = 1.0 - abs(x) - abs(y);\n \n vec4 b0 = vec4(x.xy, y.xy);\n vec4 b1 = vec4(x.zw, y.zw);\n \n //vec4 s0 = vec4(lessThan(b0,0.0))*2.0 - 1.0;\n //vec4 s1 = vec4(lessThan(b1,0.0))*2.0 - 1.0;\n vec4 s0 = floor(b0) * 2.0 + 1.0;\n vec4 s1 = floor(b1) * 2.0 + 1.0;\n vec4 sh = -step(h, vec4(0.0));\n \n vec4 a0 = b0.xzyw + s0.xzyw * sh.xxyy;\n vec4 a1 = b1.xzyw + s1.xzyw * sh.zzww;\n \n vec3 p0 = vec3(a0.xy, h.x);\n vec3 p1 = vec3(a0.zw, h.y);\n vec3 p2 = vec3(a1.xy, h.z);\n vec3 p3 = vec3(a1.zw, h.w);\n \n //Normalise gradients\n vec4 norm = taylorInvSqrt(vec4(dot(p0, p0), dot(p1, p1), dot(p2, p2), dot(p3, p3)));\n p0 *= norm.x;\n p1 *= norm.y;\n p2 *= norm.z;\n p3 *= norm.w;\n \n // Mix final noise value\n vec4 m = max(0.6 - vec4(dot(x0, x0), dot(x1, x1), dot(x2, x2), dot(x3, x3)), 0.0);\n m = m * m;\n return 42.0 * dot(m * m, vec4(dot(p0, x0), dot(p1, x1), dot(p2, x2), dot(p3, x3)));\n }\n // simplex noise --------\n \n float turbulence(vec3 p) {\n float sum = 0.0;\n float freq = 1.0;\n float amp = 1.0;\n \n for(int i = 0; i < OCTIVES; i++) {\n sum += abs(snoise(p * freq)) * amp;\n freq *= lacunarity;\n amp *= gain;\n }\n \n return sum;\n }\n \n vec4 samplerFire (vec3 p, vec4 scale) {\n vec2 st = vec2(sqrt(dot(p.xz, p.xz)), p.y);\n \n if(st.x <= 0.0 || st.x >= 1.0 || st.y <= 0.0 || st.y >= 1.0) return vec4(0.0);\n \n p.y -= (seed + time) * scale.w;\n p *= scale.xyz;\n \n st.y += sqrt(st.y) * magnitude * turbulence(p);\n \n if(st.y <= 0.0 || st.y >= 1.0) return vec4(0.0);\n \n return texture2D(fireTex, st);\n }\n \n vec3 localize(vec3 p) {\n return (invModelMatrix * vec4(p, 1.0)).xyz;\n }\n \n void main() {\n #include <logdepthbuf_fragment>\n \n vec3 rayPos = vWorldPos;\n vec3 rayDir = normalize(rayPos - cameraPosition);\n float rayLen = 0.0288 * length(scale.xyz);\n \n vec4 col = vec4(0.0);\n \n for(int i = 0; i < ITERATIONS; i++) {\n rayPos += rayDir * rayLen;\n \n vec3 lp = localize(rayPos);\n \n lp.y += 0.5;\n lp.xz *= 2.0;\n col += samplerFire(lp, noiseScale);\n }\n \n col.a = col.r;\n gl_FragColor.a = 1.0;\n gl_FragColor = col;\n }"},P="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAACACAIAAAA04/g9AAAABGdBTUEAALGOfPtRkwAAACBjSFJNAAB6JQAAgIMAAPn/AACA6AAAdTAAAOpgAAA6lwAAF2+XqZnUAAAel0lEQVR4nGLkYmX4/5/hHyMDw38GBijB8P8fiAUkGP+DRP4yDF4AEEAsTEwgDzAxMPyDuR5EMYIQI5j/Dyz7Hy47yABAADFzszEwMoJYTIwghwL9A3I6I5T8z8jADHY6EwPUG4MNAAQQCzMzKKSZ/4FCGpiQIKH/H8z4+w/kaEawgn9/QVE0CAFAADHzs4PDnomBkQnkUFDQMzJAcgQoHpjAqsARAo4bUIQwDKaoAAggZmFecB74D3Y3I8gzkBTFwAB1MYgHFoGIQ3P5gDgWGwAIIBZmoKNZQA4CJpK//0EFDiM4rQBD+g84X/+H+IeZ4d8/kPeAJMM/aMQMhpwNEEDMkvwMzEyIsGcCOxeYMf6DszXQe//BbmSE62CCpjEIGHAPAAQQs6Qg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nEGUFBME3DcGqof/wFgGspfiXAbWBAFskgNnOIVj+QABAALH8+gtrY8JX0yK1ohnhfT+Y8fCl65DyCjqICQ9+sLo/MMf9hc0Nw2ulf/9Rsul/WL0LDwsG1DxAEAAEEMtf2IIFFiZoK4oRnoT+MyCKAEb0hsh/WDPpP3ytPyOSy1AdB0nfEJ/AWwoMSF0TeIMFudnDyEAYAAQQy09YL/P3f+jxU4zIBjFCAwe+h4IRPhwLCeZ/0PwALQRhWRleiv+FNRDhNdR/2Jri/wwoHkB2PQMR5Q8EAAQQy294wwZyoCtsNyMTpGT4i6jO4BU2JKEzYqwSQcxXMyBCmgE5nyAtHUB2OtxjDEgiRAKAAGL5DaspICSkMciMuoiREWm9CCOsqvoPG55gQCr4/qE5AlZAwRvq8LYW3Bv/MNxLZNhDAECAAQDQyZH7IItOogAAAABJRU5ErkJggg==";const{THREE:T}=I;var R,G,U={distributions:{BOX:1,SPHERE:2,DISC:3,LINE:4},valueOverLifetimeLength:4};U.TypedArrayHelper=function(e,t,r,i){this.componentSize=r||1,this.size=t||1,this.TypedArrayConstructor=e||Float32Array,this.array=new e(t*this.componentSize),this.indexOffset=i||0},U.TypedArrayHelper.constructor=U.TypedArrayHelper,U.TypedArrayHelper.prototype.setSize=function(e,t){var r=this.array.length;return t||(e*=this.componentSize),e<r?this.shrink(e):e>r?this.grow(e):void console.info("TypedArray is already of size:",e+".","Will not resize.")},U.TypedArrayHelper.prototype.shrink=function(e){return this.array=this.array.subarray(0,e),this.size=e,this},U.TypedArrayHelper.prototype.grow=function(e){var t=this.array,r=new this.TypedArrayConstructor(e);return r.set(t),this.array=r,this.size=e,this},U.TypedArrayHelper.prototype.splice=function(e,t){e*=this.componentSize,t*=this.componentSize;for(var r=[],i=this.array,n=i.length,a=0;a<n;++a)(a<e||a>=t)&&r.push(i[a]);return this.setFromArray(0,r),this},U.TypedArrayHelper.prototype.setFromArray=function(e,t){var r=e+t.length;return r>this.array.length?this.grow(r):r<this.array.length&&this.shrink(r),this.array.set(t,this.indexOffset+e),this},U.TypedArrayHelper.prototype.setVec2=function(e,t){return this.setVec2Components(e,t.x,t.y)},U.TypedArrayHelper.prototype.setVec2Components=function(e,t,r){var i=this.array,n=this.indexOffset+e*this.componentSize;return i[n]=t,i[n+1]=r,this},U.TypedArrayHelper.prototype.setVec3=function(e,t){return this.setVec3Components(e,t.x,t.y,t.z)},U.TypedArrayHelper.prototype.setVec3Components=function(e,t,r,i){var n=this.array,a=this.indexOffset+e*this.componentSize;return n[a]=t,n[a+1]=r,n[a+2]=i,this},U.TypedArrayHelper.prototype.setVec4=function(e,t){return this.setVec4Components(e,t.x,t.y,t.z,t.w)},U.TypedArrayHelper.prototype.setVec4Components=function(e,t,r,i,n){var a=this.array,s=this.indexOffset+e*this.componentSize;return a[s]=t,a[s+1]=r,a[s+2]=i,a[s+3]=n,this},U.TypedArrayHelper.prototype.setMat3=function(e,t){return this.setFromArray(this.indexOffset+e*this.componentSize,t.elements)},U.TypedArrayHelper.prototype.setMat4=function(e,t){return this.setFromArray(this.indexOffset+e*this.componentSize,t.elements)},U.TypedArrayHelper.prototype.setColor=function(e,t){return this.setVec3Components(e,t.r,t.g,t.b)},U.TypedArrayHelper.prototype.setNumber=function(e,t){return this.array[this.indexOffset+e*this.componentSize]=t,this},U.TypedArrayHelper.prototype.getValueAtIndex=function(e){return this.array[this.indexOffset+e]},U.TypedArrayHelper.prototype.getComponentValueAtIndex=function(e){return this.array.subarray(this.indexOffset+e*this.componentSize)},U.ShaderAttribute=function(e,t,r){var i=U.ShaderAttribute.typeSizeMap;this.type="string"==typeof e&&i.hasOwnProperty(e)?e:"f",this.componentSize=i[this.type],this.arrayType=r||Float32Array,this.typedArray=null,this.bufferAttribute=null,this.dynamicBuffer=!!t,this.updateMin=0,this.updateMax=0},U.ShaderAttribute.constructor=U.ShaderAttribute,U.ShaderAttribute.typeSizeMap={f:1,v2:2,v3:3,v4:4,c:3,m3:9,m4:16},U.ShaderAttribute.prototype.setUpdateRange=function(e,t){this.updateMin=Math.min(e*this.componentSize,this.updateMin*this.componentSize),this.updateMax=Math.max(t*this.componentSize,this.updateMax*this.componentSize)},U.ShaderAttribute.prototype.flagUpdate=function(){var e=this.bufferAttribute,t=e.updateRange;t.offset=this.updateMin,t.count=Math.min(this.updateMax-this.updateMin+this.componentSize,this.typedArray.array.length),e.needsUpdate=!0},U.ShaderAttribute.prototype.resetUpdateRange=function(){this.updateMin=0,this.updateMax=0},U.ShaderAttribute.prototype.resetDynamic=function(){this.bufferAttribute.usage=this.dynamicBuffer?T.DynamicDrawUsage:T.StaticDrawUsage},U.ShaderAttribute.prototype.splice=function(e,t){this.typedArray.splice(e,t),this.forceUpdateAll()},U.ShaderAttribute.prototype.forceUpdateAll=function(){this.bufferAttribute.array=this.typedArray.array,this.bufferAttribute.updateRange.offset=0,this.bufferAttribute.updateRange.count=-1,this.bufferAttribute.usage=T.StaticDrawUsage,this.bufferAttribute.needsUpdate=!0},U.ShaderAttribute.prototype._ensureTypedArray=function(e){null!==this.typedArray&&this.typedArray.size===e*this.componentSize||(null!==this.typedArray&&this.typedArray.size!==e?this.typedArray.setSize(e):null===this.typedArray&&(this.typedArray=new U.TypedArrayHelper(this.arrayType,e,this.componentSize)))},U.ShaderAttribute.prototype._createBufferAttribute=function(e){if(this._ensureTypedArray(e),null!==this.bufferAttribute)return this.bufferAttribute.array=this.typedArray.array,parseFloat(T.REVISION)>=81&&(this.bufferAttribute.count=this.bufferAttribute.array.length/this.bufferAttribute.itemSize),void(this.bufferAttribute.needsUpdate=!0);this.bufferAttribute=new T.BufferAttribute(this.typedArray.array,this.componentSize),this.bufferAttribute.usage=this.dynamicBuffer?T.DynamicDrawUsage:T.StaticDrawUsage},U.ShaderAttribute.prototype.getLength=function(){return null===this.typedArray?0:this.typedArray.array.length},U.shaderChunks={defines:["#define PACKED_COLOR_SIZE 256.0","#define PACKED_COLOR_DIVISOR 255.0"].join("\n"),uniforms:["uniform float deltaTime;","uniform float runTime;","uniform sampler2D tex;","uniform vec4 textureAnimation;","uniform float scale;"].join("\n"),attributes:["attribute vec4 acceleration;","attribute vec3 velocity;","attribute vec4 rotation;","attribute vec3 rotationCenter;","attribute vec4 params;","attribute vec4 size;","attribute vec4 angle;","attribute vec4 color;","attribute vec4 opacity;"].join("\n"),varyings:["varying vec4 vColor;","#ifdef SHOULD_ROTATE_TEXTURE"," varying float vAngle;","#endif","#ifdef SHOULD_CALCULATE_SPRITE"," varying vec4 vSpriteSheet;","#endif"].join("\n"),branchAvoidanceFunctions:["float when_gt(float x, float y) {"," return max(sign(x - y), 0.0);","}","float when_lt(float x, float y) {"," return min( max(1.0 - sign(x - y), 0.0), 1.0 );","}","float when_eq( float x, float y ) {"," return 1.0 - abs( sign( x - y ) );","}","float when_ge(float x, float y) {"," return 1.0 - when_lt(x, y);","}","float when_le(float x, float y) {"," return 1.0 - when_gt(x, y);","}","float and(float a, float b) {"," return a * b;","}","float or(float a, float b) {"," return min(a + b, 1.0);","}"].join("\n"),unpackColor:["vec3 unpackColor( in float hex ) {"," vec3 c = vec3( 0.0 );"," float r = mod( (hex / PACKED_COLOR_SIZE / PACKED_COLOR_SIZE), PACKED_COLOR_SIZE );"," float g = mod( (hex / PACKED_COLOR_SIZE), PACKED_COLOR_SIZE );"," float b = mod( hex, PACKED_COLOR_SIZE );"," c.r = r / PACKED_COLOR_DIVISOR;"," c.g = g / PACKED_COLOR_DIVISOR;"," c.b = b / PACKED_COLOR_DIVISOR;"," return c;","}"].join("\n"),unpackRotationAxis:["vec3 unpackRotationAxis( in float hex ) {"," vec3 c = vec3( 0.0 );"," float r = mod( (hex / PACKED_COLOR_SIZE / PACKED_COLOR_SIZE), PACKED_COLOR_SIZE );"," float g = mod( (hex / PACKED_COLOR_SIZE), PACKED_COLOR_SIZE );"," float b = mod( hex, PACKED_COLOR_SIZE );"," c.r = r / PACKED_COLOR_DIVISOR;"," c.g = g / PACKED_COLOR_DIVISOR;"," c.b = b / PACKED_COLOR_DIVISOR;"," c *= vec3( 2.0 );"," c -= vec3( 1.0 );"," return c;","}"].join("\n"),floatOverLifetime:["float getFloatOverLifetime( in float positionInTime, in vec4 attr ) {"," highp float value = 0.0;"," float deltaAge = positionInTime * float( VALUE_OVER_LIFETIME_LENGTH - 1 );"," float fIndex = 0.0;"," float shouldApplyValue = 0.0;"," value += attr[ 0 ] * when_eq( deltaAge, 0.0 );",""," for( int i = 0; i < VALUE_OVER_LIFETIME_LENGTH - 1; ++i ) {"," fIndex = float( i );"," shouldApplyValue = and( when_gt( deltaAge, fIndex ), when_le( deltaAge, fIndex + 1.0 ) );"," value += shouldApplyValue * mix( attr[ i ], attr[ i + 1 ], deltaAge - fIndex );"," }",""," return value;","}"].join("\n"),colorOverLifetime:["vec3 getColorOverLifetime( in float positionInTime, in vec3 color1, in vec3 color2, in vec3 color3, in vec3 color4 ) {"," vec3 value = vec3( 0.0 );"," value.x = getFloatOverLifetime( positionInTime, vec4( color1.x, color2.x, color3.x, color4.x ) );"," value.y = getFloatOverLifetime( positionInTime, vec4( color1.y, color2.y, color3.y, color4.y ) );"," value.z = getFloatOverLifetime( positionInTime, vec4( color1.z, color2.z, color3.z, color4.z ) );"," return value;","}"].join("\n"),paramFetchingFunctions:["float getAlive() {"," return params.x;","}","float getAge() {"," return params.y;","}","float getMaxAge() {"," return params.z;","}","float getWiggle() {"," return params.w;","}"].join("\n"),forceFetchingFunctions:["vec4 getPosition( in float age ) {"," return modelViewMatrix * vec4( position, 1.0 );","}","vec3 getVelocity( in float age ) {"," return velocity * age;","}","vec3 getAcceleration( in float age ) {"," return acceleration.xyz * age;","}"].join("\n"),rotationFunctions:["#ifdef SHOULD_ROTATE_PARTICLES"," mat4 getRotationMatrix( in vec3 axis, in float angle) {"," axis = normalize(axis);"," float s = sin(angle);"," float c = cos(angle);"," float oc = 1.0 - c;",""," return mat4(oc * axis.x * axis.x + c, oc * axis.x * axis.y - axis.z * s, oc * axis.z * axis.x + axis.y * s, 0.0,"," oc * axis.x * axis.y + axis.z * s, oc * axis.y * axis.y + c, oc * axis.y * axis.z - axis.x * s, 0.0,"," oc * axis.z * axis.x - axis.y * s, oc * axis.y * axis.z + axis.x * s, oc * axis.z * axis.z + c, 0.0,"," 0.0, 0.0, 0.0, 1.0);"," }",""," vec3 getRotation( in vec3 pos, in float positionInTime ) {"," if( rotation.y == 0.0 ) {"," return pos;"," }",""," vec3 axis = unpackRotationAxis( rotation.x );"," vec3 center = rotationCenter;"," vec3 translated;"," mat4 rotationMatrix;"," float angle = 0.0;"," angle += when_eq( rotation.z, 0.0 ) * rotation.y;"," angle += when_gt( rotation.z, 0.0 ) * mix( 0.0, rotation.y, positionInTime );"," translated = rotationCenter - pos;"," rotationMatrix = getRotationMatrix( axis, angle );"," return center - vec3( rotationMatrix * vec4( translated, 0.0 ) );"," }","#endif"].join("\n"),rotateTexture:[" vec2 vUv = vec2( gl_PointCoord.x, 1.0 - gl_PointCoord.y );",""," #ifdef SHOULD_ROTATE_TEXTURE"," float x = gl_PointCoord.x - 0.5;"," float y = 1.0 - gl_PointCoord.y - 0.5;"," float c = cos( -vAngle );"," float s = sin( -vAngle );"," vUv = vec2( c * x + s * y + 0.5, c * y - s * x + 0.5 );"," #endif",""," #ifdef SHOULD_CALCULATE_SPRITE"," float framesX = vSpriteSheet.x;"," float framesY = vSpriteSheet.y;"," float columnNorm = vSpriteSheet.z;"," float rowNorm = vSpriteSheet.w;"," vUv.x = gl_PointCoord.x * framesX + columnNorm;"," vUv.y = 1.0 - (gl_PointCoord.y * framesY + rowNorm);"," #endif",""," vec4 rotatedTexture = texture2D( tex, vUv );"].join("\n")},U.shaders={vertex:[U.shaderChunks.defines,U.shaderChunks.uniforms,U.shaderChunks.attributes,U.shaderChunks.varyings,T.ShaderChunk.common,T.ShaderChunk.logdepthbuf_pars_vertex,T.ShaderChunk.fog_pars_vertex,U.shaderChunks.branchAvoidanceFunctions,U.shaderChunks.unpackColor,U.shaderChunks.unpackRotationAxis,U.shaderChunks.floatOverLifetime,U.shaderChunks.colorOverLifetime,U.shaderChunks.paramFetchingFunctions,U.shaderChunks.forceFetchingFunctions,U.shaderChunks.rotationFunctions,"void main() {"," highp float age = getAge();"," highp float alive = getAlive();"," highp float maxAge = getMaxAge();"," highp float positionInTime = (age / maxAge);"," highp float isAlive = when_gt( alive, 0.0 );"," #ifdef SHOULD_WIGGLE_PARTICLES"," float wiggleAmount = positionInTime * getWiggle();"," float wiggleSin = isAlive * sin( wiggleAmount );"," float wiggleCos = isAlive * cos( wiggleAmount );"," #endif"," vec3 vel = getVelocity( age );"," vec3 accel = getAcceleration( age );"," vec3 force = vec3( 0.0 );"," vec3 pos = vec3( position );"," float drag = 1.0 - (positionInTime * 0.5) * acceleration.w;"," force += vel;"," force *= drag;"," force += accel * age;"," pos += force;"," #ifdef SHOULD_WIGGLE_PARTICLES"," pos.x += wiggleSin;"," pos.y += wiggleCos;"," pos.z += wiggleSin;"," #endif"," #ifdef SHOULD_ROTATE_PARTICLES"," pos = getRotation( pos, positionInTime );"," #endif"," vec4 mvPosition = modelViewMatrix * vec4( pos, 1.0 );"," highp float pointSize = getFloatOverLifetime( positionInTime, size ) * isAlive;"," #ifdef HAS_PERSPECTIVE"," float perspective = scale / length( mvPosition.xyz );"," #else"," float perspective = 1.0;"," #endif"," float pointSizePerspective = pointSize * perspective;"," #ifdef COLORIZE"," vec3 c = isAlive * getColorOverLifetime("," positionInTime,"," unpackColor( color.x ),"," unpackColor( color.y ),"," unpackColor( color.z ),"," unpackColor( color.w )"," );"," #else"," vec3 c = vec3(1.0);"," #endif"," float o = isAlive * getFloatOverLifetime( positionInTime, opacity );"," vColor = vec4( c, o );"," #ifdef SHOULD_ROTATE_TEXTURE"," vAngle = isAlive * getFloatOverLifetime( positionInTime, angle );"," #endif"," #ifdef SHOULD_CALCULATE_SPRITE"," float framesX = textureAnimation.x;"," float framesY = textureAnimation.y;"," float loopCount = textureAnimation.w;"," float totalFrames = textureAnimation.z;"," float frameNumber = mod( (positionInTime * loopCount) * totalFrames, totalFrames );"," float column = floor(mod( frameNumber, framesX ));"," float row = floor( (frameNumber - column) / framesX );"," float columnNorm = column / framesX;"," float rowNorm = row / framesY;"," vSpriteSheet.x = 1.0 / framesX;"," vSpriteSheet.y = 1.0 / framesY;"," vSpriteSheet.z = columnNorm;"," vSpriteSheet.w = rowNorm;"," #endif"," gl_PointSize = pointSizePerspective;"," gl_Position = projectionMatrix * mvPosition;",T.ShaderChunk.logdepthbuf_vertex,T.ShaderChunk.fog_vertex,"}"].join("\n"),fragment:[U.shaderChunks.uniforms,T.ShaderChunk.common,T.ShaderChunk.fog_pars_fragment,T.ShaderChunk.logdepthbuf_pars_fragment,U.shaderChunks.varyings,U.shaderChunks.branchAvoidanceFunctions,"void main() {"," vec3 outgoingLight = vColor.xyz;"," "," #ifdef ALPHATEST"," if ( vColor.w < float(ALPHATEST) ) discard;"," #endif",U.shaderChunks.rotateTexture,T.ShaderChunk.logdepthbuf_fragment," outgoingLight = vColor.xyz * rotatedTexture.xyz;"," gl_FragColor = vec4( outgoingLight.xyz, rotatedTexture.w * vColor.w );",T.ShaderChunk.fog_fragment,"}"].join("\n")},U.utils={types:{BOOLEAN:"boolean",STRING:"string",NUMBER:"number",OBJECT:"object"},ensureTypedArg:function(e,t,r){return typeof e===t?e:r},ensureArrayTypedArg:function(e,t,r){if(Array.isArray(e)){for(var i=e.length-1;i>=0;--i)if(typeof e[i]!==t)return r;return e}return this.ensureTypedArg(e,t,r)},ensureInstanceOf:function(e,t,r){return void 0!==t&&e instanceof t?e:r},ensureArrayInstanceOf:function(e,t,r){if(Array.isArray(e)){for(var i=e.length-1;i>=0;--i)if(void 0!==t&&e[i]instanceof t==!1)return r;return e}return this.ensureInstanceOf(e,t,r)},ensureValueOverLifetimeCompliance:function(e,t,r){t=t||3,r=r||3,!1===Array.isArray(e._value)&&(e._value=[e._value]),!1===Array.isArray(e._spread)&&(e._spread=[e._spread]);var i=this.clamp(e._value.length,t,r),n=this.clamp(e._spread.length,t,r),a=Math.max(i,n);e._value.length!==a&&(e._value=this.interpolateArray(e._value,a)),e._spread.length!==a&&(e._spread=this.interpolateArray(e._spread,a))},interpolateArray:function(e,t){for(var r=e.length,i=["function"==typeof e[0].clone?e[0].clone():e[0]],n=(r-1)/(t-1),a=1;a<t-1;++a){var s=a*n,o=Math.floor(s),l=Math.ceil(s),u=s-o;i[a]=this.lerpTypeAgnostic(e[o],e[l],u)}return i.push("function"==typeof e[r-1].clone?e[r-1].clone():e[r-1]),i},clamp:function(e,t,r){return Math.max(t,Math.min(e,r))},zeroToEpsilon:function(e,t){var r=1e-5,i=e;return i=t?Math.random()*r*10:r,e<0&&e>-1e-5&&(i=-i),i},lerpTypeAgnostic:function(e,t,r){var i,n=this.types;return typeof e===n.NUMBER&&typeof t===n.NUMBER?e+(t-e)*r:e instanceof T.Vector2&&t instanceof T.Vector2?((i=e.clone()).x=this.lerp(e.x,t.x,r),i.y=this.lerp(e.y,t.y,r),i):e instanceof T.Vector3&&t instanceof T.Vector3?((i=e.clone()).x=this.lerp(e.x,t.x,r),i.y=this.lerp(e.y,t.y,r),i.z=this.lerp(e.z,t.z,r),i):e instanceof T.Vector4&&t instanceof T.Vector4?((i=e.clone()).x=this.lerp(e.x,t.x,r),i.y=this.lerp(e.y,t.y,r),i.z=this.lerp(e.z,t.z,r),i.w=this.lerp(e.w,t.w,r),i):e instanceof T.Color&&t instanceof T.Color?((i=e.clone()).r=this.lerp(e.r,t.r,r),i.g=this.lerp(e.g,t.g,r),i.b=this.lerp(e.b,t.b,r),i):void console.warn("Invalid argument types, or argument types do not match:",e,t)},lerp:function(e,t,r){return e+(t-e)*r},roundToNearestMultiple:function(e,t){var r;return 0===t||0===(r=Math.abs(e)%t)?e:e<0?-(Math.abs(e)-r):e+t-r},arrayValuesAreEqual:function(e){for(var t=0;t<e.length-1;++t)if(e[t]!==e[t+1])return!1;return!0},randomFloat:function(e,t){return e+t*(Math.random()-.5)},randomVector3:function(e,t,r,i,n){var a=r.x+(Math.random()*i.x-.5*i.x),s=r.y+(Math.random()*i.y-.5*i.y),o=r.z+(Math.random()*i.z-.5*i.z);n&&(a=.5*-n.x+this.roundToNearestMultiple(a,n.x),s=.5*-n.y+this.roundToNearestMultiple(s,n.y),o=.5*-n.z+this.roundToNearestMultiple(o,n.z)),e.typedArray.setVec3Components(t,a,s,o)},randomColor:function(e,t,r,i){var n=r.r+Math.random()*i.x,a=r.g+Math.random()*i.y,s=r.b+Math.random()*i.z;n=this.clamp(n,0,1),a=this.clamp(a,0,1),s=this.clamp(s,0,1),e.typedArray.setVec3Components(t,n,a,s)},randomColorAsHex:(G=new T.Color,function(e,t,r,i){for(var n=r.length,a=[],s=0;s<n;++s){var o=i[s];G.copy(r[s]),G.r+=Math.random()*o.x-.5*o.x,G.g+=Math.random()*o.y-.5*o.y,G.b+=Math.random()*o.z-.5*o.z,G.r=this.clamp(G.r,0,1),G.g=this.clamp(G.g,0,1),G.b=this.clamp(G.b,0,1),a.push(G.getHex())}e.typedArray.setVec4Components(t,a[0],a[1],a[2],a[3])}),randomVector3OnLine:function(e,t,r,i){var n=r.clone();n.lerp(i,Math.random()),e.typedArray.setVec3Components(t,n.x,n.y,n.z)},randomVector3OnSphere:function(e,t,r,i,n,a,s,o){var l=2*Math.random()-1,u=6.2832*Math.random(),c=Math.sqrt(1-l*l),p=this.randomFloat(i,n),h=0,d=0,A=0;s&&(p=Math.round(p/s)*s),h=c*Math.cos(u)*p,d=c*Math.sin(u)*p,A=l*p,h*=a.x,d*=a.y,A*=a.z,h+=r.x,d+=r.y,A+=r.z,e.typedArray.setVec3Components(t,h,d,A)},seededRandom:function(e){var t=1e4*Math.sin(e);return t-(0|t)},randomVector3OnDisc:function(e,t,r,i,n,a,s){var o=6.2832*Math.random(),l=Math.abs(this.randomFloat(i,n)),u=0,c=0,p=0;s&&(l=Math.round(l/s)*s),u=Math.cos(o)*l,c=Math.sin(o)*l,u*=a.x,c*=a.y,u+=r.x,c+=r.y,p+=r.z,e.typedArray.setVec3Components(t,u,c,p)},randomDirectionVector3OnSphere:(R=new T.Vector3,function(e,t,r,i,n,a,s,o){R.copy(a),R.x-=r,R.y-=i,R.z-=n,R.normalize().multiplyScalar(-this.randomFloat(s,o)),e.typedArray.setVec3Components(t,R.x,R.y,R.z)}),randomDirectionVector3OnDisc:function(){var e=new T.Vector3;return function(t,r,i,n,a,s,o,l){e.copy(s),e.x-=i,e.y-=n,e.z-=a,e.normalize().multiplyScalar(-this.randomFloat(o,l)),t.typedArray.setVec3Components(r,e.x,e.y,0)}}(),getPackedRotationAxis:function(){var e=new T.Vector3,t=new T.Vector3,r=new T.Color,i=new T.Vector3(1,1,1);return function(n,a){return e.copy(n).normalize(),t.copy(a).normalize(),e.x+=.5*-a.x+Math.random()*a.x,e.y+=.5*-a.y+Math.random()*a.y,e.z+=.5*-a.z+Math.random()*a.z,e.normalize().add(i).multiplyScalar(.5),r.setRGB(e.x,e.y,e.z),r.getHex()}}()},U.Group=function(e){var t=U.utils,r=t.types;(e=t.ensureTypedArg(e,r.OBJECT,{})).texture=t.ensureTypedArg(e.texture,r.OBJECT,{}),this.uuid=T.MathUtils.generateUUID(),this.fixedTimeStep=t.ensureTypedArg(e.fixedTimeStep,r.NUMBER,.016),this.texture=t.ensureInstanceOf(e.texture.value,T.Texture,null),this.textureFrames=t.ensureInstanceOf(e.texture.frames,T.Vector2,new T.Vector2(1,1)),this.textureFrameCount=t.ensureTypedArg(e.texture.frameCount,r.NUMBER,this.textureFrames.x*this.textureFrames.y),this.textureLoop=t.ensureTypedArg(e.texture.loop,r.NUMBER,1),this.textureFrames.max(new T.Vector2(1,1)),this.hasPerspective=t.ensureTypedArg(e.hasPerspective,r.BOOLEAN,!0),this.colorize=t.ensureTypedArg(e.colorize,r.BOOLEAN,!0),this.maxParticleCount=t.ensureTypedArg(e.maxParticleCount,r.NUMBER,null),this.blending=t.ensureTypedArg(e.blending,r.NUMBER,T.AdditiveBlending),this.transparent=t.ensureTypedArg(e.transparent,r.BOOLEAN,!0),this.alphaTest=parseFloat(t.ensureTypedArg(e.alphaTest,r.NUMBER,0)),this.depthWrite=t.ensureTypedArg(e.depthWrite,r.BOOLEAN,!1),this.depthTest=t.ensureTypedArg(e.depthTest,r.BOOLEAN,!0),this.fog=t.ensureTypedArg(e.fog,r.BOOLEAN,!0),this.scale=t.ensureTypedArg(e.scale,r.NUMBER,300),this.emitters=[],this.emitterIDs=[],this._pool=[],this._poolCreationSettings=null,this._createNewWhenPoolEmpty=0,this._attributesNeedRefresh=!1,this._attributesNeedDynamicReset=!1,this.particleCount=0,this.uniforms={tex:{type:"t",value:this.texture},textureAnimation:{type:"v4",value:new T.Vector4(this.textureFrames.x,this.textureFrames.y,this.textureFrameCount,Math.max(Math.abs(this.textureLoop),1))},fogColor:{type:"c",value:this.fog?new T.Color:null},fogNear:{type:"f",value:10},fogFar:{type:"f",value:200},fogDensity:{type:"f",value:.5},deltaTime:{type:"f",value:0},runTime:{type:"f",value:0},scale:{type:"f",value:this.scale}},this.defines={HAS_PERSPECTIVE:this.hasPerspective,COLORIZE:this.colorize,VALUE_OVER_LIFETIME_LENGTH:U.valueOverLifetimeLength,SHOULD_ROTATE_TEXTURE:!1,SHOULD_ROTATE_PARTICLES:!1,SHOULD_WIGGLE_PARTICLES:!1,SHOULD_CALCULATE_SPRITE:this.textureFrames.x>1||this.textureFrames.y>1},this.attributes={position:new U.ShaderAttribute("v3",!0),acceleration:new U.ShaderAttribute("v4",!0),velocity:new U.ShaderAttribute("v3",!0),rotation:new U.ShaderAttribute("v4",!0),rotationCenter:new U.ShaderAttribute("v3",!0),params:new U.ShaderAttribute("v4",!0),size:new U.ShaderAttribute("v4",!0),angle:new U.ShaderAttribute("v4",!0),color:new U.ShaderAttribute("v4",!0),opacity:new U.ShaderAttribute("v4",!0)},this.attributeKeys=Object.keys(this.attributes),this.attributeCount=this.attributeKeys.length,this.material=new T.ShaderMaterial({uniforms:this.uniforms,vertexShader:U.shaders.vertex,fragmentShader:U.shaders.fragment,blending:this.blending,transparent:this.transparent,alphaTest:this.alphaTest,depthWrite:this.depthWrite,depthTest:this.depthTest,defines:this.defines,fog:this.fog}),this.geometry=new T.BufferGeometry,this.mesh=new T.Points(this.geometry,this.material),null===this.maxParticleCount&&console.warn("SPE.Group: No maxParticleCount specified. Adding emitters after rendering will probably cause errors.")},U.Group.constructor=U.Group,U.Group.prototype._updateDefines=function(){for(var e,t=this.emitters,r=t.length-1,i=this.defines;r>=0;--r)e=t[r],i.SHOULD_CALCULATE_SPRITE||(i.SHOULD_ROTATE_TEXTURE=i.SHOULD_ROTATE_TEXTURE||!!Math.max(Math.max.apply(null,e.angle.value),Math.max.apply(null,e.angle.spread))),i.SHOULD_ROTATE_PARTICLES=i.SHOULD_ROTATE_PARTICLES||!!Math.max(e.rotation.angle,e.rotation.angleSpread),i.SHOULD_WIGGLE_PARTICLES=i.SHOULD_WIGGLE_PARTICLES||!!Math.max(e.wiggle.value,e.wiggle.spread);this.material.needsUpdate=!0},U.Group.prototype._applyAttributesToGeometry=function(){var e,t,r=this.attributes,i=this.geometry,n=i.attributes;for(var a in r)r.hasOwnProperty(a)&&(e=r[a],(t=n[a])?t.array=e.typedArray.array:i.setAttribute(a,e.bufferAttribute),e.bufferAttribute.needsUpdate=!0);this.geometry.setDrawRange(0,this.particleCount)},U.Group.prototype.addEmitter=function(e){if(e instanceof U.Emitter!=!1)if(this.emitterIDs.indexOf(e.uuid)>-1)console.error("Emitter already exists in this group. Will not add again.");else{if(null===e.group){var t=this.attributes,r=this.particleCount,i=r+e.particleCount;for(var n in this.particleCount=i,null!==this.maxParticleCount&&this.particleCount>this.maxParticleCount&&console.warn("SPE.Group: maxParticleCount exceeded. Requesting",this.particleCount,"particles, can support only",this.maxParticleCount),e._calculatePPSValue(e.maxAge._value+e.maxAge._spread),e._setBufferUpdateRanges(this.attributeKeys),e._setAttributeOffset(r),e.group=this,e.attributes=this.attributes,t)t.hasOwnProperty(n)&&t[n]._createBufferAttribute(null!==this.maxParticleCount?this.maxParticleCount:this.particleCount);for(var a=r;a<i;++a)e._assignPositionValue(a),e._assignForceValue(a,"velocity"),e._assignForceValue(a,"acceleration"),e._assignAbsLifetimeValue(a,"opacity"),e._assignAbsLifetimeValue(a,"size"),e._assignAngleValue(a),e._assignRotationValue(a),e._assignParamsValue(a),e._assignColorValue(a);return this._applyAttributesToGeometry(),this.emitters.push(e),this.emitterIDs.push(e.uuid),this._updateDefines(e),this.material.needsUpdate=!0,this.geometry.needsUpdate=!0,this._attributesNeedRefresh=!0,this}console.error("Emitter already belongs to another group. Will not add to requested group.")}else console.error("`emitter` argument must be instance of SPE.Emitter. Was provided with:",e)},U.Group.prototype.removeEmitter=function(e){var t=this.emitterIDs.indexOf(e.uuid);if(e instanceof U.Emitter!=!1)if(-1!==t){for(var r=e.attributeOffset,i=r+e.particleCount,n=this.attributes.params.typedArray,a=r;a<i;++a)n.array[4*a]=0,n.array[4*a+1]=0;for(var s in this.emitters.splice(t,1),this.emitterIDs.splice(t,1),this.attributes)this.attributes.hasOwnProperty(s)&&this.attributes[s].splice(r,i);this.particleCount-=e.particleCount,e._onRemove(),this._attributesNeedRefresh=!0}else console.error("Emitter does not exist in this group. Will not remove.");else console.error("`emitter` argument must be instance of SPE.Emitter. Was provided with:",e)},U.Group.prototype.getFromPool=function(){var e=this._pool,t=this._createNewWhenPoolEmpty;if(e.length)return e.pop();if(t){var r=new U.Emitter(this._poolCreationSettings);return this.addEmitter(r),r}return null},U.Group.prototype.releaseIntoPool=function(e){if(e instanceof U.Emitter!=!1)return e.reset(),this._pool.unshift(e),this;console.error("Argument is not instanceof SPE.Emitter:",e)},U.Group.prototype.getPool=function(){return this._pool},U.Group.prototype.addPool=function(e,t,r){var i;this._poolCreationSettings=t,this._createNewWhenPoolEmpty=!!r;for(var n=0;n<e;++n)i=Array.isArray(t)?new U.Emitter(t[n]):new U.Emitter(t),this.addEmitter(i),this.releaseIntoPool(i);return this},U.Group.prototype._triggerSingleEmitter=function(e){var t=this.getFromPool(),r=this;if(null!==t)return e instanceof T.Vector3&&(t.position.value.copy(e),t.position.value=t.position.value),t.enable(),setTimeout((function(){t.disable(),r.releaseIntoPool(t)}),1e3*Math.max(t.duration,t.maxAge.value+t.maxAge.spread)),this;console.log("SPE.Group pool ran out.")},U.Group.prototype.triggerPoolEmitter=function(e,t){if("number"==typeof e&&e>1)for(var r=0;r<e;++r)this._triggerSingleEmitter(t);else this._triggerSingleEmitter(t);return this},U.Group.prototype._updateUniforms=function(e){this.uniforms.runTime.value+=e,this.uniforms.deltaTime.value=e},U.Group.prototype._resetBufferRanges=function(){for(var e=this.attributeKeys,t=this.attributeCount-1,r=this.attributes;t>=0;--t)r[e[t]].resetUpdateRange()},U.Group.prototype._updateBuffers=function(e){for(var t,r,i,n=this.attributeKeys,a=this.attributeCount-1,s=this.attributes,o=e.bufferUpdateRanges;a>=0;--a)r=o[t=n[a]],(i=s[t]).setUpdateRange(r.min,r.max),i.flagUpdate()},U.Group.prototype.tick=function(e){var t=this.emitters,r=t.length,i=e||this.fixedTimeStep,n=this.attributeKeys,a=this.attributes;if(this._updateUniforms(i),this._resetBufferRanges(),0!==r||!1!==this._attributesNeedRefresh||!1!==this._attributesNeedDynamicReset){for(var s,o=0;o<r;++o)(s=t[o]).tick(i),this._updateBuffers(s);if(!0===this._attributesNeedDynamicReset){for(o=this.attributeCount-1;o>=0;--o)a[n[o]].resetDynamic();this._attributesNeedDynamicReset=!1}if(!0===this._attributesNeedRefresh){for(o=this.attributeCount-1;o>=0;--o)a[n[o]].forceUpdateAll();this._attributesNeedRefresh=!1,this._attributesNeedDynamicReset=!0}}},U.Group.prototype.dispose=function(){return this.geometry.dispose(),this.material.dispose(),this},U.Emitter=function(e){var t=U.utils,r=t.types,i=U.valueOverLifetimeLength;for(var n in(e=t.ensureTypedArg(e,r.OBJECT,{})).position=t.ensureTypedArg(e.position,r.OBJECT,{}),e.velocity=t.ensureTypedArg(e.velocity,r.OBJECT,{}),e.acceleration=t.ensureTypedArg(e.acceleration,r.OBJECT,{}),e.radius=t.ensureTypedArg(e.radius,r.OBJECT,{}),e.drag=t.ensureTypedArg(e.drag,r.OBJECT,{}),e.rotation=t.ensureTypedArg(e.rotation,r.OBJECT,{}),e.color=t.ensureTypedArg(e.color,r.OBJECT,{}),e.opacity=t.ensureTypedArg(e.opacity,r.OBJECT,{}),e.size=t.ensureTypedArg(e.size,r.OBJECT,{}),e.angle=t.ensureTypedArg(e.angle,r.OBJECT,{}),e.wiggle=t.ensureTypedArg(e.wiggle,r.OBJECT,{}),e.maxAge=t.ensureTypedArg(e.maxAge,r.OBJECT,{}),e.onParticleSpawn&&console.warn("onParticleSpawn has been removed. Please set properties directly to alter values at runtime."),this.uuid=T.MathUtils.generateUUID(),this.type=t.ensureTypedArg(e.type,r.NUMBER,U.distributions.BOX),this.position={_value:t.ensureInstanceOf(e.position.value,T.Vector3,new T.Vector3),_spread:t.ensureInstanceOf(e.position.spread,T.Vector3,new T.Vector3),_spreadClamp:t.ensureInstanceOf(e.position.spreadClamp,T.Vector3,new T.Vector3),_distribution:t.ensureTypedArg(e.position.distribution,r.NUMBER,this.type),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1),_radius:t.ensureTypedArg(e.position.radius,r.NUMBER,10),_radiusScale:t.ensureInstanceOf(e.position.radiusScale,T.Vector3,new T.Vector3(1,1,1)),_distributionClamp:t.ensureTypedArg(e.position.distributionClamp,r.NUMBER,0)},this.velocity={_value:t.ensureInstanceOf(e.velocity.value,T.Vector3,new T.Vector3),_spread:t.ensureInstanceOf(e.velocity.spread,T.Vector3,new T.Vector3),_distribution:t.ensureTypedArg(e.velocity.distribution,r.NUMBER,this.type),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.acceleration={_value:t.ensureInstanceOf(e.acceleration.value,T.Vector3,new T.Vector3),_spread:t.ensureInstanceOf(e.acceleration.spread,T.Vector3,new T.Vector3),_distribution:t.ensureTypedArg(e.acceleration.distribution,r.NUMBER,this.type),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.drag={_value:t.ensureTypedArg(e.drag.value,r.NUMBER,0),_spread:t.ensureTypedArg(e.drag.spread,r.NUMBER,0),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.wiggle={_value:t.ensureTypedArg(e.wiggle.value,r.NUMBER,0),_spread:t.ensureTypedArg(e.wiggle.spread,r.NUMBER,0)},this.rotation={_axis:t.ensureInstanceOf(e.rotation.axis,T.Vector3,new T.Vector3(0,1,0)),_axisSpread:t.ensureInstanceOf(e.rotation.axisSpread,T.Vector3,new T.Vector3),_angle:t.ensureTypedArg(e.rotation.angle,r.NUMBER,0),_angleSpread:t.ensureTypedArg(e.rotation.angleSpread,r.NUMBER,0),_static:t.ensureTypedArg(e.rotation.static,r.BOOLEAN,!1),_center:t.ensureInstanceOf(e.rotation.center,T.Vector3,this.position._value.clone()),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.maxAge={_value:t.ensureTypedArg(e.maxAge.value,r.NUMBER,2),_spread:t.ensureTypedArg(e.maxAge.spread,r.NUMBER,0)},this.color={_value:t.ensureArrayInstanceOf(e.color.value,T.Color,new T.Color),_spread:t.ensureArrayInstanceOf(e.color.spread,T.Vector3,new T.Vector3),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.opacity={_value:t.ensureArrayTypedArg(e.opacity.value,r.NUMBER,1),_spread:t.ensureArrayTypedArg(e.opacity.spread,r.NUMBER,0),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.size={_value:t.ensureArrayTypedArg(e.size.value,r.NUMBER,1),_spread:t.ensureArrayTypedArg(e.size.spread,r.NUMBER,0),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.angle={_value:t.ensureArrayTypedArg(e.angle.value,r.NUMBER,0),_spread:t.ensureArrayTypedArg(e.angle.spread,r.NUMBER,0),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.particleCount=t.ensureTypedArg(e.particleCount,r.NUMBER,100),this.duration=t.ensureTypedArg(e.duration,r.NUMBER,null),this.isStatic=t.ensureTypedArg(e.isStatic,r.BOOLEAN,!1),this.activeMultiplier=t.ensureTypedArg(e.activeMultiplier,r.NUMBER,1),this.direction=t.ensureTypedArg(e.direction,r.NUMBER,1),this.alive=t.ensureTypedArg(e.alive,r.BOOLEAN,!0),this.particlesPerSecond=0,this.activationIndex=0,this.attributeOffset=0,this.attributeEnd=0,this.age=0,this.activeParticleCount=0,this.group=null,this.attributes=null,this.paramsArray=null,this.resetFlags={position:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)||t.ensureTypedArg(e.radius.randomise,r.BOOLEAN,!1),velocity:t.ensureTypedArg(e.velocity.randomise,r.BOOLEAN,!1),acceleration:t.ensureTypedArg(e.acceleration.randomise,r.BOOLEAN,!1)||t.ensureTypedArg(e.drag.randomise,r.BOOLEAN,!1),rotation:t.ensureTypedArg(e.rotation.randomise,r.BOOLEAN,!1),rotationCenter:t.ensureTypedArg(e.rotation.randomise,r.BOOLEAN,!1),size:t.ensureTypedArg(e.size.randomise,r.BOOLEAN,!1),color:t.ensureTypedArg(e.color.randomise,r.BOOLEAN,!1),opacity:t.ensureTypedArg(e.opacity.randomise,r.BOOLEAN,!1),angle:t.ensureTypedArg(e.angle.randomise,r.BOOLEAN,!1)},this.updateFlags={},this.updateCounts={},this.updateMap={maxAge:"params",position:"position",velocity:"velocity",acceleration:"acceleration",drag:"acceleration",wiggle:"params",rotation:"rotation",size:"size",color:"color",opacity:"opacity",angle:"angle"},this.updateMap)this.updateMap.hasOwnProperty(n)&&(this.updateCounts[this.updateMap[n]]=0,this.updateFlags[this.updateMap[n]]=!1,this._createGetterSetters(this[n],n));this.bufferUpdateRanges={},this.attributeKeys=null,this.attributeCount=0,t.ensureValueOverLifetimeCompliance(this.color,i,i),t.ensureValueOverLifetimeCompliance(this.opacity,i,i),t.ensureValueOverLifetimeCompliance(this.size,i,i),t.ensureValueOverLifetimeCompliance(this.angle,i,i)},U.Emitter.constructor=U.Emitter,U.Emitter.prototype._createGetterSetters=function(e,t){var r=this;for(var i in e)if(e.hasOwnProperty(i)){var n=i.replace("_","");Object.defineProperty(e,n,{get:function(e){return function(){return this[e]}}(i),set:function(e){return function(i){var n=r.updateMap[t],a=this[e],s=U.valueOverLifetimeLength;"_rotationCenter"===e?(r.updateFlags.rotationCenter=!0,r.updateCounts.rotationCenter=0):"_randomise"===e?r.resetFlags[n]=i:(r.updateFlags[n]=!0,r.updateCounts[n]=0),r.group._updateDefines(),this[e]=i,Array.isArray(a)&&U.utils.ensureValueOverLifetimeCompliance(r[t],s,s)}}(i)})}},U.Emitter.prototype._setBufferUpdateRanges=function(e){this.attributeKeys=e,this.attributeCount=e.length;for(var t=this.attributeCount-1;t>=0;--t)this.bufferUpdateRanges[e[t]]={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY}},U.Emitter.prototype._calculatePPSValue=function(e){var t=this.particleCount;this.duration?this.particlesPerSecond=t/(e<this.duration?e:this.duration):this.particlesPerSecond=t/e},U.Emitter.prototype._setAttributeOffset=function(e){this.attributeOffset=e,this.activationIndex=e,this.activationEnd=e+this.particleCount},U.Emitter.prototype._assignValue=function(e,t){switch(e){case"position":this._assignPositionValue(t);break;case"velocity":case"acceleration":this._assignForceValue(t,e);break;case"size":case"opacity":this._assignAbsLifetimeValue(t,e);break;case"angle":this._assignAngleValue(t);break;case"params":this._assignParamsValue(t);break;case"rotation":this._assignRotationValue(t);break;case"color":this._assignColorValue(t)}},U.Emitter.prototype._assignPositionValue=function(e){var t=U.distributions,r=U.utils,i=this.position,n=this.attributes.position,a=i._value,s=i._spread;switch(i._distribution){case t.BOX:r.randomVector3(n,e,a,s,i._spreadClamp);break;case t.SPHERE:r.randomVector3OnSphere(n,e,a,i._radius,i._spread.x,i._radiusScale,i._spreadClamp.x,i._distributionClamp||this.particleCount);break;case t.DISC:r.randomVector3OnDisc(n,e,a,i._radius,i._spread.x,i._radiusScale,i._spreadClamp.x);break;case t.LINE:r.randomVector3OnLine(n,e,a,s)}},U.Emitter.prototype._assignForceValue=function(e,t){var r,i,n,a,s,o=U.distributions,l=U.utils,u=this[t],c=u._value,p=u._spread;switch(u._distribution){case o.BOX:l.randomVector3(this.attributes[t],e,c,p);break;case o.SPHERE:i=(r=this.attributes.position.typedArray.array)[s=3*e],n=r[s+1],a=r[s+2],l.randomDirectionVector3OnSphere(this.attributes[t],e,i,n,a,this.position._value,u._value.x,u._spread.x);break;case o.DISC:i=(r=this.attributes.position.typedArray.array)[s=3*e],n=r[s+1],a=r[s+2],l.randomDirectionVector3OnDisc(this.attributes[t],e,i,n,a,this.position._value,u._value.x,u._spread.x);break;case o.LINE:l.randomVector3OnLine(this.attributes[t],e,c,p)}if("acceleration"===t){var h=l.clamp(l.randomFloat(this.drag._value,this.drag._spread),0,1);this.attributes.acceleration.typedArray.array[4*e+3]=h}},U.Emitter.prototype._assignAbsLifetimeValue=function(e,t){var r,i=this.attributes[t].typedArray,n=this[t],a=U.utils;a.arrayValuesAreEqual(n._value)&&a.arrayValuesAreEqual(n._spread)?(r=Math.abs(a.randomFloat(n._value[0],n._spread[0])),i.setVec4Components(e,r,r,r,r)):i.setVec4Components(e,Math.abs(a.randomFloat(n._value[0],n._spread[0])),Math.abs(a.randomFloat(n._value[1],n._spread[1])),Math.abs(a.randomFloat(n._value[2],n._spread[2])),Math.abs(a.randomFloat(n._value[3],n._spread[3])))},U.Emitter.prototype._assignAngleValue=function(e){var t,r=this.attributes.angle.typedArray,i=this.angle,n=U.utils;n.arrayValuesAreEqual(i._value)&&n.arrayValuesAreEqual(i._spread)?(t=n.randomFloat(i._value[0],i._spread[0]),r.setVec4Components(e,t,t,t,t)):r.setVec4Components(e,n.randomFloat(i._value[0],i._spread[0]),n.randomFloat(i._value[1],i._spread[1]),n.randomFloat(i._value[2],i._spread[2]),n.randomFloat(i._value[3],i._spread[3]))},U.Emitter.prototype._assignParamsValue=function(e){this.attributes.params.typedArray.setVec4Components(e,this.isStatic?1:0,0,Math.abs(U.utils.randomFloat(this.maxAge._value,this.maxAge._spread)),U.utils.randomFloat(this.wiggle._value,this.wiggle._spread))},U.Emitter.prototype._assignRotationValue=function(e){this.attributes.rotation.typedArray.setVec3Components(e,U.utils.getPackedRotationAxis(this.rotation._axis,this.rotation._axisSpread),U.utils.randomFloat(this.rotation._angle,this.rotation._angleSpread),this.rotation._static?0:1),this.attributes.rotationCenter.typedArray.setVec3(e,this.rotation._center)},U.Emitter.prototype._assignColorValue=function(e){U.utils.randomColorAsHex(this.attributes.color,e,this.color._value,this.color._spread)},U.Emitter.prototype._resetParticle=function(e){for(var t,r,i=this.resetFlags,n=this.updateFlags,a=this.updateCounts,s=this.attributeKeys,o=this.attributeCount-1;o>=0;--o)r=n[t=s[o]],!0!==i[t]&&!0!==r||(this._assignValue(t,e),this._updateAttributeUpdateRange(t,e),!0===r&&a[t]===this.particleCount?(n[t]=!1,a[t]=0):1==r&&++a[t])},U.Emitter.prototype._updateAttributeUpdateRange=function(e,t){var r=this.bufferUpdateRanges[e];r.min=Math.min(t,r.min),r.max=Math.max(t,r.max)},U.Emitter.prototype._resetBufferRanges=function(){for(var e,t=this.bufferUpdateRanges,r=this.bufferUpdateKeys,i=this.bufferUpdateCount-1;i>=0;--i)t[e=r[i]].min=Number.POSITIVE_INFINITY,t[e].max=Number.NEGATIVE_INFINITY},U.Emitter.prototype._onRemove=function(){this.particlesPerSecond=0,this.attributeOffset=0,this.activationIndex=0,this.activeParticleCount=0,this.group=null,this.attributes=null,this.paramsArray=null,this.age=0},U.Emitter.prototype._decrementParticleCount=function(){--this.activeParticleCount},U.Emitter.prototype._incrementParticleCount=function(){++this.activeParticleCount},U.Emitter.prototype._checkParticleAges=function(e,t,r,i){for(var n,a,s,o,l=t-1;l>=e;--l)0!==(o=r[n=4*l])&&(s=r[n+1],a=r[n+2],1===this.direction?(s+=i)>=a&&(s=0,o=0,this._decrementParticleCount()):(s-=i)<=0&&(s=a,o=0,this._decrementParticleCount()),r[n]=o,r[n+1]=s,this._updateAttributeUpdateRange("params",l))},U.Emitter.prototype._activateParticles=function(e,t,r,i){for(var n,a,s=this.direction,o=e;o<t;++o)0!=r[n=4*o]&&1!==this.particleCount||(this._incrementParticleCount(),r[n]=1,this._resetParticle(o),a=i*(o-e),r[n+1]=-1===s?r[n+2]-a:a,this._updateAttributeUpdateRange("params",o))},U.Emitter.prototype.tick=function(e){if(!this.isStatic){null===this.paramsArray&&(this.paramsArray=this.attributes.params.typedArray.array);var t=this.attributeOffset,r=t+this.particleCount,i=this.paramsArray,n=this.particlesPerSecond*this.activeMultiplier*e,a=this.activationIndex;if(this._resetBufferRanges(),this._checkParticleAges(t,r,i,e),!1!==this.alive){if(null!==this.duration&&this.age>this.duration)return this.alive=!1,void(this.age=0);var s=1===this.particleCount?a:0|a,o=Math.min(s+n,this.activationEnd),l=o-this.activationIndex|0,u=l>0?e/l:0;this._activateParticles(s,o,i,u),this.activationIndex+=n,this.activationIndex>r&&(this.activationIndex=t),this.age+=e}else this.age=0}},U.Emitter.prototype.reset=function(e){if(this.age=0,this.alive=!1,!0===e){for(var t,r=this.attributeOffset,i=r+this.particleCount,n=this.paramsArray,a=this.attributes.params.bufferAttribute,s=i-1;s>=r;--s)n[t=4*s]=0,n[t+1]=0;a.updateRange.offset=0,a.updateRange.count=-1,a.needsUpdate=!0}return this},U.Emitter.prototype.enable=function(){return this.alive=!0,this},U.Emitter.prototype.disable=function(){return this.alive=!1,this},U.Emitter.prototype.remove=function(){return null!==this.group?this.group.removeEmitter(this):console.error("Emitter does not belong to a group, cannot remove."),this};var L="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAACACAQAAABpN6lAAAAAAmJLR0QA/4ePzL8AAAAJcEhZcwAACxIAAAsSAdLdfvwAAAAHdElNRQfWCgcGExyutxTlAAAgAElEQVR42kS865LbPLIEmJlVIKX2nPO8+9p75nOLBFCV+4OaWTvc0RFWhEgAdcsL+P/ghX+DWDhwIhEQnj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faa+Wg7l4EOIPcr92yH5L2v/k5wWw5XkueJsfIl9m0fGOg4bL4wMNHdISaGib5SvFgmyGWwPAEX6cYbtw/KgDhtvFa8znbuEcEb3blvgxsvfHzskKQH61Sf+OO5RM04nAA+6wg2YMjrRrcL2gGK4cAbBawYv52pvTrB11roYe2EAieI/gfajro1Jbt3CvDYuW03VgpNum/MRqCtCDMcNmK/CMtdmtv6NvCxaJTJCbuDTCxoVMPkhc8+uoRA+MSzo5U3+xnNv37PhsMHBmzgRrnhQeL0tdJwfe9QXUO/wFTcu85YFmnhQtuq9ZU3BTScCHgBFJ6dy3NhoO/P6Gs7Kq4dVdLxoNwIFG4Yp4HJRHPhwYu3B27KwoUbgpB+8R+8fQBM/LgtBAIShwcC97ZRr6CDQGwzLdBM1B5gT2g/+CuKN7CMLwMTb693uqOhoTlgaP/b4C+vEBeEbxw7ZM+bm7RS5/pie0zcO4rQW+W9WuRjPwkPnj0xmigueVvDY2JwTdkGinYicHPNX8GPY98U2J7vdP1Llmi4cewZA9H9m3UuNOM3G9bCAeCzFxqHF+Ngwl4B0dcq5L2fJRDnFmofi5a9/MY77v3EuQ/6vn/Vvfal8Hv8tV0NHLtgOHaCs7bLt2P43B+CUKAnjkWfcqGD1N6/NwQCP3gDWHAWY+D0A+EAeCxWgVdZKgSwNSPw3HnBhw3iQSJc+xFeT4bw7K9bXk/pShh7Y9ljYi9yv6CN66ndzNUahKBWSOP/38cdYbx39uCOSl8yRmhX0b+HYux/m9rR1ssTOLgQiQ389ykxErlDXMau/ASy7ZDPhUiQX5tdoF2pj7XxXMWLC8a9otO9rL7GQnLKC7d77CPNi7+3vOwAzl87Nk40vNEw0fc86IJB/C/hOTWY8yY1MAAAAABJRU5ErkJggg==",Q={vertexShader:"\n #include <common>\n #include <logdepthbuf_pars_vertex>\n uniform float pixelRatio;\n uniform float time;\n attribute float size; \n attribute float speed; \n attribute float opacity;\n attribute vec3 noise;\n attribute vec3 color;\n varying vec3 vColor;\n varying float vOpacity;\n void main() {\n vec4 modelPosition = modelMatrix * vec4(position, 1.0);\n modelPosition.y += sin(time * speed + modelPosition.x * noise.x * 100.0) * 0.2;\n modelPosition.z += cos(time * speed + modelPosition.x * noise.y * 100.0) * 0.2;\n modelPosition.x += cos(time * speed + modelPosition.x * noise.z * 100.0) * 0.2;\n vec4 viewPosition = viewMatrix * modelPosition;\n vec4 projectionPostion = projectionMatrix * viewPosition;\n gl_Position = projectionPostion;\n gl_PointSize = size * 25. * pixelRatio;\n gl_PointSize *= (1.0 / - viewPosition.z);\n vColor = color;\n vOpacity = opacity;\n\n\t #include <logdepthbuf_vertex>\n }",fragmentShader:"\n #include <common>\n #include <logdepthbuf_pars_fragment>\n varying vec3 vColor;\n varying float vOpacity;\n void main() {\n float distanceToCenter = distance(gl_PointCoord, vec2(0.5));\n float strength = 0.05 / distanceToCenter - 0.1;\n gl_FragColor = vec4(vColor, strength * vOpacity);\n #include <tonemapping_fragment>\n #include <encodings_fragment>\n #include <logdepthbuf_fragment>\n }"};const N=e=>e&&e.constructor===Float32Array,F=e=>void 0!==(null==e?void 0:e.x)&&void 0!==(null==e?void 0:e.y)&&void 0!==(null==e?void 0:e.z),z=e=>Array.isArray(e)?e:F(e)?[e.x,e.y,e.z]:[e,e,e];function H(t,r,i){if(void 0!==r){if(N(r))return r;if(r instanceof e){const e=Array.from({length:3*t},(()=>(e=>[e.r,e.g,e.b])(r))).flat();return Float32Array.from(e)}if(F(r)||Array.isArray(r)){const e=Array.from({length:3*t},(()=>z(r))).flat();return Float32Array.from(e)}return Float32Array.from({length:t},(()=>r))}return Float32Array.from({length:t},i)}const k={uniforms:{tDiffuse:{value:null},h:{value:1/512}},vertexShader:"\n\n\t\tvarying vec2 vUv;\n\n\t\tvoid main() {\n\n\t\t\tvUv = uv;\n\t\t\tgl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );\n\n\t\t}",fragmentShader:"\n\n\t\tuniform sampler2D tDiffuse;\n\t\tuniform float h;\n\n\t\tvarying vec2 vUv;\n\n\t\tvoid main() {\n\n\t\t\tvec4 sum = vec4( 0.0 );\n\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x - 4.0 * h, vUv.y ) ) * 0.051;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x - 3.0 * h, vUv.y ) ) * 0.0918;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x - 2.0 * h, vUv.y ) ) * 0.12245;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x - 1.0 * h, vUv.y ) ) * 0.1531;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y ) ) * 0.1633;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x + 1.0 * h, vUv.y ) ) * 0.1531;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x + 2.0 * h, vUv.y ) ) * 0.12245;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x + 3.0 * h, vUv.y ) ) * 0.0918;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x + 4.0 * h, vUv.y ) ) * 0.051;\n\n\t\t\tgl_FragColor = sum;\n\n\t\t}"},V={uniforms:{tDiffuse:{value:null},v:{value:1/512}},vertexShader:"\n\n\t\tvarying vec2 vUv;\n\n\t\tvoid main() {\n\n\t\t\tvUv = uv;\n\t\t\tgl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );\n\n\t\t}",fragmentShader:"\n\n\t\tuniform sampler2D tDiffuse;\n\t\tuniform float v;\n\n\t\tvarying vec2 vUv;\n\n\t\tvoid main() {\n\n\t\t\tvec4 sum = vec4( 0.0 );\n\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y - 4.0 * v ) ) * 0.051;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y - 3.0 * v ) ) * 0.0918;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y - 2.0 * v ) ) * 0.12245;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y - 1.0 * v ) ) * 0.1531;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y ) ) * 0.1633;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y + 1.0 * v ) ) * 0.1531;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y + 2.0 * v ) ) * 0.12245;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y + 3.0 * v ) ) * 0.0918;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y + 4.0 * v ) ) * 0.051;\n\n\t\t\tgl_FragColor = sum;\n\n\t\t}"};var Y=Object.defineProperty,j=(e,t,r)=>(((e,t,r)=>{t in e?Y(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r})(e,"symbol"!=typeof t?t+"":t,r),r);function W(e){return void 0!==e.w?[t,4]:void 0!==e.z?[r,3]:[i,2]}function J(e,t,r){let i=function(e,t){const r=Math.sqrt(e.lengthSq()*t.lengthSq());if(0===r)return 0;let i=e.dot(t)/r;return i=Math.max(-1,Math.min(1,i)),Math.acos(i)}(e,t);return 0===i?i:e.clone().cross(t).dot(r)<0?-i:i}const K=180/Math.PI,_={yaw:[{name:"前",range:[-15,15]},{name:"左",range:[15,165]},{name:"右",range:[-165,-15]},{name:"后",range:[-180.1,-165]},{name:"后",range:[165,180.1]}],pitch:[{name:"前",range:[-15,15]},{name:"上",range:[15,165]},{name:"下",range:[-165,-15]},{name:"后",range:[-180.1,-165]},{name:"后",range:[165,180.1]}],roll:[{name:"上",range:[-15,15]},{name:"左",range:[15,165]},{name:"右",range:[-165,-15]},{name:"下",range:[-180.1,-165]},{name:"下",range:[165,180.1]}]};const Z={degrees:!0,map:_,front:{x:0,y:0,z:1},up:{x:0,y:1,z:0}};class X{constructor(e){j(this,"_options"),j(this,"_listMap"),j(this,"_front"),j(this,"_up"),e&&(this.options=e)}static get options(){return this._options??(this.options=Z)}static set options(e){this._options=Object.assign({},structuredClone(_),e)}get defaultOptions(){return this.constructor.options}get options(){return this._options??(this.options=this.defaultOptions)}set options(e){this._options=Object.assign({},structuredClone(this.defaultOptions),e),this._listMap=null,this._front=null,this._up=null}get degrees(){return this.options.degrees??(this.options.degrees=this.defaultOptions.degrees??!0)}set degrees(e){this.options.degrees=e}get map(){return this.options.map||(this.map=this.defaultOptions.map),this.options.map}set map(e){const t=structuredClone(this.defaultOptions.map),r=structuredClone(_);e=e?{yaw:e.yaw??t.yaw??r.yaw,pitch:e.pitch??t.pitch??r.pitch,roll:e.roll??t.roll??r.roll}:t,this.options.map=e,this._listMap=null}get listMap(){return this._listMap??(this._listMap=function(e){const t={};for(const[r,i]of Object.entries(e))t[r]=Array.isArray(i)?i:Object.entries(i).map((([e,t])=>({name:e,range:t})));return t}(this.map??{}))}get front(){return this._front||(this.front=this.options.front??this.defaultOptions.front??Z.front),this._front}set front(e){this._front=(new r).copy(e)}get up(){return this._up||(this.up=this.options.up??this.defaultOptions.up??Z.up),this._up}set up(e){this._up=(new r).copy(e)}computeAzimuth(e,t,i){const n=(new r).copy(e),a=(new r).copy(t??this.front),s=(new r).copy(i??this.up);let{yaw:o,pitch:l,roll:u}=function(e,t,r){const i=t.clone().negate(),n=r.clone().projectOnPlane(t),a=J(t,e.clone().projectOnPlane(n),n),s=t.clone().cross(n);return{yaw:a,pitch:J(t,e.clone().projectOnPlane(s),s),roll:J(n,e.clone().projectOnPlane(i),i)}}(n,a,s);return this.degrees&&(o*=K,l*=K,u*=K),{yaw:{angle:o,name:this.findAzimuthNames("yaw",o)},pitch:{angle:l,name:this.findAzimuthNames("pitch",l)},roll:{angle:u,name:this.findAzimuthNames("roll",u)}}}findAzimuthNames(e,t){const r=[],i=this.listMap[e];if(!i)return r;for(const{name:e,range:[n,a]}of i)(t>=n&&t<a||t<=n&&t>a)&&r.push(e);return r}}j(X,"_options"),new X;var q=Object.defineProperty,$=(e,t,r)=>(((e,t,r)=>{t in e?q(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r})(e,"symbol"!=typeof t?t+"":t,r),r);function ee(e){const t=[];for(let r=0;r<e;r++)t.push(n.randFloatSpread(2));return t}function te(e,t,r){const i=[],n=e-1;for(let e=0;e<n;e++){const e=2*(Math.random()-.5)*(t+r);i.push(e)}const a=Math.trunc(Math.random()*e);let s=2*(Math.random()-.5)*r;return s+=Math.sign(s)*t,i.splice(a,0,s),i}function re(e,t){const r=[],i=e-1;for(let e=0;e<i;e++)r.push(n.randFloatSpread(2));return r.push(Math.random()*t),r}function ie(e,t,r,i){const n=[],a=e-1,s=a-1;for(let e=0;e<s;e++){const e=2*(Math.random()-.5)*(t+r);n.push(e)}const o=Math.trunc(Math.random()*a);let l=2*(Math.random()-.5)*r;return l+=Math.sign(l)*t,n.splice(o,0,l),n.push(Math.random()*i),n}function ne(e){let t=[];for(let r=0;r<e;r++)t.push(n.randFloatSpread(2));const r=Math.hypot(...t),i=Math.random()/r;return t=t.map((e=>e*i)),t}function ae(e,t,r){let i=[];for(let t=0;t<e;t++)i.push(n.randFloatSpread(2));const a=Math.hypot(...i),s=(Math.random()*r+t)/a;return i=i.map((e=>e*s)),i}function se(e,t){let r=[];const i=e-1;for(let e=0;e<i;e++)r.push(n.randFloatSpread(2));const a=Math.hypot(...r),s=Math.random()/a;return r=r.map((e=>e*s)),r.push(Math.random()*t),r}function oe(e,t,r,i){let a=[];const s=e-1;for(let e=0;e<s;e++)a.push(n.randFloatSpread(2));const o=Math.hypot(...a),l=(Math.random()*r+t)/o;return a=a.map((e=>e*l)),a.push(Math.random()*i),a}function le({ratio:e,density:t}){return t-t*e}function ue({ratio:e,value:t}){return t-t*e}var ce=(e=>(e[e.Circle=0]="Circle",e[e.Square=1]="Square",e))(ce||{});function pe(e,t){const{clim:i,step:n,radius:a,value:s,solid:o,hollow:l,density:u,shape:c,densityGradient:p,valueGradient:h}=e,d=e,[A,g]=W(e);let f,m;if(t){const{lineStep:e,matrix:i}=t,n=1===c?ie:oe;f=function(t,a,s){const o=n(t,a,s,e);return 2===t&&o.push(0),new r(...o).applyMatrix4(i)},m=function(t,r){return t*r**(g-2)*e}}else{const e=1===c?te:ae;f=function(t,r,i){const n=e(t,r,i);return new A(...n)},m=function(e,t){return e*t**(g-1)}}const y=[],v=[],x=a*o,w=a-x,C=a*l;for(let e=C+n;e<a;e+=n){const t={ratio:(e-x)/w,radius:a,solid:o,distance:e,density:u,solidRadius:x,gradientRadius:w,clim:i,value:s,hollow:l,hollowRadius:C};let r=m(e<x?u:p(t),e);const c=e-n;for(;r-- >-1;){const e=f(g,c,n),r=(new A).copy(e),i=r.length();r.add(d),y.push(r);const s=h({...t,ratio:i/a,distance:i});v.push(s)}}return{particles:y,values:v}}function he(e){const{points:t,clim:r={x:0,y:100},step:i=3,radius:n=10,value:a=100,solid:s=.7,hollow:o=0,density:l=1,shape:u=0,densityGradient:c=le,valueGradient:p=ue}=e,h={clim:r,step:i,radius:n,value:a,solid:s,hollow:o,density:l,shape:u,densityGradient:c,valueGradient:p},d=t[0];if(!d)return[];const[A,g]=W(d);return t.map((e=>{const t=new A;return Object.assign(t,{...h,...e}),pe(t)}))}class de extends a{constructor(e){super(),$(this,"isClusterGeometry",!0),$(this,"_options"),$(this,"_colorGradient"),$(this,"_values"),e&&(this.options=e)}get options(){return this._options??(this._options={})}set options(e){this._options=e,this.updateVertices()}get gradient(){return this.options.gradient}set gradient(e){this.options.gradient=e,this.colorGradient=this.createColorGradient(e)}get colorGradient(){return this._colorGradient?this._colorGradient:this._colorGradient=this.createColorGradient(this.gradient)}set colorGradient(e){this._colorGradient=e,this.updateVertexColors()}createColorGradient(e){if(!e)return null;const t=Array.isArray(e)?function(e,t,r,i="srgb"){const n=new OffscreenCanvas(t,r).getContext("2d"),a=n.createLinearGradient(0,0,256,1);for(const[t,r]of e)a.addColorStop(Number(t),r);return n.fillStyle=a,n.fillRect(0,0,t,r),n.getImageData(0,0,t,r,{colorSpace:i})}(e,256,1):e,{width:r,height:i}=t,n=function(e,t){const{data:r,width:i}=e,n=t*i,a=n+i;return r.slice(4*n,4*a)}(t,Math.trunc(i/2));return new ImageData(n,r,1)}updateVertexColors(){this.deleteAttribute("color");const{colorGradient:e,clim:t,values:r}=this;if(!e)return!1;const{width:i,data:a}=e,o=[],{x:l,y:u}=t,c=u-l,p=i-1;for(const e of r){const t=1-(n.clamp(e,l,u)-l)/c,r=4*Math.trunc(t*p),i=a.slice(r,r+4);o.push(...i)}this.setAttribute("color",new s(new Uint8ClampedArray(o),4,!0))}get clim(){return this.options.clim??(this.options.clim={x:0,y:100})}set clim(e){this.options.clim=e,this.updateVertexColors()}get clusters(){return this.options.clusters}set clusters(e){this.options.clusters=e,this.updateVertices()}updateVertices(){this.deleteAttribute("position"),this._values=null;const e=this.clusters;if(!e)return;const t=[],r=[];let i=0;for(const{particles:n,values:a}of e){const e=n.length;for(let s=0;s<e;s++,i++){n[s].toArray(t,3*i);const e=a[s];r.push(e)}}this.setAttribute("position",new s(new Float32Array(t),3)),this.values=r}get values(){return this._values??(this._values=[])}set values(e){this._values=e,this.updateVertexColors()}addCluster(e){const t=Array.isArray(e)?e:[e],r=this.clusters;if(!r)return void(this.clusters=t);r.push.apply(r,t);let i=[];const n=[];let a=0;for(const{particles:e,values:r}of t){const t=e.length;for(let s=0;s<t;s++,a++){e[s].toArray(i,3*a);const t=r[s];n.push(t)}}const o=this.getAttribute("position");o&&(i=[...o.array,...i]),this.setAttribute("position",new s(new Float32Array(i),3)),o?this.addValueColors(n):this.values=n}addValueColors(e){const{colorGradient:t,clim:r,values:i}=this;if(!t)return!1;const{width:a,data:o}=t;let l=[];const{x:u,y:c}=r,p=c-u,h=a-1;for(const t of e){const e=1-(n.clamp(t,u,c)-u)/p,r=4*Math.trunc(e*h),a=o.slice(r,r+4);l.push(...a),i.push(t)}const d=this.getAttribute("color");d&&(l=[...d.array,...l]),this.setAttribute("color",new s(new Uint8ClampedArray(l),4,!0))}}function Ae({startRadius:e,addedRadius:t,ratio:r}){return t*r+e}function ge({startDensity:e,addedDensity:t,ratio:r}){return t*r+e}function fe({startValue:e,addedValue:t,ratio:r}){return t*r+e}function me(e){const{points:t,clim:i={x:0,y:100},step:n=3,radius:a=10,value:s=100,solid:o=.7,hollow:l=0,density:p=1,shape:h=ce.Circle,densityGradient:d=le,valueGradient:A=ue,radiusGradient:g=Ae,lineDensityGradient:f=ge,lineValueGradient:m=fe}=e,y=e.lineStep??n,v={clim:i,step:n,radius:a,value:s,solid:o,hollow:l,density:p,shape:h,densityGradient:d,valueGradient:A,radiusGradient:g,lineDensityGradient:f},{total:x,lengths:w}=function(e){const t=e.length;let r=e[0];const[i,n]=W(r),a=[0];let s=0;for(let n=1;n<t;n++){const t=(new i).copy(e[n]).distanceTo(r);a.push(t),s+=t}return{lengths:a,total:s}}(t),C=t.length,E=t[0],b=t[C-1],B=E.radius??a,M=E.density??p,D=E.value??s,S=b.radius??a,I=b.density??p,O=b.value??s,P={length:x,startRadius:B,endRadius:S,addedRadius:S-B,defaultRadius:a,startDensity:M,endDensity:I,addedDensity:I-M,defaultDensity:p,startValue:D,endValue:O,addedValue:O-D,defaultValue:s},T=[];for(let e=0;e<C;e++){const r=t[e];let{radius:i,value:n,density:a}=r;const s={...P,ratio:w[e]/x,index:e-1};i=i??g(s),a=a??f(s),n=n??m(s),T.push({...v,...r,radius:i,density:a,value:n})}const[R,G]=W(E),U=[],L=C-1;for(let e=0;e<L;e++){const t=T[e],{radius:i,density:n,value:o}=t,l=new R;l.lineStep=y;const h=T[e+1],{radius:d,density:A,value:v}=h,x=new R;Object.assign(x,h);const C=x.clone().sub(l).normalize(),E=w[e+1],b=Math.trunc(E/y),B=d-i,M=A-n,D=v-o,S=new u;3===G?S.setFromUnitVectors(new r(0,0,1),C):S.setFromUnitVectors(new r(0,1,0),new r(C.x,C.y,0));const I=(new c).makeRotationFromQuaternion(S);Object.assign(l,{...t,lineDir:C,matrix:I}),U.push(l);const O={length:E,startRadius:i,endRadius:d,addedRadius:B,defaultRadius:a,startDensity:n,endDensity:A,addedDensity:M,defaultDensity:p,startValue:o,endValue:v,addedValue:D,defaultValue:s,index:e,ratio:0};let P=0;for(let e=1;e<b;e++){P=e*y;const r=C.clone().multiplyScalar(P).add(l),i=P/E;O.ratio=i;const n=g(O),a=f(O),s=m(O),o={...t,lineDir:C,matrix:I,radius:n,density:a,value:s,lineStep:y};delete o.x,delete o.y,delete o.z,delete o.w,Object.assign(r,o),U.push(r)}U[U.length-1].lineStep=E-P}return U.map((e=>{const{lineStep:t,matrix:r}=e;return pe(e,{lineStep:t,matrix:r})}))}function ye(e,t){const{x:r,y:i}=t;let n=0;for(const{value:t,clim:{x:r,y:i}}of e)n+=(t-r)/(i-r);return n*(i-r)+r}function ve(e,t){const{clim:r,step:i,radius:n,value:a,solid:s,hollow:o,density:l,shape:u,densityGradient:c,valueGradient:p,valuesAccumulate:h}=e,[d,A]=W(e),g=(new d).copy(e),f=u===ce.Square?te:ae,m=[],y=[],v=n*s,x=n-v,w=n*o,C=t.map((e=>({dist:g.distanceTo(e),point:e})));for(let t=w+i;t<n;t+=i){const u={ratio:(t-v)/x,radius:n,solid:s,hollow:o,hollowRadius:w,distance:t,density:l,solidRadius:v,gradientRadius:x,clim:r,value:a},E=t<v?l:c(u);let b=E*t**(A-1);const B=t-i,M=C.filter((({dist:e,point:r})=>{const i=r.radius;return e-t<=i}));e:for(;b-- >-1;){const t=new d(...f(A,B,i)),a=t.length();t.add(g);const s=[],o={...u,ratio:a/n,distance:a},l=p(o);s.push({...e,...o,value:l,density:E});for(const{point:e}of M){const r=t.distanceTo(e),{solid:i,hollow:n,radius:a}=e;if(r<=a){const t=a*i,o=a-t,l=a*n;if(r<l)continue e;const u={...e,ratio:r/a,distance:r,solidRadius:t,gradientRadius:o,hollowRadius:l},c=p(u);s.push({...u,value:c})}}m.push(t);const c=h(s,r,E);y.push(c)}}return{particles:m,values:y}}function xe(e){const{points:t,clim:r={x:0,y:100},step:i=3,radius:n=10,value:a=100,solid:s=.7,hollow:o=0,density:l=1,shape:u=ce.Circle,densityGradient:c=le,valueGradient:p=ue,valuesAccumulate:h=ye}=e,d={clim:r,step:i,radius:n,value:a,solid:s,hollow:o,density:l,shape:u,densityGradient:c,valueGradient:p,valuesAccumulate:h},A=t.map((e=>({...d,...e}))),g=function(e){const t=e.length,r=[];if(0===t)return r;const[i,n]=W(e[0]);for(let n=0;n<t;n++){const a=e[n],s=(new i).copy(a),o=a.radius,l=r[n]??(r[n]=[]);for(let i=n+1;i<t;i++){const t=e[i];s.distanceToSquared(t)<=(t.radius+o)**2&&(l.push(i),(r[i]=[]).push(n))}}return r}(A);return A.map(((e,t)=>{const r=g[t].map((e=>A[e]));return ve({...d,...e},r)}))}var we=(e=>(e[e.Point=0]="Point",e[e.Line=1]="Line",e[e.Heat=2]="Heat",e))(we||{});const Ce={cluster:{base:["radius","solid","hollow","density","shape","densityGradient","step","clusterType","points"],line:["radiusGradient","lineDensityGradient","lineStep"],heat:[]},gradient:{base:["value","valueGradient","clim","gradient"],line:["lineValueGradient"],heat:["valuesAccumulate"]}};class Ee extends de{constructor(e){super(),$(this,"isParticleClusterGeometry",!0),e&&(this.options=e)}get options(){return this._options}set options(e){this._options=e,this.updateClusters()}get clusterType(){return this.options.clusterType}set clusterType(e){this.options.clusterType!==e&&(this.options.clusterType=e,this.updateClusters())}setOptions(e){const t=this.options;let r=!1;const i=Object.entries(e).some((([e,i])=>i!==t[e]&&(!!(Ce.cluster.base.includes(e)||1===this.clusterType&&Ce.cluster.line.includes(e)||2===this.clusterType&&Ce.cluster.heat.includes(e))||(Ce.gradient.base.includes(e)&&(r=!0),1===this.clusterType&&Ce.gradient.line.includes(e)&&(r=!0),void(2===this.clusterType&&Ce.gradient.heat.includes(e)&&(r=!0))))));Object.assign(this.options,e),i?this.updateClusters():r&&this.updateVertexColors()}updateClusters(){this.clusters=this.createClusters(this.options)}createClusters(e){let t;switch(e.clusterType){case 2:t=xe(e);break;case 1:t=me(e);break;default:t=he(e)}return t}addPoint(e,t){const r=Array.isArray(e)?e:[e],i={...this.options,...t,points:r},n=this.createClusters(i);this.addCluster(n)}}class be extends o{constructor(e){super(new Ee,new l({vertexColors:!0,transparent:!0,...e})),$(this,"isParticleCluster",!0),e&&(this.options=e)}get options(){return this.geometry.options}set options(e){const t=null==e?void 0:e.points;if(t){const r=this.convertPoints(t);e={...e,points:r}}this.geometry.options=e}setOptions(e){const t=e.points;if(t){const r=this.convertPoints(t);e={...e,points:r}}this.geometry.setOptions(e)}addPoint(e,t){const r=Array.isArray(e)?e:[e],i=this.convertPoints(r);this.geometry.addPoint(i,t)}convertPoints(e){const t=this.matrixWorld.clone().invert();return e.map((e=>{const i=new r;return Object.assign(i,e),i.applyMatrix4(t),i}))}}class Be{constructor(e){const{textureUrl:t,width:r,height:i,position:n,isScaleAnimate:a,isOpacityAnimate:s}=e;void 0!==t[1]&&(this.outMaterial=this.createMaterial(t[1]),this.outPlaneGeometry=this.createPlane(r,i),this.outMesh=new p(this.outPlaneGeometry,this.outMaterial),this.outMesh.renderOrder=Number.MAX_SAFE_INTEGER-2,this.outMesh.position.set(n.x,n.y,n.z),this.outMesh.rotation.set(-1.5707022192751596,33819658717412135e-21,.34500000055302255)),this.inMaterial=this.createMaterial(t[0]),this.inPlaneGeometry=this.createPlane(r,i),this.inMesh=new p(this.inPlaneGeometry,this.inMaterial),this.inMesh.renderOrder=Number.MAX_SAFE_INTEGER-1,this.inMesh.position.set(n.x,n.y,n.z),this.inMesh.rotation.set(-1.5707022192751596,33819658717412135e-21,.34500000055302255),this.isScaleAnimate=a,this.isOpacityAnimate=s,this.AngleUnit=.1,this.MaxScale=3,this.ScaleUnit=.02,this.OpacityUnit=1/((this.MaxScale-0)/this.ScaleUnit)}createPlane(e=10,t=10){return new h(e,t)}createMaterial(e){const t=new d,r=(new A).load(e);return t.map=r,t.side=g,t.transparent=!0,t}update(){if(void 0!==this.outMesh){const e=this.outMesh.material.map;null==e||e.center.set(.5,.5),e.rotation+=this.AngleUnit}const e=this.inMesh.material.map;if(null==e||e.center.set(.5,.5),e.rotation-=this.AngleUnit,this.isScaleAnimate){this.inMesh.scale.x>this.MaxScale&&(this.inMesh.scale.x=0,this.inMesh.scale.y=0,this.inMesh.material.opacity=1,void 0!==this.outMesh&&(this.outMesh.scale.y=0,this.outMesh.scale.x=0,this.outMesh.material.opacity=1)),void 0!==this.outMesh&&(this.outMesh.scale.y+=this.ScaleUnit,this.outMesh.scale.x+=this.ScaleUnit),this.inMesh.scale.x+=this.ScaleUnit,this.inMesh.scale.y+=this.ScaleUnit}this.isOpacityAnimate&&(void 0!==this.outMesh&&(this.outMesh.material.opacity-=this.OpacityUnit),this.inMesh.material.opacity-=this.OpacityUnit)}}class Me{constructor(e){const{topRadius:t,bottomRadius:r,height:i,position:n,texturePath:a,color:s}=e;this.geometry=this.createGeometry(t,r,i),this.material=this.creatematerial(a,s),this.position=n,this.mesh=new p(this.geometry,this.material),this.mesh.renderOrder=Number.MAX_SAFE_INTEGER-1,this.mesh.position.set(n.x,n.y+i/2,n.z),this.maxScale=15,this.minScale=1,this.opacityUnit=1/this.maxScale}createGeometry(e,t,r){return new f(e,t,r,32,16,!0)}creatematerial(e,t){const r=new d,i=(new A).load(e);return r.map=i,r.side=g,r.opacity=1,r.transparent=!0,r}update(){let e=this.mesh.scale.x;e+=.1,e>=this.maxScale&&(e=1);const t=1-this.opacityUnit*e;this.mesh.scale.set(e,this.mesh.scale.y,e),this.mesh.material.opacity=t}}var De={vertexShader:"\n attribute float size;\n uniform float showDistance;\n varying float dcolor;\n void main() {\n\n vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );\n // vec4 viewPosition = viewMatrix * mvPosition;\n \n //gl_PointSize = 5.0;\n float fDistance =sqrt( position.x * position.x + position.z * position.z );\n if(fDistance < showDistance)\n return;\n\n // dcolor = fDistance/355.0/3.0;\n gl_Position = projectionMatrix * mvPosition;\n gl_PointSize = size * ( 300.0 / - mvPosition.z );\n // gl_PointSize *= (1.0 / - viewPosition.z);\n }\n ",fragmentShader:"\n #include <common>\n uniform vec3 color;\n uniform float opacity;\n // varying float dcolor;\n void main() {\n\n //if ( length( gl_PointCoord - vec2( 0.5, 0.5 ) ) > 0.475 ) discard;\n // int buffer = int(dcolor);\n \n //gl_FragColor = vec4( dcolor,sin(dcolor),0, 1.0 );\n gl_FragColor = vec4( color, opacity );\n\n #include <tonemapping_fragment>\n #include <encodings_fragment>\n }\n "},Se={vertexShader:"\n uniform vec2 lowHeigh;\n varying float ratioHeigh;\n void main() {\n \n vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );\n float maxHeigh = lowHeigh.y - lowHeigh.x;\t\n float curHeigh = lowHeigh.y - position.y;\t\n ratioHeigh = curHeigh/maxHeigh;\n gl_Position = projectionMatrix * mvPosition;\n \n }\n ",fragmentShader:"\n #include <common>\n uniform vec3 color;\n varying float ratioHeigh;\n void main() {\n \n // gl_FragColor = vec4( color, 1.0-ratioHeigh*ratioHeigh*ratioHeigh-0.5 );\n gl_FragColor = vec4( color, max( 1.0-ratioHeigh*ratioHeigh*ratioHeigh-0.5, 0.01 ) );\n\n #include <tonemapping_fragment>\n #include <encodings_fragment>\n }\n "};class Ie{constructor(e){this.ssp=e,this.weatherPresetImgs={rain:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAASQSURBVHjarFfPb1RVFP7Oufe9Nz86zLSlI2DjD4xYYyFGY7QJiQu60ITEENlhIgs2hIoLjewb3bvgH8DEuDAEY1y4IKwMRYmAhGAULZGGinSmM5158+bN+3GPi04rbaf0tvUkMy95uffc73znO+fcRyKC1Tb5fYqNzNOMW/f9N6q1Ogad4EpiaMM9X32wb8073WuhbOwLfmxwr6lPLQSZZKiMKwWHIdi89QRg9OMRaAZuz0Tv3Hyg3gOV5IWsXBh5yv02Tv8nAI1OtO4GIiBJMXT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kaEphoFeJwBeL4cCIBGg5EQXXuxfOJRT7csCgQjBdLcJAENLT4YRggiQ5fbl0YHGoZITX0iElv1Zp2BlIyMAdHWn135rwKm/e9cvHAvhvgbhHQZMEAJTKkSmkVHR1b15/8t67J4XoaZN0rSNort0N0s6PJdj91K/8l8v5PTYdDA4AAL25urzfiueaqfujyUnnKnHrthOkH8HAIl7DGQhmnDgAAAAAElFTkSuQmCC",snow:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAUNJREFUOE+lk78rhWEUxz/fwWAzUBYs/gMMNkp+lbKwWPgPGAySuJPxWqSUMhMpgzCwWShumSibxWJ2h6/O7Xlvb5d7da+nTk9vz3s+z/ec53vEP5ca5du+iXNJo/X++wGwvQhMp4SutH+kfVnSex5WBdjuB76AE0lDto+AKkDSvO17YE/SQQapAGwPAHG4CmwAnZLKtSXYNjALrAMLkl4ywBywAgwDJaAo6TAPSKUVgF7gAtiRdJVXMAZkEcLOgI4k9TPdHJ+RXAlJrxlgBOgBniSVbG8Bm0AkxgpQQdKW7Skg4lTSbR7QLinI0ZMoaRdoawA4l3SdAYaASWACKAOhqKkSxoHlJC0uXarTxG2gG7hLjT6ufcZ9YAboa/CMAVkDBiU95I0UXngDLv8wUhF4lPRcsXmtx1u28m/D0tIwNTvd35YVoxGOzVJ7AAAAAElFTkSuQmCC"},this._weatherId=""}createFlame(i){const{magnitude:n=1.3,gain:a=.5}=i,s=50,o=new p(new m(1,1,1),(i=>{const{imgUrl:o=P}=i,l=(new A).load(o);l.magFilter=l.minFilter=B,l.wrapS=l.wrapT=M;const u=new b({defines:{ITERATIONS:20,OCTIVES:3,WIDTH:128,BOUNDS:512},uniforms:D.merge([S.phong.uniforms,{fireTex:{type:"t",value:l},time:{type:"f",value:0},seed:{type:"f",value:19.19*Math.random()},invModelMatrix:{type:"v4",value:new c},scale:{type:"v3",value:new r(s,s,s)},noiseScale:{type:"v4",value:new t(1,2,1,.3)},magnitude:{type:"f",value:n},gain:{type:"f",value:a},lacunarity:{type:"f",value:2},diffuse:{type:"c",value:new e(16576)},specular:{type:"c",value:new e(1118481)},shininess:{type:"f",value:Math.max(50,1e-4)},opacity:{type:"f",value:.8}}]),vertexShader:O.vertexShader,fragmentShader:O.fragmentShader,transparent:!0,depthWrite:!1,depthTest:!0,lights:!0});return u.uniforms.fireTex.value=l,u})(i));o.scale.set(s,s,s);this.ssp.viewport.postUpdate.set(i.id,(e=>{const t=o.material,i=t.uniforms.invModelMatrix.value;o.updateMatrixWorld(),i.copy(o.matrixWorld).invert(),void 0!==e&&(t.uniforms.time.value=e/1e3),t.uniforms.invModelMatrix.value=i,t.uniforms.scale.value=o.getWorldScale(new r),t.uniforms.magnitude.value=n||1.3,t.uniforms.gain.value=a||.5,t.version++,this.ssp.render()}));const l=this.ssp.createPluginObject(i,o);return l.addEventListener("removed",(()=>{this.ssp.viewport.postUpdate.delete(i.id)})),l}removeFlame(e){return console.warn("请使用 ssp.removeObjectById 替代"),this.ssp.removeObjectById(e)}createSmoke(t){const{imgUrl:i=L,count:n=1e3,maxAge:a=4,size:s=200,acceleration:o=10,velocity:l={x:100,y:100,z:100},color:u=[3355443,1118481]}=t,c=new y,p=(new A).load(i),h=new U.Group({texture:{value:p},blending:v}),d=new U.Emitter({particleCount:n,maxAge:{value:a},position:{value:new r(0,0,0),spread:new r(0,0,0)},size:{value:s,spread:[1,1,8]},acceleration:{value:new r(0,o,0)},rotation:{angle:this.ssp.utils.deg2Euler(45),randomise:!0},velocity:{value:new r(0,100,0),spread:new r(l.x,l.y,l.z)},opacity:{value:[.5,.2,0]},color:{value:u.map((t=>new e(t)))}});h.addEmitter(d);this.ssp.viewport.postUpdate.set(t.id,(()=>{h.tick(c.getDelta()),this.ssp.render()}));const g=this.ssp.createPluginObject(t,h.mesh);return g.addEventListener("removed",(()=>{this.ssp.viewport.postUpdate.delete(t.id)})),g}removeSmoke(e){return console.warn("请使用 removeObjectById 替代"),this.ssp.removeObjectById(e)}createSparkles(e){const{count:t=100,scalar:r=8,speed:i=1,opacity:n=1,noise:a=1,color:s="#fff",size:o=2}=e,{ssp:l}=this,{THREE:u}=l,{Points:c,ShaderMaterial:p,BufferGeometry:h,BufferAttribute:d}=u,A=Float32Array.from(Array.from({length:t},(()=>z(r).map(u.MathUtils.randFloatSpread))).flat()),g=H(t,o,Math.random),f=H(t,n),m=H(t,i),y=H(3*t,a),v=H(void 0===s?3*t:t,N(s)?s:new u.Color(s),(()=>1)),w=new h;w.setAttribute("position",new d(A,3)),w.setAttribute("size",new d(g,1)),w.setAttribute("opacity",new d(f,1)),w.setAttribute("speed",new d(m,1)),w.setAttribute("color",new d(v,3)),w.setAttribute("noise",new d(y,3));const C=new p({uniforms:{time:{value:0},pixelRatio:{value:self.devicePixelRatio}},vertexShader:Q.vertexShader,fragmentShader:Q.fragmentShader,depthWrite:!1,transparent:!0,blending:x}),E=new c(w,C);this.ssp.viewport.postUpdate.set(e.id,(()=>{C.uniforms.time.value=l.viewport.clock.elapsedTime,this.ssp.render()}));const b=this.ssp.createPluginObject(e,E);return b.addEventListener("removed",(()=>{this.ssp.viewport.postUpdate.delete(e.id)})),b}createContactShadows(e){var{scale:t=10,frames:r=1/0,opacity:i=1,width:n=1,height:a=1,blur:s=1,darkness:o=1,far:l=10,resolution:u=512}=e,c=function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(i=Object.getOwnPropertySymbols(e);n<i.length;n++)t.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(r[i[n]]=e[i[n]])}return r}(e,["scale","frames","opacity","width","height","blur","darkness","far","resolution"]);const{viewport:{renderer:p,scene:h},THREE:d}=this.ssp;n*=Array.isArray(t)?t[0]:t||1,a*=Array.isArray(t)?t[1]:t||1;const A=new d.Group,g=new d.OrthographicCamera(-n/2,n/2,a/2,-a/2,0,l);g.rotation.x=Math.PI/2,A.add(g);const f=new d.WebGLRenderTarget(u,u),m=new d.WebGLRenderTarget(u,u);m.texture.generateMipmaps=f.texture.generateMipmaps=!1;const y=new d.PlaneGeometry(n,a).rotateX(Math.PI/2),v=new d.MeshBasicMaterial({map:f.texture,opacity:i,transparent:!0,depthWrite:!1}),x=new d.Mesh(y,v);x.renderOrder=1,x.scale.y=-1,A.add(x);const w=new d.Mesh(y);w.visible=!1,A.add(w);const C=new d.MeshDepthMaterial;C.userData.darkness={value:o},C.onBeforeCompile=function(e){e.uniforms.darkness=C.userData.darkness,e.fragmentShader=`\n uniform float darkness;\n ${e.fragmentShader.replace("gl_FragColor = vec4( vec3( 1.0 - fragCoordZ ), opacity );","gl_FragColor = vec4( vec3( 0.0 ), ( 1.0 - fragCoordZ ) * darkness );")}\n `},C.depthTest=!1,C.depthWrite=!1;const E=new d.ShaderMaterial(k);E.depthTest=!1;const b=new d.ShaderMaterial(V);function B(e){w.visible=!0,w.material=E,E.uniforms.tDiffuse.value=f.texture,E.uniforms.h.value=1*e/256,p.setRenderTarget(m),p.render(w,g),w.material=b,b.uniforms.tDiffuse.value=m.texture,b.uniforms.v.value=1*e/256,p.setRenderTarget(f),p.render(w,g),w.visible=!1}b.depthTest=!1;let M=0;const D=()=>{if(M>r)return;M++;const e=h.background;h.background=null,h.overrideMaterial=C;const t=p.getClearAlpha();p.setClearAlpha(0),p.setRenderTarget(f),p.render(h,g),h.overrideMaterial=null,B(s),B(.4*s),p.setRenderTarget(null),p.setClearAlpha(t),h.background=e};this.ssp.signals.beforeRender.add(D);const S=this.ssp.createPluginObject(c,A);return S.addEventListener("removed",(()=>{this.ssp.signals.beforeRender.remove(D)})),S}openWeather(e={}){const{imgUrl:t=this.weatherPresetImgs.rain,count:r=500,range:i=100,size:u=1,opacity:c=.9,color:p=16777215,velocityX:h=[-.02,.02],velocityY:d=[.4,.8]}=e;this._weatherId&&this.closeWeather();const{viewport:{renderer:g,container:f},utils:m}=this.ssp,y=new Float32Array(3*r),v=Array.from({length:r}).fill({x:0,y:0}),x=new a;for(let e=0;e<r;e++)y[3*e]=n.randFloatSpread(i),y[3*e+1]=n.randFloatSpread(i),y[3*e+2]=n.randFloatSpread(i),v[e].x=n.randFloat(...h),v[e].y=n.randFloat(...d);const b=new s(y,3);b.setUsage(w),x.setAttribute("position",b);const B=(new A).load(t);B.colorSpace=g.outputColorSpace;const M=new l({color:p,size:u,opacity:c,map:B,transparent:!0}),D=new o(x,M),S=new C,I=new E(45,f.offsetWidth/f.offsetHeight,.1,1e3);I.position.set(0,0,i/2),S.add(D);this._weatherId=`weather_${m.randomString()}`,this.ssp.viewport.postRender.set(this._weatherId,(()=>{v.forEach(((e,t)=>{y[3*t]-=e.x,y[3*t+1]-=e.y,(y[3*t]<=-i/2||y[3*t]>=i/2)&&(v[t].x*=-1),y[3*t+1]<=-i/2&&(y[3*t+1]=i/2)})),b.needsUpdate=!0,g.render(S,I),this.ssp.render()})),this.ssp.render()}closeWeather(){this._weatherId&&(this.ssp.viewport.postRender.delete(this._weatherId),this._weatherId="",this.ssp.render())}createParticleCluster(e){const t=new be(e);return this.ssp.addObject(t),t}createCircleWave(e){const t=this.ssp.createPluginObject(e),r=new Be(e);return t.add(r.inMesh),r.outMesh&&t.add(r.outMesh),this.ssp.viewport.postUpdate.set(e.id,(()=>{r.update(),this.ssp.render()})),t.addEventListener("removed",(()=>{this.ssp.viewport.postUpdate.delete(e.id)})),t}createCylinderWave(e){const t=this.ssp.createPluginObject(e),r=new Me(e);return t.add(r.mesh),this.ssp.addObject(t),this.ssp.viewport.postUpdate.set(e.id,(()=>{r.update(),this.ssp.render()})),t.addEventListener("removed",(()=>{this.ssp.viewport.postUpdate.delete(e.id)})),t}createPointsWave(t){let r=0;const{xAxisCount:i=100,zAxisCount:n=100,showDistance:l=0,separation:u=20,size:c=5,maxFluctua:p=.1,color:h="#485c7c",opacity:d=1}=t,A=i*n,g=new Float32Array(3*A),f=new Float32Array(A);let m=0,y=0;for(let e=0;e<i;e++)for(let t=0;t<n;t++)g[m]=e*u-i*u/2,g[m+1]=0,g[m+2]=t*u-n*u/2,f[y]=1,m+=3,y++;const v=new a;v.setAttribute("position",new s(g,3).setUsage(w)),v.setAttribute("size",new s(f,1).setUsage(w));const x=new b({transparent:!0,depthWrite:!1,uniforms:{color:{value:new e(h)},opacity:{value:d},showDistance:{value:l}},vertexShader:De.vertexShader,fragmentShader:De.fragmentShader}),C=new o(v,x);C.renderOrder=-1;this.ssp.viewport.postUpdate.set(t.id,(()=>{const e=C.geometry.attributes.position.array,t=C.geometry.attributes.size.array;let a=0,s=0;const o=Math.sqrt(i/2*(i/2)+n/2*(n/2));for(let l=0;l<i;l++)for(let u=0;u<n;u++){const h=l-i/2,d=u-n/2,A=Math.sqrt(h*h+d*d);e[a+1]=50*Math.cos(1*(A/o*50-r))*p,t[s]=c,a+=3,s++}C.geometry.attributes.position.needsUpdate=!0,C.geometry.attributes.size.needsUpdate=!0,r+=.01,this.ssp.render()}));const E=this.ssp.createPluginObject(t,C);return E.addEventListener("removed",(()=>{this.ssp.viewport.postUpdate.delete(t.id)})),E}createBuilds(t){const{buildWidth:r=100,buildDepth:n=100,buildHeigh:a=200,count:s=12,gapX:o=2,gapZ:l=2,showDistance:u=1e3,randShift:c=.5,color:h="#485c7c"}=t,d=this.ssp.createPluginObject(t);for(let t=0;t<s;t++)for(let A=0;A<s;A++){const g=(t-s/2)*r*o+(Math.random()-1)*c*r*o,f=(A-s/2)*n*l+(Math.random()-1)*c*n*l;if(Math.sqrt(g*g+f*f)<u)continue;const y=Math.floor(Math.random()*a)+a,v=new m(r,y,n,1,1,1);v.translate(g,y/2,f),v.computeBoundingBox();const x=v.boundingBox,w=new b({transparent:!0,depthWrite:!1,uniforms:{color:{value:new e(h)},lowHeigh:{value:new i(x.min.y,x.max.y)}},vertexShader:Se.vertexShader,fragmentShader:Se.fragmentShader}),C=new p(v,w);d.add(C)}return d}removeEffect(e){return console.warn("请使用 removeObjectById 替代"),this.ssp.removeObjectById(e)}}export{de as ClusterGeometry,we as ClusterType,be as ParticleCluster,Ee as ParticleClusterGeometry,ce as ParticleClusterShape,ve as createHeatParticleClusterData,xe as createHeatParticleClusterDataArr,pe as createPointParticleClusterData,he as createPointParticleClusterDataArr,Ie as default,le as densityGradient_Default,ne as getRandomVector_Circle,ae as getRandomVector_CircleAnnular,se as getRandomVector_CircleCylinder,oe as getRandomVector_CircleCylinderAnnular,ee as getRandomVector_Square,te as getRandomVector_SquareAnnular,re as getRandomVector_SquareCylinder,ie as getRandomVector_SquareCylinderAnnular,ue as valueGradient_Default,ye as valuesAccumulate_Default};
|
|
1
|
+
import{Color as e,Vector4 as t,Vector3 as r,Vector2 as i,MathUtils as n,BufferGeometry as a,BufferAttribute as s,Points as o,PointsMaterial as l,Quaternion as u,Matrix4 as c,Mesh as p,PlaneGeometry as h,MeshBasicMaterial as d,TextureLoader as A,DoubleSide as g,CylinderGeometry as f,BoxGeometry as m,Clock as y,NormalBlending as v,AdditiveBlending as x,DynamicDrawUsage as w,Scene as C,PerspectiveCamera as E,ShaderMaterial as b,LinearFilter as B,ClampToEdgeWrapping as M,UniformsUtils as D,ShaderLib as S}from"three";import I from"soonspacejs";"function"==typeof SuppressedError&&SuppressedError;var O={vertexShader:"\n varying vec3 vViewPosition;\n varying vec3 vWorldPos;\n varying vec3 vNormal;\n\n #include <common>\n #include <uv_pars_vertex>\n #include <displacementmap_pars_vertex>\n #include <envmap_pars_vertex>\n #include <color_pars_vertex>\n #include <morphtarget_pars_vertex>\n #include <skinning_pars_vertex>\n #include <shadowmap_pars_vertex>\n #include <logdepthbuf_pars_vertex>\n #include <clipping_planes_pars_vertex>\n \n void main() {\n\n #include <uv_vertex>\n #include <color_vertex>\n \n //# include <begin_vertex>\n vec3 transformed = vec3( position.x, position.y, position.z );\n //<begin_vertex>\n \n #include <morphtarget_vertex>\n #include <displacementmap_vertex>\n #include <project_vertex>\n #include <logdepthbuf_vertex>\n #include <clipping_planes_vertex>\n\n vViewPosition = - mvPosition.xyz;\n\n #include <worldpos_vertex>\n\n vWorldPos = (modelMatrix * vec4(position, 1.0)).xyz;\n }",fragmentShader:"\n #include <packing>\n #include <logdepthbuf_pars_fragment>\n \n uniform vec3 color;\n uniform float time;\n uniform float seed;\n uniform mat4 invModelMatrix;\n uniform vec3 scale;\n \n uniform vec4 noiseScale;\n uniform float magnitude;\n uniform float lacunarity;\n uniform float gain;\n \n uniform sampler2D fireTex;\n \n varying vec3 vWorldPos;\n \n // GLSL simplex noise function by ashima / https://github.com/ashima/webgl-noise/blob/master/src/noise3D.glsl\n // -------- simplex noise\n vec3 mod289(vec3 x) {\n return x - floor(x * (1.0 / 289.0)) * 289.0;\n }\n \n vec4 mod289(vec4 x) {\n return x - floor(x * (1.0 / 289.0)) * 289.0;\n }\n \n vec4 permute(vec4 x) {\n return mod289(((x * 34.0) + 1.0) * x);\n }\n \n vec4 taylorInvSqrt(vec4 r) {\n return 1.79284291400159 - 0.85373472095314 * r;\n }\n \n float snoise(vec3 v) {\n const vec2 C = vec2(1.0 / 6.0, 1.0 / 3.0);\n const vec4 D = vec4(0.0, 0.5, 1.0, 2.0);\n \n // First corner\n vec3 i = floor(v + dot(v, C.yyy));\n vec3 x0 = v - i + dot(i, C.xxx);\n \n // Other corners\n vec3 g = step(x0.yzx, x0.xyz);\n vec3 l = 1.0 - g;\n vec3 i1 = min(g.xyz, l.zxy);\n vec3 i2 = max(g.xyz, l.zxy);\n \n // x0 = x0 - 0.0 + 0.0 * C.xxx;\n // x1 = x0 - i1 + 1.0 * C.xxx;\n // x2 = x0 - i2 + 2.0 * C.xxx;\n // x3 = x0 - 1.0 + 3.0 * C.xxx;\n vec3 x1 = x0 - i1 + C.xxx;\n vec3 x2 = x0 - i2 + C.yyy; // 2.0*C.x = 1/3 = C.y\n vec3 x3 = x0 - D.yyy; // -1.0+3.0*C.x = -0.5 = -D.y\n \n // Permutations\n i = mod289(i); \n vec4 p = permute(permute(permute( \n i.z + vec4(0.0, i1.z, i2.z, 1.0))\n + i.y + vec4(0.0, i1.y, i2.y, 1.0))\n + i.x + vec4(0.0, i1.x, i2.x, 1.0));\n \n // Gradients: 7x7 points over a square, mapped onto an octahedron.\n // The ring size 17*17 = 289 is close to a multiple of 49 (49*6 = 294)\n float n_ = 0.142857142857; // 1.0/7.0\n vec3 ns = n_ * D.wyz - D.xzx;\n \n vec4 j = p - 49.0 * floor(p * ns.z * ns.z); // mod(p,7*7)\n \n vec4 x_ = floor(j * ns.z);\n vec4 y_ = floor(j - 7.0 * x_); // mod(j,N)\n \n vec4 x = x_ * ns.x + ns.yyyy;\n vec4 y = y_ * ns.x + ns.yyyy;\n vec4 h = 1.0 - abs(x) - abs(y);\n \n vec4 b0 = vec4(x.xy, y.xy);\n vec4 b1 = vec4(x.zw, y.zw);\n \n //vec4 s0 = vec4(lessThan(b0,0.0))*2.0 - 1.0;\n //vec4 s1 = vec4(lessThan(b1,0.0))*2.0 - 1.0;\n vec4 s0 = floor(b0) * 2.0 + 1.0;\n vec4 s1 = floor(b1) * 2.0 + 1.0;\n vec4 sh = -step(h, vec4(0.0));\n \n vec4 a0 = b0.xzyw + s0.xzyw * sh.xxyy;\n vec4 a1 = b1.xzyw + s1.xzyw * sh.zzww;\n \n vec3 p0 = vec3(a0.xy, h.x);\n vec3 p1 = vec3(a0.zw, h.y);\n vec3 p2 = vec3(a1.xy, h.z);\n vec3 p3 = vec3(a1.zw, h.w);\n \n //Normalise gradients\n vec4 norm = taylorInvSqrt(vec4(dot(p0, p0), dot(p1, p1), dot(p2, p2), dot(p3, p3)));\n p0 *= norm.x;\n p1 *= norm.y;\n p2 *= norm.z;\n p3 *= norm.w;\n \n // Mix final noise value\n vec4 m = max(0.6 - vec4(dot(x0, x0), dot(x1, x1), dot(x2, x2), dot(x3, x3)), 0.0);\n m = m * m;\n return 42.0 * dot(m * m, vec4(dot(p0, x0), dot(p1, x1), dot(p2, x2), dot(p3, x3)));\n }\n // simplex noise --------\n \n float turbulence(vec3 p) {\n float sum = 0.0;\n float freq = 1.0;\n float amp = 1.0;\n \n for(int i = 0; i < OCTIVES; i++) {\n sum += abs(snoise(p * freq)) * amp;\n freq *= lacunarity;\n amp *= gain;\n }\n \n return sum;\n }\n \n vec4 samplerFire (vec3 p, vec4 scale) {\n vec2 st = vec2(sqrt(dot(p.xz, p.xz)), p.y);\n \n if(st.x <= 0.0 || st.x >= 1.0 || st.y <= 0.0 || st.y >= 1.0) return vec4(0.0);\n \n p.y -= (seed + time) * scale.w;\n p *= scale.xyz;\n \n st.y += sqrt(st.y) * magnitude * turbulence(p);\n \n if(st.y <= 0.0 || st.y >= 1.0) return vec4(0.0);\n \n return texture2D(fireTex, st);\n }\n \n vec3 localize(vec3 p) {\n return (invModelMatrix * vec4(p, 1.0)).xyz;\n }\n \n void main() {\n #include <logdepthbuf_fragment>\n \n vec3 rayPos = vWorldPos;\n vec3 rayDir = normalize(rayPos - cameraPosition);\n float rayLen = 0.0288 * length(scale.xyz);\n \n vec4 col = vec4(0.0);\n \n for(int i = 0; i < ITERATIONS; i++) {\n rayPos += rayDir * rayLen;\n \n vec3 lp = localize(rayPos);\n \n lp.y += 0.5;\n lp.xz *= 2.0;\n col += samplerFire(lp, noiseScale);\n }\n \n col.a = col.r;\n gl_FragColor.a = 1.0;\n gl_FragColor = col;\n }"},P="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAACACAIAAAA04/g9AAAABGdBTUEAALGOfPtRkwAAACBjSFJNAAB6JQAAgIMAAPn/AACA6AAAdTAAAOpgAAA6lwAAF2+XqZnUAAAel0lEQVR4nGLkYmX4/5/hHyMDw38GBijB8P8fiAUkGP+DRP4yDF4AEEAsTEwgDzAxMPyDuR5EMYIQI5j/Dyz7Hy47yABAADFzszEwMoJYTIwghwL9A3I6I5T8z8jADHY6EwPUG4MNAAQQCzMzKKSZ/4FCGpiQIKH/H8z4+w/kaEawgn9/QVE0CAFAADHzs4PDnomBkQnkUFDQMzJAcgQ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XQyrnv7COrUMMP//gY2G/4Ula3iD+R/Scgmo3/5BEz106ybMJ2iJ5z9unwAEEAswA/39C6tfIQc7MUCnlP8zoKQuRtjMOyO8vGKEhjRyMwSSHRnAlRR8PgK6HecfNJvCXQ+dwf8HywBILiNY/kAAQACxAOtzRnCDhwm2ggK+RZYBNjkO2fsDaQ79RaqnEGUFBME3DcGqof/wFgGspfiXAbWBAFskgNnOIVj+QABAALH8+gtrY8JX0yK1ohnhfT+Y8fCl65DyCjqICQ9+sLo/MMf9hc0Nw2ulf/9Rsul/WL0LDwsG1DxAEAAEEMtf2IIFFiZoK4oRnoT+MyCKAEb0hsh/WDPpP3ytPyOSy1AdB0nfEJ/AWwoMSF0TeIMFudnDyEAYAAQQy09YL/P3f+jxU4zIBjFCAwe+h4IRPhwLCeZ/0PwALQRhWRleiv+FNRDhNdR/2Jri/wwoHkB2PQMR5Q8EAAQQy294wwZyoCtsNyMTpGT4i6jO4BU2JKEzYqwSQcxXMyBCmgE5nyAtHUB2OtxjDEgiRAKAAGL5DaspICSkMciMuoiREWm9CCOsqvoPG55gQCr4/qE5AlZAwRvq8LYW3Bv/MNxLZNhDAECAAQDQyZH7IItOogAAAABJRU5ErkJggg==";const{THREE:T}=I;var R,G,U={distributions:{BOX:1,SPHERE:2,DISC:3,LINE:4},valueOverLifetimeLength:4};U.TypedArrayHelper=function(e,t,r,i){this.componentSize=r||1,this.size=t||1,this.TypedArrayConstructor=e||Float32Array,this.array=new e(t*this.componentSize),this.indexOffset=i||0},U.TypedArrayHelper.constructor=U.TypedArrayHelper,U.TypedArrayHelper.prototype.setSize=function(e,t){var r=this.array.length;return t||(e*=this.componentSize),e<r?this.shrink(e):e>r?this.grow(e):void console.info("TypedArray is already of size:",e+".","Will not resize.")},U.TypedArrayHelper.prototype.shrink=function(e){return this.array=this.array.subarray(0,e),this.size=e,this},U.TypedArrayHelper.prototype.grow=function(e){var t=this.array,r=new this.TypedArrayConstructor(e);return r.set(t),this.array=r,this.size=e,this},U.TypedArrayHelper.prototype.splice=function(e,t){e*=this.componentSize,t*=this.componentSize;for(var r=[],i=this.array,n=i.length,a=0;a<n;++a)(a<e||a>=t)&&r.push(i[a]);return this.setFromArray(0,r),this},U.TypedArrayHelper.prototype.setFromArray=function(e,t){var r=e+t.length;return r>this.array.length?this.grow(r):r<this.array.length&&this.shrink(r),this.array.set(t,this.indexOffset+e),this},U.TypedArrayHelper.prototype.setVec2=function(e,t){return this.setVec2Components(e,t.x,t.y)},U.TypedArrayHelper.prototype.setVec2Components=function(e,t,r){var i=this.array,n=this.indexOffset+e*this.componentSize;return i[n]=t,i[n+1]=r,this},U.TypedArrayHelper.prototype.setVec3=function(e,t){return this.setVec3Components(e,t.x,t.y,t.z)},U.TypedArrayHelper.prototype.setVec3Components=function(e,t,r,i){var n=this.array,a=this.indexOffset+e*this.componentSize;return n[a]=t,n[a+1]=r,n[a+2]=i,this},U.TypedArrayHelper.prototype.setVec4=function(e,t){return this.setVec4Components(e,t.x,t.y,t.z,t.w)},U.TypedArrayHelper.prototype.setVec4Components=function(e,t,r,i,n){var a=this.array,s=this.indexOffset+e*this.componentSize;return a[s]=t,a[s+1]=r,a[s+2]=i,a[s+3]=n,this},U.TypedArrayHelper.prototype.setMat3=function(e,t){return this.setFromArray(this.indexOffset+e*this.componentSize,t.elements)},U.TypedArrayHelper.prototype.setMat4=function(e,t){return this.setFromArray(this.indexOffset+e*this.componentSize,t.elements)},U.TypedArrayHelper.prototype.setColor=function(e,t){return this.setVec3Components(e,t.r,t.g,t.b)},U.TypedArrayHelper.prototype.setNumber=function(e,t){return this.array[this.indexOffset+e*this.componentSize]=t,this},U.TypedArrayHelper.prototype.getValueAtIndex=function(e){return this.array[this.indexOffset+e]},U.TypedArrayHelper.prototype.getComponentValueAtIndex=function(e){return this.array.subarray(this.indexOffset+e*this.componentSize)},U.ShaderAttribute=function(e,t,r){var i=U.ShaderAttribute.typeSizeMap;this.type="string"==typeof e&&i.hasOwnProperty(e)?e:"f",this.componentSize=i[this.type],this.arrayType=r||Float32Array,this.typedArray=null,this.bufferAttribute=null,this.dynamicBuffer=!!t,this.updateMin=0,this.updateMax=0},U.ShaderAttribute.constructor=U.ShaderAttribute,U.ShaderAttribute.typeSizeMap={f:1,v2:2,v3:3,v4:4,c:3,m3:9,m4:16},U.ShaderAttribute.prototype.setUpdateRange=function(e,t){this.updateMin=Math.min(e*this.componentSize,this.updateMin*this.componentSize),this.updateMax=Math.max(t*this.componentSize,this.updateMax*this.componentSize)},U.ShaderAttribute.prototype.flagUpdate=function(){var e=this.bufferAttribute,t=e.updateRange;t.offset=this.updateMin,t.count=Math.min(this.updateMax-this.updateMin+this.componentSize,this.typedArray.array.length),e.needsUpdate=!0},U.ShaderAttribute.prototype.resetUpdateRange=function(){this.updateMin=0,this.updateMax=0},U.ShaderAttribute.prototype.resetDynamic=function(){this.bufferAttribute.usage=this.dynamicBuffer?T.DynamicDrawUsage:T.StaticDrawUsage},U.ShaderAttribute.prototype.splice=function(e,t){this.typedArray.splice(e,t),this.forceUpdateAll()},U.ShaderAttribute.prototype.forceUpdateAll=function(){this.bufferAttribute.array=this.typedArray.array,this.bufferAttribute.updateRange.offset=0,this.bufferAttribute.updateRange.count=-1,this.bufferAttribute.usage=T.StaticDrawUsage,this.bufferAttribute.needsUpdate=!0},U.ShaderAttribute.prototype._ensureTypedArray=function(e){null!==this.typedArray&&this.typedArray.size===e*this.componentSize||(null!==this.typedArray&&this.typedArray.size!==e?this.typedArray.setSize(e):null===this.typedArray&&(this.typedArray=new U.TypedArrayHelper(this.arrayType,e,this.componentSize)))},U.ShaderAttribute.prototype._createBufferAttribute=function(e){if(this._ensureTypedArray(e),null!==this.bufferAttribute)return this.bufferAttribute.array=this.typedArray.array,parseFloat(T.REVISION)>=81&&(this.bufferAttribute.count=this.bufferAttribute.array.length/this.bufferAttribute.itemSize),void(this.bufferAttribute.needsUpdate=!0);this.bufferAttribute=new T.BufferAttribute(this.typedArray.array,this.componentSize),this.bufferAttribute.usage=this.dynamicBuffer?T.DynamicDrawUsage:T.StaticDrawUsage},U.ShaderAttribute.prototype.getLength=function(){return null===this.typedArray?0:this.typedArray.array.length},U.shaderChunks={defines:["#define PACKED_COLOR_SIZE 256.0","#define PACKED_COLOR_DIVISOR 255.0"].join("\n"),uniforms:["uniform float deltaTime;","uniform float runTime;","uniform sampler2D tex;","uniform vec4 textureAnimation;","uniform float scale;"].join("\n"),attributes:["attribute vec4 acceleration;","attribute vec3 velocity;","attribute vec4 rotation;","attribute vec3 rotationCenter;","attribute vec4 params;","attribute vec4 size;","attribute vec4 angle;","attribute vec4 color;","attribute vec4 opacity;"].join("\n"),varyings:["varying vec4 vColor;","#ifdef SHOULD_ROTATE_TEXTURE"," varying float vAngle;","#endif","#ifdef SHOULD_CALCULATE_SPRITE"," varying vec4 vSpriteSheet;","#endif"].join("\n"),branchAvoidanceFunctions:["float when_gt(float x, float y) {"," return max(sign(x - y), 0.0);","}","float when_lt(float x, float y) {"," return min( max(1.0 - sign(x - y), 0.0), 1.0 );","}","float when_eq( float x, float y ) {"," return 1.0 - abs( sign( x - y ) );","}","float when_ge(float x, float y) {"," return 1.0 - when_lt(x, y);","}","float when_le(float x, float y) {"," return 1.0 - when_gt(x, y);","}","float and(float a, float b) {"," return a * b;","}","float or(float a, float b) {"," return min(a + b, 1.0);","}"].join("\n"),unpackColor:["vec3 unpackColor( in float hex ) {"," vec3 c = vec3( 0.0 );"," float r = mod( (hex / PACKED_COLOR_SIZE / PACKED_COLOR_SIZE), PACKED_COLOR_SIZE );"," float g = mod( (hex / PACKED_COLOR_SIZE), PACKED_COLOR_SIZE );"," float b = mod( hex, PACKED_COLOR_SIZE );"," c.r = r / PACKED_COLOR_DIVISOR;"," c.g = g / PACKED_COLOR_DIVISOR;"," c.b = b / PACKED_COLOR_DIVISOR;"," return c;","}"].join("\n"),unpackRotationAxis:["vec3 unpackRotationAxis( in float hex ) {"," vec3 c = vec3( 0.0 );"," float r = mod( (hex / PACKED_COLOR_SIZE / PACKED_COLOR_SIZE), PACKED_COLOR_SIZE );"," float g = mod( (hex / PACKED_COLOR_SIZE), PACKED_COLOR_SIZE );"," float b = mod( hex, PACKED_COLOR_SIZE );"," c.r = r / PACKED_COLOR_DIVISOR;"," c.g = g / PACKED_COLOR_DIVISOR;"," c.b = b / PACKED_COLOR_DIVISOR;"," c *= vec3( 2.0 );"," c -= vec3( 1.0 );"," return c;","}"].join("\n"),floatOverLifetime:["float getFloatOverLifetime( in float positionInTime, in vec4 attr ) {"," highp float value = 0.0;"," float deltaAge = positionInTime * float( VALUE_OVER_LIFETIME_LENGTH - 1 );"," float fIndex = 0.0;"," float shouldApplyValue = 0.0;"," value += attr[ 0 ] * when_eq( deltaAge, 0.0 );",""," for( int i = 0; i < VALUE_OVER_LIFETIME_LENGTH - 1; ++i ) {"," fIndex = float( i );"," shouldApplyValue = and( when_gt( deltaAge, fIndex ), when_le( deltaAge, fIndex + 1.0 ) );"," value += shouldApplyValue * mix( attr[ i ], attr[ i + 1 ], deltaAge - fIndex );"," }",""," return value;","}"].join("\n"),colorOverLifetime:["vec3 getColorOverLifetime( in float positionInTime, in vec3 color1, in vec3 color2, in vec3 color3, in vec3 color4 ) {"," vec3 value = vec3( 0.0 );"," value.x = getFloatOverLifetime( positionInTime, vec4( color1.x, color2.x, color3.x, color4.x ) );"," value.y = getFloatOverLifetime( positionInTime, vec4( color1.y, color2.y, color3.y, color4.y ) );"," value.z = getFloatOverLifetime( positionInTime, vec4( color1.z, color2.z, color3.z, color4.z ) );"," return value;","}"].join("\n"),paramFetchingFunctions:["float getAlive() {"," return params.x;","}","float getAge() {"," return params.y;","}","float getMaxAge() {"," return params.z;","}","float getWiggle() {"," return params.w;","}"].join("\n"),forceFetchingFunctions:["vec4 getPosition( in float age ) {"," return modelViewMatrix * vec4( position, 1.0 );","}","vec3 getVelocity( in float age ) {"," return velocity * age;","}","vec3 getAcceleration( in float age ) {"," return acceleration.xyz * age;","}"].join("\n"),rotationFunctions:["#ifdef SHOULD_ROTATE_PARTICLES"," mat4 getRotationMatrix( in vec3 axis, in float angle) {"," axis = normalize(axis);"," float s = sin(angle);"," float c = cos(angle);"," float oc = 1.0 - c;",""," return mat4(oc * axis.x * axis.x + c, oc * axis.x * axis.y - axis.z * s, oc * axis.z * axis.x + axis.y * s, 0.0,"," oc * axis.x * axis.y + axis.z * s, oc * axis.y * axis.y + c, oc * axis.y * axis.z - axis.x * s, 0.0,"," oc * axis.z * axis.x - axis.y * s, oc * axis.y * axis.z + axis.x * s, oc * axis.z * axis.z + c, 0.0,"," 0.0, 0.0, 0.0, 1.0);"," }",""," vec3 getRotation( in vec3 pos, in float positionInTime ) {"," if( rotation.y == 0.0 ) {"," return pos;"," }",""," vec3 axis = unpackRotationAxis( rotation.x );"," vec3 center = rotationCenter;"," vec3 translated;"," mat4 rotationMatrix;"," float angle = 0.0;"," angle += when_eq( rotation.z, 0.0 ) * rotation.y;"," angle += when_gt( rotation.z, 0.0 ) * mix( 0.0, rotation.y, positionInTime );"," translated = rotationCenter - pos;"," rotationMatrix = getRotationMatrix( axis, angle );"," return center - vec3( rotationMatrix * vec4( translated, 0.0 ) );"," }","#endif"].join("\n"),rotateTexture:[" vec2 vUv = vec2( gl_PointCoord.x, 1.0 - gl_PointCoord.y );",""," #ifdef SHOULD_ROTATE_TEXTURE"," float x = gl_PointCoord.x - 0.5;"," float y = 1.0 - gl_PointCoord.y - 0.5;"," float c = cos( -vAngle );"," float s = sin( -vAngle );"," vUv = vec2( c * x + s * y + 0.5, c * y - s * x + 0.5 );"," #endif",""," #ifdef SHOULD_CALCULATE_SPRITE"," float framesX = vSpriteSheet.x;"," float framesY = vSpriteSheet.y;"," float columnNorm = vSpriteSheet.z;"," float rowNorm = vSpriteSheet.w;"," vUv.x = gl_PointCoord.x * framesX + columnNorm;"," vUv.y = 1.0 - (gl_PointCoord.y * framesY + rowNorm);"," #endif",""," vec4 rotatedTexture = texture2D( tex, vUv );"].join("\n")},U.shaders={vertex:[U.shaderChunks.defines,U.shaderChunks.uniforms,U.shaderChunks.attributes,U.shaderChunks.varyings,T.ShaderChunk.common,T.ShaderChunk.logdepthbuf_pars_vertex,T.ShaderChunk.fog_pars_vertex,U.shaderChunks.branchAvoidanceFunctions,U.shaderChunks.unpackColor,U.shaderChunks.unpackRotationAxis,U.shaderChunks.floatOverLifetime,U.shaderChunks.colorOverLifetime,U.shaderChunks.paramFetchingFunctions,U.shaderChunks.forceFetchingFunctions,U.shaderChunks.rotationFunctions,"void main() {"," highp float age = getAge();"," highp float alive = getAlive();"," highp float maxAge = getMaxAge();"," highp float positionInTime = (age / maxAge);"," highp float isAlive = when_gt( alive, 0.0 );"," #ifdef SHOULD_WIGGLE_PARTICLES"," float wiggleAmount = positionInTime * getWiggle();"," float wiggleSin = isAlive * sin( wiggleAmount );"," float wiggleCos = isAlive * cos( wiggleAmount );"," #endif"," vec3 vel = getVelocity( age );"," vec3 accel = getAcceleration( age );"," vec3 force = vec3( 0.0 );"," vec3 pos = vec3( position );"," float drag = 1.0 - (positionInTime * 0.5) * acceleration.w;"," force += vel;"," force *= drag;"," force += accel * age;"," pos += force;"," #ifdef SHOULD_WIGGLE_PARTICLES"," pos.x += wiggleSin;"," pos.y += wiggleCos;"," pos.z += wiggleSin;"," #endif"," #ifdef SHOULD_ROTATE_PARTICLES"," pos = getRotation( pos, positionInTime );"," #endif"," vec4 mvPosition = modelViewMatrix * vec4( pos, 1.0 );"," highp float pointSize = getFloatOverLifetime( positionInTime, size ) * isAlive;"," #ifdef HAS_PERSPECTIVE"," float perspective = scale / length( mvPosition.xyz );"," #else"," float perspective = 1.0;"," #endif"," float pointSizePerspective = pointSize * perspective;"," #ifdef COLORIZE"," vec3 c = isAlive * getColorOverLifetime("," positionInTime,"," unpackColor( color.x ),"," unpackColor( color.y ),"," unpackColor( color.z ),"," unpackColor( color.w )"," );"," #else"," vec3 c = vec3(1.0);"," #endif"," float o = isAlive * getFloatOverLifetime( positionInTime, opacity );"," vColor = vec4( c, o );"," #ifdef SHOULD_ROTATE_TEXTURE"," vAngle = isAlive * getFloatOverLifetime( positionInTime, angle );"," #endif"," #ifdef SHOULD_CALCULATE_SPRITE"," float framesX = textureAnimation.x;"," float framesY = textureAnimation.y;"," float loopCount = textureAnimation.w;"," float totalFrames = textureAnimation.z;"," float frameNumber = mod( (positionInTime * loopCount) * totalFrames, totalFrames );"," float column = floor(mod( frameNumber, framesX ));"," float row = floor( (frameNumber - column) / framesX );"," float columnNorm = column / framesX;"," float rowNorm = row / framesY;"," vSpriteSheet.x = 1.0 / framesX;"," vSpriteSheet.y = 1.0 / framesY;"," vSpriteSheet.z = columnNorm;"," vSpriteSheet.w = rowNorm;"," #endif"," gl_PointSize = pointSizePerspective;"," gl_Position = projectionMatrix * mvPosition;",T.ShaderChunk.logdepthbuf_vertex,T.ShaderChunk.fog_vertex,"}"].join("\n"),fragment:[U.shaderChunks.uniforms,T.ShaderChunk.common,T.ShaderChunk.fog_pars_fragment,T.ShaderChunk.logdepthbuf_pars_fragment,U.shaderChunks.varyings,U.shaderChunks.branchAvoidanceFunctions,"void main() {"," vec3 outgoingLight = vColor.xyz;"," "," #ifdef ALPHATEST"," if ( vColor.w < float(ALPHATEST) ) discard;"," #endif",U.shaderChunks.rotateTexture,T.ShaderChunk.logdepthbuf_fragment," outgoingLight = vColor.xyz * rotatedTexture.xyz;"," gl_FragColor = vec4( outgoingLight.xyz, rotatedTexture.w * vColor.w );",T.ShaderChunk.fog_fragment,"}"].join("\n")},U.utils={types:{BOOLEAN:"boolean",STRING:"string",NUMBER:"number",OBJECT:"object"},ensureTypedArg:function(e,t,r){return typeof e===t?e:r},ensureArrayTypedArg:function(e,t,r){if(Array.isArray(e)){for(var i=e.length-1;i>=0;--i)if(typeof e[i]!==t)return r;return e}return this.ensureTypedArg(e,t,r)},ensureInstanceOf:function(e,t,r){return void 0!==t&&e instanceof t?e:r},ensureArrayInstanceOf:function(e,t,r){if(Array.isArray(e)){for(var i=e.length-1;i>=0;--i)if(void 0!==t&&e[i]instanceof t==!1)return r;return e}return this.ensureInstanceOf(e,t,r)},ensureValueOverLifetimeCompliance:function(e,t,r){t=t||3,r=r||3,!1===Array.isArray(e._value)&&(e._value=[e._value]),!1===Array.isArray(e._spread)&&(e._spread=[e._spread]);var i=this.clamp(e._value.length,t,r),n=this.clamp(e._spread.length,t,r),a=Math.max(i,n);e._value.length!==a&&(e._value=this.interpolateArray(e._value,a)),e._spread.length!==a&&(e._spread=this.interpolateArray(e._spread,a))},interpolateArray:function(e,t){for(var r=e.length,i=["function"==typeof e[0].clone?e[0].clone():e[0]],n=(r-1)/(t-1),a=1;a<t-1;++a){var s=a*n,o=Math.floor(s),l=Math.ceil(s),u=s-o;i[a]=this.lerpTypeAgnostic(e[o],e[l],u)}return i.push("function"==typeof e[r-1].clone?e[r-1].clone():e[r-1]),i},clamp:function(e,t,r){return Math.max(t,Math.min(e,r))},zeroToEpsilon:function(e,t){var r=1e-5,i=e;return i=t?Math.random()*r*10:r,e<0&&e>-1e-5&&(i=-i),i},lerpTypeAgnostic:function(e,t,r){var i,n=this.types;return typeof e===n.NUMBER&&typeof t===n.NUMBER?e+(t-e)*r:e instanceof T.Vector2&&t instanceof T.Vector2?((i=e.clone()).x=this.lerp(e.x,t.x,r),i.y=this.lerp(e.y,t.y,r),i):e instanceof T.Vector3&&t instanceof T.Vector3?((i=e.clone()).x=this.lerp(e.x,t.x,r),i.y=this.lerp(e.y,t.y,r),i.z=this.lerp(e.z,t.z,r),i):e instanceof T.Vector4&&t instanceof T.Vector4?((i=e.clone()).x=this.lerp(e.x,t.x,r),i.y=this.lerp(e.y,t.y,r),i.z=this.lerp(e.z,t.z,r),i.w=this.lerp(e.w,t.w,r),i):e instanceof T.Color&&t instanceof T.Color?((i=e.clone()).r=this.lerp(e.r,t.r,r),i.g=this.lerp(e.g,t.g,r),i.b=this.lerp(e.b,t.b,r),i):void console.warn("Invalid argument types, or argument types do not match:",e,t)},lerp:function(e,t,r){return e+(t-e)*r},roundToNearestMultiple:function(e,t){var r;return 0===t||0===(r=Math.abs(e)%t)?e:e<0?-(Math.abs(e)-r):e+t-r},arrayValuesAreEqual:function(e){for(var t=0;t<e.length-1;++t)if(e[t]!==e[t+1])return!1;return!0},randomFloat:function(e,t){return e+t*(Math.random()-.5)},randomVector3:function(e,t,r,i,n){var a=r.x+(Math.random()*i.x-.5*i.x),s=r.y+(Math.random()*i.y-.5*i.y),o=r.z+(Math.random()*i.z-.5*i.z);n&&(a=.5*-n.x+this.roundToNearestMultiple(a,n.x),s=.5*-n.y+this.roundToNearestMultiple(s,n.y),o=.5*-n.z+this.roundToNearestMultiple(o,n.z)),e.typedArray.setVec3Components(t,a,s,o)},randomColor:function(e,t,r,i){var n=r.r+Math.random()*i.x,a=r.g+Math.random()*i.y,s=r.b+Math.random()*i.z;n=this.clamp(n,0,1),a=this.clamp(a,0,1),s=this.clamp(s,0,1),e.typedArray.setVec3Components(t,n,a,s)},randomColorAsHex:(G=new T.Color,function(e,t,r,i){for(var n=r.length,a=[],s=0;s<n;++s){var o=i[s];G.copy(r[s]),G.r+=Math.random()*o.x-.5*o.x,G.g+=Math.random()*o.y-.5*o.y,G.b+=Math.random()*o.z-.5*o.z,G.r=this.clamp(G.r,0,1),G.g=this.clamp(G.g,0,1),G.b=this.clamp(G.b,0,1),a.push(G.getHex())}e.typedArray.setVec4Components(t,a[0],a[1],a[2],a[3])}),randomVector3OnLine:function(e,t,r,i){var n=r.clone();n.lerp(i,Math.random()),e.typedArray.setVec3Components(t,n.x,n.y,n.z)},randomVector3OnSphere:function(e,t,r,i,n,a,s,o){var l=2*Math.random()-1,u=6.2832*Math.random(),c=Math.sqrt(1-l*l),p=this.randomFloat(i,n),h=0,d=0,A=0;s&&(p=Math.round(p/s)*s),h=c*Math.cos(u)*p,d=c*Math.sin(u)*p,A=l*p,h*=a.x,d*=a.y,A*=a.z,h+=r.x,d+=r.y,A+=r.z,e.typedArray.setVec3Components(t,h,d,A)},seededRandom:function(e){var t=1e4*Math.sin(e);return t-(0|t)},randomVector3OnDisc:function(e,t,r,i,n,a,s){var o=6.2832*Math.random(),l=Math.abs(this.randomFloat(i,n)),u=0,c=0,p=0;s&&(l=Math.round(l/s)*s),u=Math.cos(o)*l,c=Math.sin(o)*l,u*=a.x,c*=a.y,u+=r.x,c+=r.y,p+=r.z,e.typedArray.setVec3Components(t,u,c,p)},randomDirectionVector3OnSphere:(R=new T.Vector3,function(e,t,r,i,n,a,s,o){R.copy(a),R.x-=r,R.y-=i,R.z-=n,R.normalize().multiplyScalar(-this.randomFloat(s,o)),e.typedArray.setVec3Components(t,R.x,R.y,R.z)}),randomDirectionVector3OnDisc:function(){var e=new T.Vector3;return function(t,r,i,n,a,s,o,l){e.copy(s),e.x-=i,e.y-=n,e.z-=a,e.normalize().multiplyScalar(-this.randomFloat(o,l)),t.typedArray.setVec3Components(r,e.x,e.y,0)}}(),getPackedRotationAxis:function(){var e=new T.Vector3,t=new T.Vector3,r=new T.Color,i=new T.Vector3(1,1,1);return function(n,a){return e.copy(n).normalize(),t.copy(a).normalize(),e.x+=.5*-a.x+Math.random()*a.x,e.y+=.5*-a.y+Math.random()*a.y,e.z+=.5*-a.z+Math.random()*a.z,e.normalize().add(i).multiplyScalar(.5),r.setRGB(e.x,e.y,e.z),r.getHex()}}()},U.Group=function(e){var t=U.utils,r=t.types;(e=t.ensureTypedArg(e,r.OBJECT,{})).texture=t.ensureTypedArg(e.texture,r.OBJECT,{}),this.uuid=T.MathUtils.generateUUID(),this.fixedTimeStep=t.ensureTypedArg(e.fixedTimeStep,r.NUMBER,.016),this.texture=t.ensureInstanceOf(e.texture.value,T.Texture,null),this.textureFrames=t.ensureInstanceOf(e.texture.frames,T.Vector2,new T.Vector2(1,1)),this.textureFrameCount=t.ensureTypedArg(e.texture.frameCount,r.NUMBER,this.textureFrames.x*this.textureFrames.y),this.textureLoop=t.ensureTypedArg(e.texture.loop,r.NUMBER,1),this.textureFrames.max(new T.Vector2(1,1)),this.hasPerspective=t.ensureTypedArg(e.hasPerspective,r.BOOLEAN,!0),this.colorize=t.ensureTypedArg(e.colorize,r.BOOLEAN,!0),this.maxParticleCount=t.ensureTypedArg(e.maxParticleCount,r.NUMBER,null),this.blending=t.ensureTypedArg(e.blending,r.NUMBER,T.AdditiveBlending),this.transparent=t.ensureTypedArg(e.transparent,r.BOOLEAN,!0),this.alphaTest=parseFloat(t.ensureTypedArg(e.alphaTest,r.NUMBER,0)),this.depthWrite=t.ensureTypedArg(e.depthWrite,r.BOOLEAN,!1),this.depthTest=t.ensureTypedArg(e.depthTest,r.BOOLEAN,!0),this.fog=t.ensureTypedArg(e.fog,r.BOOLEAN,!0),this.scale=t.ensureTypedArg(e.scale,r.NUMBER,300),this.emitters=[],this.emitterIDs=[],this._pool=[],this._poolCreationSettings=null,this._createNewWhenPoolEmpty=0,this._attributesNeedRefresh=!1,this._attributesNeedDynamicReset=!1,this.particleCount=0,this.uniforms={tex:{type:"t",value:this.texture},textureAnimation:{type:"v4",value:new T.Vector4(this.textureFrames.x,this.textureFrames.y,this.textureFrameCount,Math.max(Math.abs(this.textureLoop),1))},fogColor:{type:"c",value:this.fog?new T.Color:null},fogNear:{type:"f",value:10},fogFar:{type:"f",value:200},fogDensity:{type:"f",value:.5},deltaTime:{type:"f",value:0},runTime:{type:"f",value:0},scale:{type:"f",value:this.scale}},this.defines={HAS_PERSPECTIVE:this.hasPerspective,COLORIZE:this.colorize,VALUE_OVER_LIFETIME_LENGTH:U.valueOverLifetimeLength,SHOULD_ROTATE_TEXTURE:!1,SHOULD_ROTATE_PARTICLES:!1,SHOULD_WIGGLE_PARTICLES:!1,SHOULD_CALCULATE_SPRITE:this.textureFrames.x>1||this.textureFrames.y>1},this.attributes={position:new U.ShaderAttribute("v3",!0),acceleration:new U.ShaderAttribute("v4",!0),velocity:new U.ShaderAttribute("v3",!0),rotation:new U.ShaderAttribute("v4",!0),rotationCenter:new U.ShaderAttribute("v3",!0),params:new U.ShaderAttribute("v4",!0),size:new U.ShaderAttribute("v4",!0),angle:new U.ShaderAttribute("v4",!0),color:new U.ShaderAttribute("v4",!0),opacity:new U.ShaderAttribute("v4",!0)},this.attributeKeys=Object.keys(this.attributes),this.attributeCount=this.attributeKeys.length,this.material=new T.ShaderMaterial({uniforms:this.uniforms,vertexShader:U.shaders.vertex,fragmentShader:U.shaders.fragment,blending:this.blending,transparent:this.transparent,alphaTest:this.alphaTest,depthWrite:this.depthWrite,depthTest:this.depthTest,defines:this.defines,fog:this.fog}),this.geometry=new T.BufferGeometry,this.mesh=new T.Points(this.geometry,this.material),null===this.maxParticleCount&&console.warn("SPE.Group: No maxParticleCount specified. Adding emitters after rendering will probably cause errors.")},U.Group.constructor=U.Group,U.Group.prototype._updateDefines=function(){for(var e,t=this.emitters,r=t.length-1,i=this.defines;r>=0;--r)e=t[r],i.SHOULD_CALCULATE_SPRITE||(i.SHOULD_ROTATE_TEXTURE=i.SHOULD_ROTATE_TEXTURE||!!Math.max(Math.max.apply(null,e.angle.value),Math.max.apply(null,e.angle.spread))),i.SHOULD_ROTATE_PARTICLES=i.SHOULD_ROTATE_PARTICLES||!!Math.max(e.rotation.angle,e.rotation.angleSpread),i.SHOULD_WIGGLE_PARTICLES=i.SHOULD_WIGGLE_PARTICLES||!!Math.max(e.wiggle.value,e.wiggle.spread);this.material.needsUpdate=!0},U.Group.prototype._applyAttributesToGeometry=function(){var e,t,r=this.attributes,i=this.geometry,n=i.attributes;for(var a in r)r.hasOwnProperty(a)&&(e=r[a],(t=n[a])?t.array=e.typedArray.array:i.setAttribute(a,e.bufferAttribute),e.bufferAttribute.needsUpdate=!0);this.geometry.setDrawRange(0,this.particleCount)},U.Group.prototype.addEmitter=function(e){if(e instanceof U.Emitter!=!1)if(this.emitterIDs.indexOf(e.uuid)>-1)console.error("Emitter already exists in this group. Will not add again.");else{if(null===e.group){var t=this.attributes,r=this.particleCount,i=r+e.particleCount;for(var n in this.particleCount=i,null!==this.maxParticleCount&&this.particleCount>this.maxParticleCount&&console.warn("SPE.Group: maxParticleCount exceeded. Requesting",this.particleCount,"particles, can support only",this.maxParticleCount),e._calculatePPSValue(e.maxAge._value+e.maxAge._spread),e._setBufferUpdateRanges(this.attributeKeys),e._setAttributeOffset(r),e.group=this,e.attributes=this.attributes,t)t.hasOwnProperty(n)&&t[n]._createBufferAttribute(null!==this.maxParticleCount?this.maxParticleCount:this.particleCount);for(var a=r;a<i;++a)e._assignPositionValue(a),e._assignForceValue(a,"velocity"),e._assignForceValue(a,"acceleration"),e._assignAbsLifetimeValue(a,"opacity"),e._assignAbsLifetimeValue(a,"size"),e._assignAngleValue(a),e._assignRotationValue(a),e._assignParamsValue(a),e._assignColorValue(a);return this._applyAttributesToGeometry(),this.emitters.push(e),this.emitterIDs.push(e.uuid),this._updateDefines(e),this.material.needsUpdate=!0,this.geometry.needsUpdate=!0,this._attributesNeedRefresh=!0,this}console.error("Emitter already belongs to another group. Will not add to requested group.")}else console.error("`emitter` argument must be instance of SPE.Emitter. Was provided with:",e)},U.Group.prototype.removeEmitter=function(e){var t=this.emitterIDs.indexOf(e.uuid);if(e instanceof U.Emitter!=!1)if(-1!==t){for(var r=e.attributeOffset,i=r+e.particleCount,n=this.attributes.params.typedArray,a=r;a<i;++a)n.array[4*a]=0,n.array[4*a+1]=0;for(var s in this.emitters.splice(t,1),this.emitterIDs.splice(t,1),this.attributes)this.attributes.hasOwnProperty(s)&&this.attributes[s].splice(r,i);this.particleCount-=e.particleCount,e._onRemove(),this._attributesNeedRefresh=!0}else console.error("Emitter does not exist in this group. Will not remove.");else console.error("`emitter` argument must be instance of SPE.Emitter. Was provided with:",e)},U.Group.prototype.getFromPool=function(){var e=this._pool,t=this._createNewWhenPoolEmpty;if(e.length)return e.pop();if(t){var r=new U.Emitter(this._poolCreationSettings);return this.addEmitter(r),r}return null},U.Group.prototype.releaseIntoPool=function(e){if(e instanceof U.Emitter!=!1)return e.reset(),this._pool.unshift(e),this;console.error("Argument is not instanceof SPE.Emitter:",e)},U.Group.prototype.getPool=function(){return this._pool},U.Group.prototype.addPool=function(e,t,r){var i;this._poolCreationSettings=t,this._createNewWhenPoolEmpty=!!r;for(var n=0;n<e;++n)i=Array.isArray(t)?new U.Emitter(t[n]):new U.Emitter(t),this.addEmitter(i),this.releaseIntoPool(i);return this},U.Group.prototype._triggerSingleEmitter=function(e){var t=this.getFromPool(),r=this;if(null!==t)return e instanceof T.Vector3&&(t.position.value.copy(e),t.position.value=t.position.value),t.enable(),setTimeout((function(){t.disable(),r.releaseIntoPool(t)}),1e3*Math.max(t.duration,t.maxAge.value+t.maxAge.spread)),this;console.log("SPE.Group pool ran out.")},U.Group.prototype.triggerPoolEmitter=function(e,t){if("number"==typeof e&&e>1)for(var r=0;r<e;++r)this._triggerSingleEmitter(t);else this._triggerSingleEmitter(t);return this},U.Group.prototype._updateUniforms=function(e){this.uniforms.runTime.value+=e,this.uniforms.deltaTime.value=e},U.Group.prototype._resetBufferRanges=function(){for(var e=this.attributeKeys,t=this.attributeCount-1,r=this.attributes;t>=0;--t)r[e[t]].resetUpdateRange()},U.Group.prototype._updateBuffers=function(e){for(var t,r,i,n=this.attributeKeys,a=this.attributeCount-1,s=this.attributes,o=e.bufferUpdateRanges;a>=0;--a)r=o[t=n[a]],(i=s[t]).setUpdateRange(r.min,r.max),i.flagUpdate()},U.Group.prototype.tick=function(e){var t=this.emitters,r=t.length,i=e||this.fixedTimeStep,n=this.attributeKeys,a=this.attributes;if(this._updateUniforms(i),this._resetBufferRanges(),0!==r||!1!==this._attributesNeedRefresh||!1!==this._attributesNeedDynamicReset){for(var s,o=0;o<r;++o)(s=t[o]).tick(i),this._updateBuffers(s);if(!0===this._attributesNeedDynamicReset){for(o=this.attributeCount-1;o>=0;--o)a[n[o]].resetDynamic();this._attributesNeedDynamicReset=!1}if(!0===this._attributesNeedRefresh){for(o=this.attributeCount-1;o>=0;--o)a[n[o]].forceUpdateAll();this._attributesNeedRefresh=!1,this._attributesNeedDynamicReset=!0}}},U.Group.prototype.dispose=function(){return this.geometry.dispose(),this.material.dispose(),this},U.Emitter=function(e){var t=U.utils,r=t.types,i=U.valueOverLifetimeLength;for(var n in(e=t.ensureTypedArg(e,r.OBJECT,{})).position=t.ensureTypedArg(e.position,r.OBJECT,{}),e.velocity=t.ensureTypedArg(e.velocity,r.OBJECT,{}),e.acceleration=t.ensureTypedArg(e.acceleration,r.OBJECT,{}),e.radius=t.ensureTypedArg(e.radius,r.OBJECT,{}),e.drag=t.ensureTypedArg(e.drag,r.OBJECT,{}),e.rotation=t.ensureTypedArg(e.rotation,r.OBJECT,{}),e.color=t.ensureTypedArg(e.color,r.OBJECT,{}),e.opacity=t.ensureTypedArg(e.opacity,r.OBJECT,{}),e.size=t.ensureTypedArg(e.size,r.OBJECT,{}),e.angle=t.ensureTypedArg(e.angle,r.OBJECT,{}),e.wiggle=t.ensureTypedArg(e.wiggle,r.OBJECT,{}),e.maxAge=t.ensureTypedArg(e.maxAge,r.OBJECT,{}),e.onParticleSpawn&&console.warn("onParticleSpawn has been removed. Please set properties directly to alter values at runtime."),this.uuid=T.MathUtils.generateUUID(),this.type=t.ensureTypedArg(e.type,r.NUMBER,U.distributions.BOX),this.position={_value:t.ensureInstanceOf(e.position.value,T.Vector3,new T.Vector3),_spread:t.ensureInstanceOf(e.position.spread,T.Vector3,new T.Vector3),_spreadClamp:t.ensureInstanceOf(e.position.spreadClamp,T.Vector3,new T.Vector3),_distribution:t.ensureTypedArg(e.position.distribution,r.NUMBER,this.type),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1),_radius:t.ensureTypedArg(e.position.radius,r.NUMBER,10),_radiusScale:t.ensureInstanceOf(e.position.radiusScale,T.Vector3,new T.Vector3(1,1,1)),_distributionClamp:t.ensureTypedArg(e.position.distributionClamp,r.NUMBER,0)},this.velocity={_value:t.ensureInstanceOf(e.velocity.value,T.Vector3,new T.Vector3),_spread:t.ensureInstanceOf(e.velocity.spread,T.Vector3,new T.Vector3),_distribution:t.ensureTypedArg(e.velocity.distribution,r.NUMBER,this.type),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.acceleration={_value:t.ensureInstanceOf(e.acceleration.value,T.Vector3,new T.Vector3),_spread:t.ensureInstanceOf(e.acceleration.spread,T.Vector3,new T.Vector3),_distribution:t.ensureTypedArg(e.acceleration.distribution,r.NUMBER,this.type),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.drag={_value:t.ensureTypedArg(e.drag.value,r.NUMBER,0),_spread:t.ensureTypedArg(e.drag.spread,r.NUMBER,0),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.wiggle={_value:t.ensureTypedArg(e.wiggle.value,r.NUMBER,0),_spread:t.ensureTypedArg(e.wiggle.spread,r.NUMBER,0)},this.rotation={_axis:t.ensureInstanceOf(e.rotation.axis,T.Vector3,new T.Vector3(0,1,0)),_axisSpread:t.ensureInstanceOf(e.rotation.axisSpread,T.Vector3,new T.Vector3),_angle:t.ensureTypedArg(e.rotation.angle,r.NUMBER,0),_angleSpread:t.ensureTypedArg(e.rotation.angleSpread,r.NUMBER,0),_static:t.ensureTypedArg(e.rotation.static,r.BOOLEAN,!1),_center:t.ensureInstanceOf(e.rotation.center,T.Vector3,this.position._value.clone()),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.maxAge={_value:t.ensureTypedArg(e.maxAge.value,r.NUMBER,2),_spread:t.ensureTypedArg(e.maxAge.spread,r.NUMBER,0)},this.color={_value:t.ensureArrayInstanceOf(e.color.value,T.Color,new T.Color),_spread:t.ensureArrayInstanceOf(e.color.spread,T.Vector3,new T.Vector3),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.opacity={_value:t.ensureArrayTypedArg(e.opacity.value,r.NUMBER,1),_spread:t.ensureArrayTypedArg(e.opacity.spread,r.NUMBER,0),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.size={_value:t.ensureArrayTypedArg(e.size.value,r.NUMBER,1),_spread:t.ensureArrayTypedArg(e.size.spread,r.NUMBER,0),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.angle={_value:t.ensureArrayTypedArg(e.angle.value,r.NUMBER,0),_spread:t.ensureArrayTypedArg(e.angle.spread,r.NUMBER,0),_randomise:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)},this.particleCount=t.ensureTypedArg(e.particleCount,r.NUMBER,100),this.duration=t.ensureTypedArg(e.duration,r.NUMBER,null),this.isStatic=t.ensureTypedArg(e.isStatic,r.BOOLEAN,!1),this.activeMultiplier=t.ensureTypedArg(e.activeMultiplier,r.NUMBER,1),this.direction=t.ensureTypedArg(e.direction,r.NUMBER,1),this.alive=t.ensureTypedArg(e.alive,r.BOOLEAN,!0),this.particlesPerSecond=0,this.activationIndex=0,this.attributeOffset=0,this.attributeEnd=0,this.age=0,this.activeParticleCount=0,this.group=null,this.attributes=null,this.paramsArray=null,this.resetFlags={position:t.ensureTypedArg(e.position.randomise,r.BOOLEAN,!1)||t.ensureTypedArg(e.radius.randomise,r.BOOLEAN,!1),velocity:t.ensureTypedArg(e.velocity.randomise,r.BOOLEAN,!1),acceleration:t.ensureTypedArg(e.acceleration.randomise,r.BOOLEAN,!1)||t.ensureTypedArg(e.drag.randomise,r.BOOLEAN,!1),rotation:t.ensureTypedArg(e.rotation.randomise,r.BOOLEAN,!1),rotationCenter:t.ensureTypedArg(e.rotation.randomise,r.BOOLEAN,!1),size:t.ensureTypedArg(e.size.randomise,r.BOOLEAN,!1),color:t.ensureTypedArg(e.color.randomise,r.BOOLEAN,!1),opacity:t.ensureTypedArg(e.opacity.randomise,r.BOOLEAN,!1),angle:t.ensureTypedArg(e.angle.randomise,r.BOOLEAN,!1)},this.updateFlags={},this.updateCounts={},this.updateMap={maxAge:"params",position:"position",velocity:"velocity",acceleration:"acceleration",drag:"acceleration",wiggle:"params",rotation:"rotation",size:"size",color:"color",opacity:"opacity",angle:"angle"},this.updateMap)this.updateMap.hasOwnProperty(n)&&(this.updateCounts[this.updateMap[n]]=0,this.updateFlags[this.updateMap[n]]=!1,this._createGetterSetters(this[n],n));this.bufferUpdateRanges={},this.attributeKeys=null,this.attributeCount=0,t.ensureValueOverLifetimeCompliance(this.color,i,i),t.ensureValueOverLifetimeCompliance(this.opacity,i,i),t.ensureValueOverLifetimeCompliance(this.size,i,i),t.ensureValueOverLifetimeCompliance(this.angle,i,i)},U.Emitter.constructor=U.Emitter,U.Emitter.prototype._createGetterSetters=function(e,t){var r=this;for(var i in e)if(e.hasOwnProperty(i)){var n=i.replace("_","");Object.defineProperty(e,n,{get:function(e){return function(){return this[e]}}(i),set:function(e){return function(i){var n=r.updateMap[t],a=this[e],s=U.valueOverLifetimeLength;"_rotationCenter"===e?(r.updateFlags.rotationCenter=!0,r.updateCounts.rotationCenter=0):"_randomise"===e?r.resetFlags[n]=i:(r.updateFlags[n]=!0,r.updateCounts[n]=0),r.group._updateDefines(),this[e]=i,Array.isArray(a)&&U.utils.ensureValueOverLifetimeCompliance(r[t],s,s)}}(i)})}},U.Emitter.prototype._setBufferUpdateRanges=function(e){this.attributeKeys=e,this.attributeCount=e.length;for(var t=this.attributeCount-1;t>=0;--t)this.bufferUpdateRanges[e[t]]={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY}},U.Emitter.prototype._calculatePPSValue=function(e){var t=this.particleCount;this.duration?this.particlesPerSecond=t/(e<this.duration?e:this.duration):this.particlesPerSecond=t/e},U.Emitter.prototype._setAttributeOffset=function(e){this.attributeOffset=e,this.activationIndex=e,this.activationEnd=e+this.particleCount},U.Emitter.prototype._assignValue=function(e,t){switch(e){case"position":this._assignPositionValue(t);break;case"velocity":case"acceleration":this._assignForceValue(t,e);break;case"size":case"opacity":this._assignAbsLifetimeValue(t,e);break;case"angle":this._assignAngleValue(t);break;case"params":this._assignParamsValue(t);break;case"rotation":this._assignRotationValue(t);break;case"color":this._assignColorValue(t)}},U.Emitter.prototype._assignPositionValue=function(e){var t=U.distributions,r=U.utils,i=this.position,n=this.attributes.position,a=i._value,s=i._spread;switch(i._distribution){case t.BOX:r.randomVector3(n,e,a,s,i._spreadClamp);break;case t.SPHERE:r.randomVector3OnSphere(n,e,a,i._radius,i._spread.x,i._radiusScale,i._spreadClamp.x,i._distributionClamp||this.particleCount);break;case t.DISC:r.randomVector3OnDisc(n,e,a,i._radius,i._spread.x,i._radiusScale,i._spreadClamp.x);break;case t.LINE:r.randomVector3OnLine(n,e,a,s)}},U.Emitter.prototype._assignForceValue=function(e,t){var r,i,n,a,s,o=U.distributions,l=U.utils,u=this[t],c=u._value,p=u._spread;switch(u._distribution){case o.BOX:l.randomVector3(this.attributes[t],e,c,p);break;case o.SPHERE:i=(r=this.attributes.position.typedArray.array)[s=3*e],n=r[s+1],a=r[s+2],l.randomDirectionVector3OnSphere(this.attributes[t],e,i,n,a,this.position._value,u._value.x,u._spread.x);break;case o.DISC:i=(r=this.attributes.position.typedArray.array)[s=3*e],n=r[s+1],a=r[s+2],l.randomDirectionVector3OnDisc(this.attributes[t],e,i,n,a,this.position._value,u._value.x,u._spread.x);break;case o.LINE:l.randomVector3OnLine(this.attributes[t],e,c,p)}if("acceleration"===t){var h=l.clamp(l.randomFloat(this.drag._value,this.drag._spread),0,1);this.attributes.acceleration.typedArray.array[4*e+3]=h}},U.Emitter.prototype._assignAbsLifetimeValue=function(e,t){var r,i=this.attributes[t].typedArray,n=this[t],a=U.utils;a.arrayValuesAreEqual(n._value)&&a.arrayValuesAreEqual(n._spread)?(r=Math.abs(a.randomFloat(n._value[0],n._spread[0])),i.setVec4Components(e,r,r,r,r)):i.setVec4Components(e,Math.abs(a.randomFloat(n._value[0],n._spread[0])),Math.abs(a.randomFloat(n._value[1],n._spread[1])),Math.abs(a.randomFloat(n._value[2],n._spread[2])),Math.abs(a.randomFloat(n._value[3],n._spread[3])))},U.Emitter.prototype._assignAngleValue=function(e){var t,r=this.attributes.angle.typedArray,i=this.angle,n=U.utils;n.arrayValuesAreEqual(i._value)&&n.arrayValuesAreEqual(i._spread)?(t=n.randomFloat(i._value[0],i._spread[0]),r.setVec4Components(e,t,t,t,t)):r.setVec4Components(e,n.randomFloat(i._value[0],i._spread[0]),n.randomFloat(i._value[1],i._spread[1]),n.randomFloat(i._value[2],i._spread[2]),n.randomFloat(i._value[3],i._spread[3]))},U.Emitter.prototype._assignParamsValue=function(e){this.attributes.params.typedArray.setVec4Components(e,this.isStatic?1:0,0,Math.abs(U.utils.randomFloat(this.maxAge._value,this.maxAge._spread)),U.utils.randomFloat(this.wiggle._value,this.wiggle._spread))},U.Emitter.prototype._assignRotationValue=function(e){this.attributes.rotation.typedArray.setVec3Components(e,U.utils.getPackedRotationAxis(this.rotation._axis,this.rotation._axisSpread),U.utils.randomFloat(this.rotation._angle,this.rotation._angleSpread),this.rotation._static?0:1),this.attributes.rotationCenter.typedArray.setVec3(e,this.rotation._center)},U.Emitter.prototype._assignColorValue=function(e){U.utils.randomColorAsHex(this.attributes.color,e,this.color._value,this.color._spread)},U.Emitter.prototype._resetParticle=function(e){for(var t,r,i=this.resetFlags,n=this.updateFlags,a=this.updateCounts,s=this.attributeKeys,o=this.attributeCount-1;o>=0;--o)r=n[t=s[o]],!0!==i[t]&&!0!==r||(this._assignValue(t,e),this._updateAttributeUpdateRange(t,e),!0===r&&a[t]===this.particleCount?(n[t]=!1,a[t]=0):1==r&&++a[t])},U.Emitter.prototype._updateAttributeUpdateRange=function(e,t){var r=this.bufferUpdateRanges[e];r.min=Math.min(t,r.min),r.max=Math.max(t,r.max)},U.Emitter.prototype._resetBufferRanges=function(){for(var e,t=this.bufferUpdateRanges,r=this.bufferUpdateKeys,i=this.bufferUpdateCount-1;i>=0;--i)t[e=r[i]].min=Number.POSITIVE_INFINITY,t[e].max=Number.NEGATIVE_INFINITY},U.Emitter.prototype._onRemove=function(){this.particlesPerSecond=0,this.attributeOffset=0,this.activationIndex=0,this.activeParticleCount=0,this.group=null,this.attributes=null,this.paramsArray=null,this.age=0},U.Emitter.prototype._decrementParticleCount=function(){--this.activeParticleCount},U.Emitter.prototype._incrementParticleCount=function(){++this.activeParticleCount},U.Emitter.prototype._checkParticleAges=function(e,t,r,i){for(var n,a,s,o,l=t-1;l>=e;--l)0!==(o=r[n=4*l])&&(s=r[n+1],a=r[n+2],1===this.direction?(s+=i)>=a&&(s=0,o=0,this._decrementParticleCount()):(s-=i)<=0&&(s=a,o=0,this._decrementParticleCount()),r[n]=o,r[n+1]=s,this._updateAttributeUpdateRange("params",l))},U.Emitter.prototype._activateParticles=function(e,t,r,i){for(var n,a,s=this.direction,o=e;o<t;++o)0!=r[n=4*o]&&1!==this.particleCount||(this._incrementParticleCount(),r[n]=1,this._resetParticle(o),a=i*(o-e),r[n+1]=-1===s?r[n+2]-a:a,this._updateAttributeUpdateRange("params",o))},U.Emitter.prototype.tick=function(e){if(!this.isStatic){null===this.paramsArray&&(this.paramsArray=this.attributes.params.typedArray.array);var t=this.attributeOffset,r=t+this.particleCount,i=this.paramsArray,n=this.particlesPerSecond*this.activeMultiplier*e,a=this.activationIndex;if(this._resetBufferRanges(),this._checkParticleAges(t,r,i,e),!1!==this.alive){if(null!==this.duration&&this.age>this.duration)return this.alive=!1,void(this.age=0);var s=1===this.particleCount?a:0|a,o=Math.min(s+n,this.activationEnd),l=o-this.activationIndex|0,u=l>0?e/l:0;this._activateParticles(s,o,i,u),this.activationIndex+=n,this.activationIndex>r&&(this.activationIndex=t),this.age+=e}else this.age=0}},U.Emitter.prototype.reset=function(e){if(this.age=0,this.alive=!1,!0===e){for(var t,r=this.attributeOffset,i=r+this.particleCount,n=this.paramsArray,a=this.attributes.params.bufferAttribute,s=i-1;s>=r;--s)n[t=4*s]=0,n[t+1]=0;a.updateRange.offset=0,a.updateRange.count=-1,a.needsUpdate=!0}return this},U.Emitter.prototype.enable=function(){return this.alive=!0,this},U.Emitter.prototype.disable=function(){return this.alive=!1,this},U.Emitter.prototype.remove=function(){return null!==this.group?this.group.removeEmitter(this):console.error("Emitter does not belong to a group, cannot remove."),this};var L="data:image/png;base64,iVBORw0KGg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87Nk40vNEw0fc86IJB/C/hOTWY8yY1MAAAAABJRU5ErkJggg==",Q={vertexShader:"\n #include <common>\n #include <logdepthbuf_pars_vertex>\n uniform float pixelRatio;\n uniform float time;\n attribute float size; \n attribute float speed; \n attribute float opacity;\n attribute vec3 noise;\n attribute vec3 color;\n varying vec3 vColor;\n varying float vOpacity;\n void main() {\n vec4 modelPosition = modelMatrix * vec4(position, 1.0);\n modelPosition.y += sin(time * speed + modelPosition.x * noise.x * 100.0) * 0.2;\n modelPosition.z += cos(time * speed + modelPosition.x * noise.y * 100.0) * 0.2;\n modelPosition.x += cos(time * speed + modelPosition.x * noise.z * 100.0) * 0.2;\n vec4 viewPosition = viewMatrix * modelPosition;\n vec4 projectionPostion = projectionMatrix * viewPosition;\n gl_Position = projectionPostion;\n gl_PointSize = size * 25. * pixelRatio;\n gl_PointSize *= (1.0 / - viewPosition.z);\n vColor = color;\n vOpacity = opacity;\n\n\t #include <logdepthbuf_vertex>\n }",fragmentShader:"\n #include <common>\n #include <logdepthbuf_pars_fragment>\n varying vec3 vColor;\n varying float vOpacity;\n void main() {\n float distanceToCenter = distance(gl_PointCoord, vec2(0.5));\n float strength = 0.05 / distanceToCenter - 0.1;\n gl_FragColor = vec4(vColor, strength * vOpacity);\n #include <tonemapping_fragment>\n #include <encodings_fragment>\n #include <logdepthbuf_fragment>\n }"};const N=e=>e&&e.constructor===Float32Array,F=e=>void 0!==(null==e?void 0:e.x)&&void 0!==(null==e?void 0:e.y)&&void 0!==(null==e?void 0:e.z),z=e=>Array.isArray(e)?e:F(e)?[e.x,e.y,e.z]:[e,e,e];function H(t,r,i){if(void 0!==r){if(N(r))return r;if(r instanceof e){const e=Array.from({length:3*t},(()=>(e=>[e.r,e.g,e.b])(r))).flat();return Float32Array.from(e)}if(F(r)||Array.isArray(r)){const e=Array.from({length:3*t},(()=>z(r))).flat();return Float32Array.from(e)}return Float32Array.from({length:t},(()=>r))}return Float32Array.from({length:t},i)}const k={uniforms:{tDiffuse:{value:null},h:{value:1/512}},vertexShader:"\n\n\t\tvarying vec2 vUv;\n\n\t\tvoid main() {\n\n\t\t\tvUv = uv;\n\t\t\tgl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );\n\n\t\t}",fragmentShader:"\n\n\t\tuniform sampler2D tDiffuse;\n\t\tuniform float h;\n\n\t\tvarying vec2 vUv;\n\n\t\tvoid main() {\n\n\t\t\tvec4 sum = vec4( 0.0 );\n\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x - 4.0 * h, vUv.y ) ) * 0.051;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x - 3.0 * h, vUv.y ) ) * 0.0918;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x - 2.0 * h, vUv.y ) ) * 0.12245;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x - 1.0 * h, vUv.y ) ) * 0.1531;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y ) ) * 0.1633;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x + 1.0 * h, vUv.y ) ) * 0.1531;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x + 2.0 * h, vUv.y ) ) * 0.12245;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x + 3.0 * h, vUv.y ) ) * 0.0918;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x + 4.0 * h, vUv.y ) ) * 0.051;\n\n\t\t\tgl_FragColor = sum;\n\n\t\t}"},V={uniforms:{tDiffuse:{value:null},v:{value:1/512}},vertexShader:"\n\n\t\tvarying vec2 vUv;\n\n\t\tvoid main() {\n\n\t\t\tvUv = uv;\n\t\t\tgl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );\n\n\t\t}",fragmentShader:"\n\n\t\tuniform sampler2D tDiffuse;\n\t\tuniform float v;\n\n\t\tvarying vec2 vUv;\n\n\t\tvoid main() {\n\n\t\t\tvec4 sum = vec4( 0.0 );\n\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y - 4.0 * v ) ) * 0.051;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y - 3.0 * v ) ) * 0.0918;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y - 2.0 * v ) ) * 0.12245;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y - 1.0 * v ) ) * 0.1531;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y ) ) * 0.1633;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y + 1.0 * v ) ) * 0.1531;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y + 2.0 * v ) ) * 0.12245;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y + 3.0 * v ) ) * 0.0918;\n\t\t\tsum += texture2D( tDiffuse, vec2( vUv.x, vUv.y + 4.0 * v ) ) * 0.051;\n\n\t\t\tgl_FragColor = sum;\n\n\t\t}"};var Y=Object.defineProperty,j=(e,t,r)=>(((e,t,r)=>{t in e?Y(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r})(e,"symbol"!=typeof t?t+"":t,r),r);function W(e){return void 0!==e.w?[t,4]:void 0!==e.z?[r,3]:[i,2]}function J(e,t,r){let i=function(e,t){const r=Math.sqrt(e.lengthSq()*t.lengthSq());if(0===r)return 0;let i=e.dot(t)/r;return i=Math.max(-1,Math.min(1,i)),Math.acos(i)}(e,t);return 0===i?i:e.clone().cross(t).dot(r)<0?-i:i}const K=180/Math.PI,_={yaw:[{name:"前",range:[-15,15]},{name:"左",range:[15,165]},{name:"右",range:[-165,-15]},{name:"后",range:[-180.1,-165]},{name:"后",range:[165,180.1]}],pitch:[{name:"前",range:[-15,15]},{name:"上",range:[15,165]},{name:"下",range:[-165,-15]},{name:"后",range:[-180.1,-165]},{name:"后",range:[165,180.1]}],roll:[{name:"上",range:[-15,15]},{name:"左",range:[15,165]},{name:"右",range:[-165,-15]},{name:"下",range:[-180.1,-165]},{name:"下",range:[165,180.1]}]};const Z={degrees:!0,map:_,front:{x:0,y:0,z:1},up:{x:0,y:1,z:0}};class X{constructor(e){j(this,"_options"),j(this,"_listMap"),j(this,"_front"),j(this,"_up"),e&&(this.options=e)}static get options(){return this._options??(this.options=Z)}static set options(e){this._options=Object.assign({},structuredClone(_),e)}get defaultOptions(){return this.constructor.options}get options(){return this._options??(this.options=this.defaultOptions)}set options(e){this._options=Object.assign({},structuredClone(this.defaultOptions),e),this._listMap=null,this._front=null,this._up=null}get degrees(){return this.options.degrees??(this.options.degrees=this.defaultOptions.degrees??!0)}set degrees(e){this.options.degrees=e}get map(){return this.options.map||(this.map=this.defaultOptions.map),this.options.map}set map(e){const t=structuredClone(this.defaultOptions.map),r=structuredClone(_);e=e?{yaw:e.yaw??t.yaw??r.yaw,pitch:e.pitch??t.pitch??r.pitch,roll:e.roll??t.roll??r.roll}:t,this.options.map=e,this._listMap=null}get listMap(){return this._listMap??(this._listMap=function(e){const t={};for(const[r,i]of Object.entries(e))t[r]=Array.isArray(i)?i:Object.entries(i).map((([e,t])=>({name:e,range:t})));return t}(this.map??{}))}get front(){return this._front||(this.front=this.options.front??this.defaultOptions.front??Z.front),this._front}set front(e){this._front=(new r).copy(e)}get up(){return this._up||(this.up=this.options.up??this.defaultOptions.up??Z.up),this._up}set up(e){this._up=(new r).copy(e)}computeAzimuth(e,t,i){const n=(new r).copy(e),a=(new r).copy(t??this.front),s=(new r).copy(i??this.up);let{yaw:o,pitch:l,roll:u}=function(e,t,r){const i=t.clone().negate(),n=r.clone().projectOnPlane(t),a=J(t,e.clone().projectOnPlane(n),n),s=t.clone().cross(n);return{yaw:a,pitch:J(t,e.clone().projectOnPlane(s),s),roll:J(n,e.clone().projectOnPlane(i),i)}}(n,a,s);return this.degrees&&(o*=K,l*=K,u*=K),{yaw:{angle:o,name:this.findAzimuthNames("yaw",o)},pitch:{angle:l,name:this.findAzimuthNames("pitch",l)},roll:{angle:u,name:this.findAzimuthNames("roll",u)}}}findAzimuthNames(e,t){const r=[],i=this.listMap[e];if(!i)return r;for(const{name:e,range:[n,a]}of i)(t>=n&&t<a||t<=n&&t>a)&&r.push(e);return r}}j(X,"_options"),new X;var q=Object.defineProperty,$=(e,t,r)=>(((e,t,r)=>{t in e?q(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r})(e,"symbol"!=typeof t?t+"":t,r),r);function ee(e){const t=[];for(let r=0;r<e;r++)t.push(n.randFloatSpread(2));return t}function te(e,t,r){const i=[],n=e-1;for(let e=0;e<n;e++){const e=2*(Math.random()-.5)*(t+r);i.push(e)}const a=Math.trunc(Math.random()*e);let s=2*(Math.random()-.5)*r;return s+=Math.sign(s)*t,i.splice(a,0,s),i}function re(e,t){const r=[],i=e-1;for(let e=0;e<i;e++)r.push(n.randFloatSpread(2));return r.push(Math.random()*t),r}function ie(e,t,r,i){const n=[],a=e-1,s=a-1;for(let e=0;e<s;e++){const e=2*(Math.random()-.5)*(t+r);n.push(e)}const o=Math.trunc(Math.random()*a);let l=2*(Math.random()-.5)*r;return l+=Math.sign(l)*t,n.splice(o,0,l),n.push(Math.random()*i),n}function ne(e){let t=[];for(let r=0;r<e;r++)t.push(n.randFloatSpread(2));const r=Math.hypot(...t),i=Math.random()/r;return t=t.map((e=>e*i)),t}function ae(e,t,r){let i=[];for(let t=0;t<e;t++)i.push(n.randFloatSpread(2));const a=Math.hypot(...i),s=(Math.random()*r+t)/a;return i=i.map((e=>e*s)),i}function se(e,t){let r=[];const i=e-1;for(let e=0;e<i;e++)r.push(n.randFloatSpread(2));const a=Math.hypot(...r),s=Math.random()/a;return r=r.map((e=>e*s)),r.push(Math.random()*t),r}function oe(e,t,r,i){let a=[];const s=e-1;for(let e=0;e<s;e++)a.push(n.randFloatSpread(2));const o=Math.hypot(...a),l=(Math.random()*r+t)/o;return a=a.map((e=>e*l)),a.push(Math.random()*i),a}function le({ratio:e,density:t}){return t-t*e}function ue({ratio:e,value:t}){return t-t*e}var ce=(e=>(e[e.Circle=0]="Circle",e[e.Square=1]="Square",e))(ce||{});function pe(e,t){const{clim:i,step:n,radius:a,value:s,solid:o,hollow:l,density:u,shape:c,densityGradient:p,valueGradient:h}=e,d=e,[A,g]=W(e);let f,m;if(t){const{lineStep:e,matrix:i}=t,n=1===c?ie:oe;f=function(t,a,s){const o=n(t,a,s,e);return 2===t&&o.push(0),new r(...o).applyMatrix4(i)},m=function(t,r){return t*r**(g-2)*e}}else{const e=1===c?te:ae;f=function(t,r,i){const n=e(t,r,i);return new A(...n)},m=function(e,t){return e*t**(g-1)}}const y=[],v=[],x=a*o,w=a-x,C=a*l;for(let e=C+n;e<a;e+=n){const t={ratio:(e-x)/w,radius:a,solid:o,distance:e,density:u,solidRadius:x,gradientRadius:w,clim:i,value:s,hollow:l,hollowRadius:C};let r=m(e<x?u:p(t),e);const c=e-n;for(;r-- >-1;){const e=f(g,c,n),r=(new A).copy(e),i=r.length();r.add(d),y.push(r);const s=h({...t,ratio:i/a,distance:i});v.push(s)}}return{particles:y,values:v}}function he(e){const{points:t,clim:r={x:0,y:100},step:i=3,radius:n=10,value:a=100,solid:s=.7,hollow:o=0,density:l=1,shape:u=0,densityGradient:c=le,valueGradient:p=ue}=e,h={clim:r,step:i,radius:n,value:a,solid:s,hollow:o,density:l,shape:u,densityGradient:c,valueGradient:p},d=t[0];if(!d)return[];const[A,g]=W(d);return t.map((e=>{const t=new A;return Object.assign(t,{...h,...e}),pe(t)}))}class de extends a{constructor(e){super(),$(this,"isClusterGeometry",!0),$(this,"_options"),$(this,"_colorGradient"),$(this,"_values"),e&&(this.options=e)}get options(){return this._options??(this._options={})}set options(e){this._options=e,this.updateVertices()}get gradient(){return this.options.gradient}set gradient(e){this.options.gradient=e,this.colorGradient=this.createColorGradient(e)}get colorGradient(){return this._colorGradient?this._colorGradient:this._colorGradient=this.createColorGradient(this.gradient)}set colorGradient(e){this._colorGradient=e,this.updateVertexColors()}createColorGradient(e){if(!e)return null;const t=Array.isArray(e)?function(e,t,r,i="srgb"){const n=new OffscreenCanvas(t,r).getContext("2d"),a=n.createLinearGradient(0,0,256,1);for(const[t,r]of e)a.addColorStop(Number(t),r);return n.fillStyle=a,n.fillRect(0,0,t,r),n.getImageData(0,0,t,r,{colorSpace:i})}(e,256,1):e,{width:r,height:i}=t,n=function(e,t){const{data:r,width:i}=e,n=t*i,a=n+i;return r.slice(4*n,4*a)}(t,Math.trunc(i/2));return new ImageData(n,r,1)}updateVertexColors(){this.deleteAttribute("color");const{colorGradient:e,clim:t,values:r}=this;if(!e)return!1;const{width:i,data:a}=e,o=[],{x:l,y:u}=t,c=u-l,p=i-1;for(const e of r){const t=1-(n.clamp(e,l,u)-l)/c,r=4*Math.trunc(t*p),i=a.slice(r,r+4);o.push(...i)}this.setAttribute("color",new s(new Uint8ClampedArray(o),4,!0))}get clim(){return this.options.clim??(this.options.clim={x:0,y:100})}set clim(e){this.options.clim=e,this.updateVertexColors()}get clusters(){return this.options.clusters}set clusters(e){this.options.clusters=e,this.updateVertices()}updateVertices(){this.deleteAttribute("position"),this._values=null;const e=this.clusters;if(!e)return;const t=[],r=[];let i=0;for(const{particles:n,values:a}of e){const e=n.length;for(let s=0;s<e;s++,i++){n[s].toArray(t,3*i);const e=a[s];r.push(e)}}this.setAttribute("position",new s(new Float32Array(t),3)),this.values=r}get values(){return this._values??(this._values=[])}set values(e){this._values=e,this.updateVertexColors()}addCluster(e){const t=Array.isArray(e)?e:[e],r=this.clusters;if(!r)return void(this.clusters=t);r.push.apply(r,t);let i=[];const n=[];let a=0;for(const{particles:e,values:r}of t){const t=e.length;for(let s=0;s<t;s++,a++){e[s].toArray(i,3*a);const t=r[s];n.push(t)}}const o=this.getAttribute("position");o&&(i=[...o.array,...i]),this.setAttribute("position",new s(new Float32Array(i),3)),o?this.addValueColors(n):this.values=n}addValueColors(e){const{colorGradient:t,clim:r,values:i}=this;if(!t)return!1;const{width:a,data:o}=t;let l=[];const{x:u,y:c}=r,p=c-u,h=a-1;for(const t of e){const e=1-(n.clamp(t,u,c)-u)/p,r=4*Math.trunc(e*h),a=o.slice(r,r+4);l.push(...a),i.push(t)}const d=this.getAttribute("color");d&&(l=[...d.array,...l]),this.setAttribute("color",new s(new Uint8ClampedArray(l),4,!0))}}function Ae({startRadius:e,addedRadius:t,ratio:r}){return t*r+e}function ge({startDensity:e,addedDensity:t,ratio:r}){return t*r+e}function fe({startValue:e,addedValue:t,ratio:r}){return t*r+e}function me(e){const{points:t,clim:i={x:0,y:100},step:n=3,radius:a=10,value:s=100,solid:o=.7,hollow:l=0,density:p=1,shape:h=ce.Circle,densityGradient:d=le,valueGradient:A=ue,radiusGradient:g=Ae,lineDensityGradient:f=ge,lineValueGradient:m=fe}=e,y=e.lineStep??n,v={clim:i,step:n,radius:a,value:s,solid:o,hollow:l,density:p,shape:h,densityGradient:d,valueGradient:A,radiusGradient:g,lineDensityGradient:f},{total:x,lengths:w}=function(e){const t=e.length;let r=e[0];const[i,n]=W(r),a=[0];let s=0;for(let n=1;n<t;n++){const t=(new i).copy(e[n]).distanceTo(r);a.push(t),s+=t}return{lengths:a,total:s}}(t),C=t.length,E=t[0],b=t[C-1],B=E.radius??a,M=E.density??p,D=E.value??s,S=b.radius??a,I=b.density??p,O=b.value??s,P={length:x,startRadius:B,endRadius:S,addedRadius:S-B,defaultRadius:a,startDensity:M,endDensity:I,addedDensity:I-M,defaultDensity:p,startValue:D,endValue:O,addedValue:O-D,defaultValue:s},T=[];for(let e=0;e<C;e++){const r=t[e];let{radius:i,value:n,density:a}=r;const s={...P,ratio:w[e]/x,index:e-1};i=i??g(s),a=a??f(s),n=n??m(s),T.push({...v,...r,radius:i,density:a,value:n})}const[R,G]=W(E),U=[],L=C-1;for(let e=0;e<L;e++){const t=T[e],{radius:i,density:n,value:o}=t,l=new R;l.lineStep=y;const h=T[e+1],{radius:d,density:A,value:v}=h,x=new R;Object.assign(x,h);const C=x.clone().sub(l).normalize(),E=w[e+1],b=Math.trunc(E/y),B=d-i,M=A-n,D=v-o,S=new u;3===G?S.setFromUnitVectors(new r(0,0,1),C):S.setFromUnitVectors(new r(0,1,0),new r(C.x,C.y,0));const I=(new c).makeRotationFromQuaternion(S);Object.assign(l,{...t,lineDir:C,matrix:I}),U.push(l);const O={length:E,startRadius:i,endRadius:d,addedRadius:B,defaultRadius:a,startDensity:n,endDensity:A,addedDensity:M,defaultDensity:p,startValue:o,endValue:v,addedValue:D,defaultValue:s,index:e,ratio:0};let P=0;for(let e=1;e<b;e++){P=e*y;const r=C.clone().multiplyScalar(P).add(l),i=P/E;O.ratio=i;const n=g(O),a=f(O),s=m(O),o={...t,lineDir:C,matrix:I,radius:n,density:a,value:s,lineStep:y};delete o.x,delete o.y,delete o.z,delete o.w,Object.assign(r,o),U.push(r)}U[U.length-1].lineStep=E-P}return U.map((e=>{const{lineStep:t,matrix:r}=e;return pe(e,{lineStep:t,matrix:r})}))}function ye(e,t){const{x:r,y:i}=t;let n=0;for(const{value:t,clim:{x:r,y:i}}of e)n+=(t-r)/(i-r);return n*(i-r)+r}function ve(e,t){const{clim:r,step:i,radius:n,value:a,solid:s,hollow:o,density:l,shape:u,densityGradient:c,valueGradient:p,valuesAccumulate:h}=e,[d,A]=W(e),g=(new d).copy(e),f=u===ce.Square?te:ae,m=[],y=[],v=n*s,x=n-v,w=n*o,C=t.map((e=>({dist:g.distanceTo(e),point:e})));for(let t=w+i;t<n;t+=i){const u={ratio:(t-v)/x,radius:n,solid:s,hollow:o,hollowRadius:w,distance:t,density:l,solidRadius:v,gradientRadius:x,clim:r,value:a},E=t<v?l:c(u);let b=E*t**(A-1);const B=t-i,M=C.filter((({dist:e,point:r})=>{const i=r.radius;return e-t<=i}));e:for(;b-- >-1;){const t=new d(...f(A,B,i)),a=t.length();t.add(g);const s=[],o={...u,ratio:a/n,distance:a},l=p(o);s.push({...e,...o,value:l,density:E});for(const{point:e}of M){const r=t.distanceTo(e),{solid:i,hollow:n,radius:a}=e;if(r<=a){const t=a*i,o=a-t,l=a*n;if(r<l)continue e;const u={...e,ratio:r/a,distance:r,solidRadius:t,gradientRadius:o,hollowRadius:l},c=p(u);s.push({...u,value:c})}}m.push(t);const c=h(s,r,E);y.push(c)}}return{particles:m,values:y}}function xe(e){const{points:t,clim:r={x:0,y:100},step:i=3,radius:n=10,value:a=100,solid:s=.7,hollow:o=0,density:l=1,shape:u=ce.Circle,densityGradient:c=le,valueGradient:p=ue,valuesAccumulate:h=ye}=e,d={clim:r,step:i,radius:n,value:a,solid:s,hollow:o,density:l,shape:u,densityGradient:c,valueGradient:p,valuesAccumulate:h},A=t.map((e=>({...d,...e}))),g=function(e){const t=e.length,r=[];if(0===t)return r;const[i,n]=W(e[0]);for(let n=0;n<t;n++){const a=e[n],s=(new i).copy(a),o=a.radius,l=r[n]??(r[n]=[]);for(let i=n+1;i<t;i++){const t=e[i];s.distanceToSquared(t)<=(t.radius+o)**2&&(l.push(i),(r[i]=[]).push(n))}}return r}(A);return A.map(((e,t)=>{const r=g[t].map((e=>A[e]));return ve({...d,...e},r)}))}var we=(e=>(e[e.Point=0]="Point",e[e.Line=1]="Line",e[e.Heat=2]="Heat",e))(we||{});const Ce={cluster:{base:["radius","solid","hollow","density","shape","densityGradient","step","clusterType","points"],line:["radiusGradient","lineDensityGradient","lineStep"],heat:[]},gradient:{base:["value","valueGradient","clim","gradient"],line:["lineValueGradient"],heat:["valuesAccumulate"]}};class Ee extends de{constructor(e){super(),$(this,"isParticleClusterGeometry",!0),e&&(this.options=e)}get options(){return this._options}set options(e){this._options=e,this.updateClusters()}get clusterType(){return this.options.clusterType}set clusterType(e){this.options.clusterType!==e&&(this.options.clusterType=e,this.updateClusters())}setOptions(e){const t=this.options;let r=!1;const i=Object.entries(e).some((([e,i])=>i!==t[e]&&(!!(Ce.cluster.base.includes(e)||1===this.clusterType&&Ce.cluster.line.includes(e)||2===this.clusterType&&Ce.cluster.heat.includes(e))||(Ce.gradient.base.includes(e)&&(r=!0),1===this.clusterType&&Ce.gradient.line.includes(e)&&(r=!0),void(2===this.clusterType&&Ce.gradient.heat.includes(e)&&(r=!0))))));Object.assign(this.options,e),i?this.updateClusters():r&&this.updateVertexColors()}updateClusters(){this.clusters=this.createClusters(this.options)}createClusters(e){let t;switch(e.clusterType){case 2:t=xe(e);break;case 1:t=me(e);break;default:t=he(e)}return t}addPoint(e,t){const r=Array.isArray(e)?e:[e],i={...this.options,...t,points:r},n=this.createClusters(i);this.addCluster(n)}}class be extends o{constructor(e){super(new Ee,new l({vertexColors:!0,transparent:!0,...e})),$(this,"isParticleCluster",!0),e&&(this.options=e)}get options(){return this.geometry.options}set options(e){const t=null==e?void 0:e.points;if(t){const r=this.convertPoints(t);e={...e,points:r}}this.geometry.options=e}setOptions(e){const t=e.points;if(t){const r=this.convertPoints(t);e={...e,points:r}}this.geometry.setOptions(e)}addPoint(e,t){const r=Array.isArray(e)?e:[e],i=this.convertPoints(r);this.geometry.addPoint(i,t)}convertPoints(e){const t=this.matrixWorld.clone().invert();return e.map((e=>{const i=new r;return Object.assign(i,e),i.applyMatrix4(t),i}))}}class Be{constructor(e){const{textureUrl:t,width:r,height:i,position:n,isScaleAnimate:a,isOpacityAnimate:s}=e;void 0!==t[1]&&(this.outMaterial=this.createMaterial(t[1]),this.outPlaneGeometry=this.createPlane(r,i),this.outMesh=new p(this.outPlaneGeometry,this.outMaterial),this.outMesh.renderOrder=Number.MAX_SAFE_INTEGER-2,this.outMesh.position.set(n.x,n.y,n.z),this.outMesh.rotation.set(-1.5707022192751596,33819658717412135e-21,.34500000055302255)),this.inMaterial=this.createMaterial(t[0]),this.inPlaneGeometry=this.createPlane(r,i),this.inMesh=new p(this.inPlaneGeometry,this.inMaterial),this.inMesh.renderOrder=Number.MAX_SAFE_INTEGER-1,this.inMesh.position.set(n.x,n.y,n.z),this.inMesh.rotation.set(-1.5707022192751596,33819658717412135e-21,.34500000055302255),this.isScaleAnimate=a,this.isOpacityAnimate=s,this.AngleUnit=.1,this.MaxScale=3,this.ScaleUnit=.02,this.OpacityUnit=1/((this.MaxScale-0)/this.ScaleUnit)}createPlane(e=10,t=10){return new h(e,t)}createMaterial(e){const t=new d,r=(new A).load(e);return t.map=r,t.side=g,t.transparent=!0,t}update(){if(void 0!==this.outMesh){const e=this.outMesh.material.map;null==e||e.center.set(.5,.5),e.rotation+=this.AngleUnit}const e=this.inMesh.material.map;if(null==e||e.center.set(.5,.5),e.rotation-=this.AngleUnit,this.isScaleAnimate){this.inMesh.scale.x>this.MaxScale&&(this.inMesh.scale.x=0,this.inMesh.scale.y=0,this.inMesh.material.opacity=1,void 0!==this.outMesh&&(this.outMesh.scale.y=0,this.outMesh.scale.x=0,this.outMesh.material.opacity=1)),void 0!==this.outMesh&&(this.outMesh.scale.y+=this.ScaleUnit,this.outMesh.scale.x+=this.ScaleUnit),this.inMesh.scale.x+=this.ScaleUnit,this.inMesh.scale.y+=this.ScaleUnit}this.isOpacityAnimate&&(void 0!==this.outMesh&&(this.outMesh.material.opacity-=this.OpacityUnit),this.inMesh.material.opacity-=this.OpacityUnit)}}class Me{constructor(e){const{topRadius:t,bottomRadius:r,height:i,position:n,texturePath:a,color:s}=e;this.geometry=this.createGeometry(t,r,i),this.material=this.creatematerial(a,s),this.position=n,this.mesh=new p(this.geometry,this.material),this.mesh.renderOrder=Number.MAX_SAFE_INTEGER-1,this.mesh.position.set(n.x,n.y+i/2,n.z),this.maxScale=15,this.minScale=1,this.opacityUnit=1/this.maxScale}createGeometry(e,t,r){return new f(e,t,r,32,16,!0)}creatematerial(e,t){const r=new d,i=(new A).load(e);return r.map=i,r.side=g,r.opacity=1,r.transparent=!0,r}update(){let e=this.mesh.scale.x;e+=.1,e>=this.maxScale&&(e=1);const t=1-this.opacityUnit*e;this.mesh.scale.set(e,this.mesh.scale.y,e),this.mesh.material.opacity=t}}var De={vertexShader:"\n attribute float size;\n uniform float showDistance;\n varying float dcolor;\n void main() {\n\n vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );\n // vec4 viewPosition = viewMatrix * mvPosition;\n \n //gl_PointSize = 5.0;\n float fDistance =sqrt( position.x * position.x + position.z * position.z );\n if(fDistance < showDistance)\n return;\n\n // dcolor = fDistance/355.0/3.0;\n gl_Position = projectionMatrix * mvPosition;\n gl_PointSize = size * ( 300.0 / - mvPosition.z );\n // gl_PointSize *= (1.0 / - viewPosition.z);\n }\n ",fragmentShader:"\n #include <common>\n uniform vec3 color;\n uniform float opacity;\n // varying float dcolor;\n void main() {\n\n //if ( length( gl_PointCoord - vec2( 0.5, 0.5 ) ) > 0.475 ) discard;\n // int buffer = int(dcolor);\n \n //gl_FragColor = vec4( dcolor,sin(dcolor),0, 1.0 );\n gl_FragColor = vec4( color, opacity );\n\n #include <tonemapping_fragment>\n #include <encodings_fragment>\n }\n "},Se={vertexShader:"\n uniform vec2 lowHeigh;\n varying float ratioHeigh;\n void main() {\n \n vec4 mvPosition = modelViewMatrix * vec4( position, 1.0 );\n float maxHeigh = lowHeigh.y - lowHeigh.x;\t\n float curHeigh = lowHeigh.y - position.y;\t\n ratioHeigh = curHeigh/maxHeigh;\n gl_Position = projectionMatrix * mvPosition;\n \n }\n ",fragmentShader:"\n #include <common>\n uniform vec3 color;\n varying float ratioHeigh;\n void main() {\n \n // gl_FragColor = vec4( color, 1.0-ratioHeigh*ratioHeigh*ratioHeigh-0.5 );\n gl_FragColor = vec4( color, max( 1.0-ratioHeigh*ratioHeigh*ratioHeigh-0.5, 0.01 ) );\n\n #include <tonemapping_fragment>\n #include <encodings_fragment>\n }\n "};class Ie{constructor(e){this.ssp=e,this.weatherPresetImgs={rain:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAACXBIWXMAAAsTAAALEwEAmpwYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAASQSURBVHjarFfPb1RVFP7Oufe9Nz86zLSlI2DjD4xYYyFGY7QJiQu60ITEENlhIgs2hIoLjewb3bvgH8DEuDAEY1y4IK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fJjy8NmM0AkaULSvcbY09f55uSF16yZkDlB2YH+71zu/LB9dgsFYKxmIXoQjUABHFK2J0Pr/cPZM9R385ZawYGyYdW4qtBPlUNvO9iowYcy45I3f9EGJ5K50eHWqeGHOMvfrrl7RjQZMAwKHhqaqRYPZFXUTMWXk7D0r1gZZ+U5fhTYeQ5ar5UrJzYkaEphoFeJwBeL4cCIBGg5EQXXuxfOJRT7csCgQjBdLcJAENLT4YRggiQ5fbl0YHGoZITX0iElv1Zp2BlIyMAdHWn135rwKm/e9cvHAvhvgbhHQZMEAJTKkSmkVHR1b15/8t67J4XoaZN0rSNort0N0s6PJdj91K/8l8v5PTYdDA4AAL25urzfiueaqfujyUnnKnHrthOkH8HAIl7DGQhmnDgAAAAAElFTkSuQmCC",snow:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAUNJREFUOE+lk78rhWEUxz/fwWAzUBYs/gMMNkp+lbKwWPgPGAySuJPxWqSUMhMpgzCwWShumSibxWJ2h6/O7Xlvb5d7da+nTk9vz3s+z/ec53vEP5ca5du+iXNJo/X++wGwvQhMp4SutH+kfVnSex5WBdjuB76AE0lDto+AKkDSvO17YE/SQQapAGwPAHG4CmwAnZLKtSXYNjALrAMLkl4ywBywAgwDJaAo6TAPSKUVgF7gAtiRdJVXMAZkEcLOgI4k9TPdHJ+RXAlJrxlgBOgBniSVbG8Bm0AkxgpQQdKW7Skg4lTSbR7QLinI0ZMoaRdoawA4l3SdAYaASWACKAOhqKkSxoHlJC0uXarTxG2gG7hLjT6ufcZ9YAboa/CMAVkDBiU95I0UXngDLv8wUhF4lPRcsXmtx1u28m/D0tIwNTvd35YVoxGOzVJ7AAAAAElFTkSuQmCC"},this._weatherId=""}createFlame(i){const{magnitude:n=1.3,gain:a=.5}=i,s=50,o=new p(new m(1,1,1),(i=>{const{imgUrl:o=P}=i,l=(new A).load(o);l.magFilter=l.minFilter=B,l.wrapS=l.wrapT=M;const u=new b({defines:{ITERATIONS:20,OCTIVES:3,WIDTH:128,BOUNDS:512},uniforms:D.merge([S.phong.uniforms,{fireTex:{type:"t",value:l},time:{type:"f",value:0},seed:{type:"f",value:19.19*Math.random()},invModelMatrix:{type:"v4",value:new c},scale:{type:"v3",value:new r(s,s,s)},noiseScale:{type:"v4",value:new t(1,2,1,.3)},magnitude:{type:"f",value:n},gain:{type:"f",value:a},lacunarity:{type:"f",value:2},diffuse:{type:"c",value:new e(16576)},specular:{type:"c",value:new e(1118481)},shininess:{type:"f",value:Math.max(50,1e-4)},opacity:{type:"f",value:.8}}]),vertexShader:O.vertexShader,fragmentShader:O.fragmentShader,transparent:!0,depthWrite:!1,depthTest:!0,lights:!0});return u.uniforms.fireTex.value=l,u})(i));o.scale.set(s,s,s);const l=e=>{const t=o.material,i=t.uniforms.invModelMatrix.value;o.updateMatrixWorld(),i.copy(o.matrixWorld).invert(),void 0!==e&&(t.uniforms.time.value=e/1e3),t.uniforms.invModelMatrix.value=i,t.uniforms.scale.value=o.getWorldScale(new r),t.uniforms.magnitude.value=n||1.3,t.uniforms.gain.value=a||.5,t.version++,this.ssp.render()};this.ssp.viewport.postUpdate.set(i.id,l);const u=this.ssp.createPluginObject(i,o),h=()=>this.ssp.viewport.postUpdate.set(i.id,l);return h(),u.addEventListener("added",h),u.addEventListener("removed",(()=>this.ssp.viewport.postUpdate.delete(i.id))),u}removeFlame(e){return console.warn("请使用 ssp.removeObjectById 替代"),this.ssp.removeObjectById(e)}createSmoke(t){const{imgUrl:i=L,count:n=1e3,maxAge:a=4,size:s=200,acceleration:o=10,velocity:l={x:100,y:100,z:100},color:u=[3355443,1118481]}=t,c=new y,p=(new A).load(i),h=new U.Group({texture:{value:p},blending:v}),d=new U.Emitter({particleCount:n,maxAge:{value:a},position:{value:new r(0,0,0),spread:new r(0,0,0)},size:{value:s,spread:[1,1,8]},acceleration:{value:new r(0,o,0)},rotation:{angle:this.ssp.utils.deg2Euler(45),randomise:!0},velocity:{value:new r(0,100,0),spread:new r(l.x,l.y,l.z)},opacity:{value:[.5,.2,0]},color:{value:u.map((t=>new e(t)))}});h.addEmitter(d);const g=()=>{h.tick(c.getDelta()),this.ssp.render()},f=this.ssp.createPluginObject(t,h.mesh),m=()=>this.ssp.viewport.postUpdate.set(t.id,g);return m(),f.addEventListener("added",m),f.addEventListener("removed",(()=>this.ssp.viewport.postUpdate.delete(t.id))),f}removeSmoke(e){return console.warn("请使用 removeObjectById 替代"),this.ssp.removeObjectById(e)}createSparkles(e){const{count:t=100,scalar:r=8,speed:i=1,opacity:n=1,noise:a=1,color:s="#fff",size:o=2}=e,{ssp:l}=this,{THREE:u}=l,{Points:c,ShaderMaterial:p,BufferGeometry:h,BufferAttribute:d}=u,A=Float32Array.from(Array.from({length:t},(()=>z(r).map(u.MathUtils.randFloatSpread))).flat()),g=H(t,o,Math.random),f=H(t,n),m=H(t,i),y=H(3*t,a),v=H(void 0===s?3*t:t,N(s)?s:new u.Color(s),(()=>1)),w=new h;w.setAttribute("position",new d(A,3)),w.setAttribute("size",new d(g,1)),w.setAttribute("opacity",new d(f,1)),w.setAttribute("speed",new d(m,1)),w.setAttribute("color",new d(v,3)),w.setAttribute("noise",new d(y,3));const C=new p({uniforms:{time:{value:0},pixelRatio:{value:self.devicePixelRatio}},vertexShader:Q.vertexShader,fragmentShader:Q.fragmentShader,depthWrite:!1,transparent:!0,blending:x}),E=new c(w,C),b=()=>{C.uniforms.time.value=l.viewport.clock.elapsedTime,this.ssp.render()},B=this.ssp.createPluginObject(e,E),M=()=>this.ssp.viewport.postUpdate.set(e.id,b);return M(),B.addEventListener("added",M),B.addEventListener("removed",(()=>this.ssp.viewport.postUpdate.delete(e.id))),B}createContactShadows(e){var{scale:t=10,frames:r=1/0,opacity:i=1,width:n=1,height:a=1,blur:s=1,darkness:o=1,far:l=10,resolution:u=512}=e,c=function(e,t){var r={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(r[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(i=Object.getOwnPropertySymbols(e);n<i.length;n++)t.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(r[i[n]]=e[i[n]])}return r}(e,["scale","frames","opacity","width","height","blur","darkness","far","resolution"]);const{viewport:{renderer:p,scene:h},THREE:d}=this.ssp;n*=Array.isArray(t)?t[0]:t||1,a*=Array.isArray(t)?t[1]:t||1;const A=new d.Group,g=new d.OrthographicCamera(-n/2,n/2,a/2,-a/2,0,l);g.rotation.x=Math.PI/2,A.add(g);const f=new d.WebGLRenderTarget(u,u),m=new d.WebGLRenderTarget(u,u);m.texture.generateMipmaps=f.texture.generateMipmaps=!1;const y=new d.PlaneGeometry(n,a).rotateX(Math.PI/2),v=new d.MeshBasicMaterial({map:f.texture,opacity:i,transparent:!0,depthWrite:!1}),x=new d.Mesh(y,v);x.renderOrder=1,x.scale.y=-1,A.add(x);const w=new d.Mesh(y);w.visible=!1,A.add(w);const C=new d.MeshDepthMaterial;C.userData.darkness={value:o},C.onBeforeCompile=function(e){e.uniforms.darkness=C.userData.darkness,e.fragmentShader=`\n uniform float darkness;\n ${e.fragmentShader.replace("gl_FragColor = vec4( vec3( 1.0 - fragCoordZ ), opacity );","gl_FragColor = vec4( vec3( 0.0 ), ( 1.0 - fragCoordZ ) * darkness );")}\n `},C.depthTest=!1,C.depthWrite=!1;const E=new d.ShaderMaterial(k);E.depthTest=!1;const b=new d.ShaderMaterial(V);function B(e){w.visible=!0,w.material=E,E.uniforms.tDiffuse.value=f.texture,E.uniforms.h.value=1*e/256,p.setRenderTarget(m),p.render(w,g),w.material=b,b.uniforms.tDiffuse.value=m.texture,b.uniforms.v.value=1*e/256,p.setRenderTarget(f),p.render(w,g),w.visible=!1}b.depthTest=!1;let M=0;const D=()=>{if(M>r)return;M++;const e=h.background;h.background=null,h.overrideMaterial=C;const t=p.getClearAlpha();p.setClearAlpha(0),p.setRenderTarget(f),p.render(h,g),h.overrideMaterial=null,B(s),B(.4*s),p.setRenderTarget(null),p.setClearAlpha(t),h.background=e},S=this.ssp.createPluginObject(c,A),I=()=>this.ssp.signals.beforeRender.add(D);return I(),S.addEventListener("added",I),S.addEventListener("removed",(()=>this.ssp.signals.beforeRender.remove(D))),S}openWeather(e={}){const{imgUrl:t=this.weatherPresetImgs.rain,count:r=500,range:i=100,size:u=1,opacity:c=.9,color:p=16777215,velocityX:h=[-.02,.02],velocityY:d=[.4,.8]}=e;this._weatherId&&this.closeWeather();const{viewport:{renderer:g,container:f},utils:m}=this.ssp,y=new Float32Array(3*r),v=Array.from({length:r}).fill({x:0,y:0}),x=new a;for(let e=0;e<r;e++)y[3*e]=n.randFloatSpread(i),y[3*e+1]=n.randFloatSpread(i),y[3*e+2]=n.randFloatSpread(i),v[e].x=n.randFloat(...h),v[e].y=n.randFloat(...d);const b=new s(y,3);b.setUsage(w),x.setAttribute("position",b);const B=(new A).load(t);B.colorSpace=g.outputColorSpace;const M=new l({color:p,size:u,opacity:c,map:B,transparent:!0}),D=new o(x,M),S=new C,I=new E(45,f.offsetWidth/f.offsetHeight,.1,1e3);I.position.set(0,0,i/2),S.add(D);this._weatherId=`weather_${m.randomString()}`,this.ssp.viewport.postRender.set(this._weatherId,(()=>{v.forEach(((e,t)=>{y[3*t]-=e.x,y[3*t+1]-=e.y,(y[3*t]<=-i/2||y[3*t]>=i/2)&&(v[t].x*=-1),y[3*t+1]<=-i/2&&(y[3*t+1]=i/2)})),b.needsUpdate=!0,g.render(S,I),this.ssp.render()})),this.ssp.render()}closeWeather(){this._weatherId&&(this.ssp.viewport.postRender.delete(this._weatherId),this._weatherId="",this.ssp.render())}createParticleCluster(e){const t=new be(e);return this.ssp.addObject(t),t}createCircleWave(e){const t=this.ssp.createPluginObject(e),r=new Be(e);t.add(r.inMesh),r.outMesh&&t.add(r.outMesh);const i=()=>{this.ssp.viewport.postUpdate.set(e.id,(()=>{r.update(),this.ssp.render()}))};return i(),t.addEventListener("added",i),t.addEventListener("removed",(()=>this.ssp.viewport.postUpdate.delete(e.id))),t}createCylinderWave(e){const t=this.ssp.createPluginObject(e),r=new Me(e);t.add(r.mesh),this.ssp.addObject(t);const i=()=>{this.ssp.viewport.postUpdate.set(e.id,(()=>{r.update(),this.ssp.render()}))};return i(),t.addEventListener("added",i),t.addEventListener("removed",(()=>this.ssp.viewport.postUpdate.delete(e.id))),t}createPointsWave(t){let r=0;const{xAxisCount:i=100,zAxisCount:n=100,showDistance:l=0,separation:u=20,size:c=5,maxFluctua:p=.1,color:h="#485c7c",opacity:d=1}=t,A=i*n,g=new Float32Array(3*A),f=new Float32Array(A);let m=0,y=0;for(let e=0;e<i;e++)for(let t=0;t<n;t++)g[m]=e*u-i*u/2,g[m+1]=0,g[m+2]=t*u-n*u/2,f[y]=1,m+=3,y++;const v=new a;v.setAttribute("position",new s(g,3).setUsage(w)),v.setAttribute("size",new s(f,1).setUsage(w));const x=new b({transparent:!0,depthWrite:!1,uniforms:{color:{value:new e(h)},opacity:{value:d},showDistance:{value:l}},vertexShader:De.vertexShader,fragmentShader:De.fragmentShader}),C=new o(v,x);C.renderOrder=-1;const E=()=>{const e=C.geometry.attributes.position.array,t=C.geometry.attributes.size.array;let a=0,s=0;const o=Math.sqrt(i/2*(i/2)+n/2*(n/2));for(let l=0;l<i;l++)for(let u=0;u<n;u++){const h=l-i/2,d=u-n/2,A=Math.sqrt(h*h+d*d);e[a+1]=50*Math.cos(1*(A/o*50-r))*p,t[s]=c,a+=3,s++}C.geometry.attributes.position.needsUpdate=!0,C.geometry.attributes.size.needsUpdate=!0,r+=.01,this.ssp.render()},B=this.ssp.createPluginObject(t,C),M=()=>this.ssp.viewport.postUpdate.set(t.id,E);return M(),B.addEventListener("added",M),B.addEventListener("removed",(()=>this.ssp.viewport.postUpdate.delete(t.id))),B}createBuilds(t){const{buildWidth:r=100,buildDepth:n=100,buildHeigh:a=200,count:s=12,gapX:o=2,gapZ:l=2,showDistance:u=1e3,randShift:c=.5,color:h="#485c7c"}=t,d=this.ssp.createPluginObject(t);for(let t=0;t<s;t++)for(let A=0;A<s;A++){const g=(t-s/2)*r*o+(Math.random()-1)*c*r*o,f=(A-s/2)*n*l+(Math.random()-1)*c*n*l;if(Math.sqrt(g*g+f*f)<u)continue;const y=Math.floor(Math.random()*a)+a,v=new m(r,y,n,1,1,1);v.translate(g,y/2,f),v.computeBoundingBox();const x=v.boundingBox,w=new b({transparent:!0,depthWrite:!1,uniforms:{color:{value:new e(h)},lowHeigh:{value:new i(x.min.y,x.max.y)}},vertexShader:Se.vertexShader,fragmentShader:Se.fragmentShader}),C=new p(v,w);d.add(C)}return d}removeEffect(e){return console.warn("请使用 removeObjectById 替代"),this.ssp.removeObjectById(e)}}export{de as ClusterGeometry,we as ClusterType,be as ParticleCluster,Ee as ParticleClusterGeometry,ce as ParticleClusterShape,ve as createHeatParticleClusterData,xe as createHeatParticleClusterDataArr,pe as createPointParticleClusterData,he as createPointParticleClusterDataArr,Ie as default,le as densityGradient_Default,ne as getRandomVector_Circle,ae as getRandomVector_CircleAnnular,se as getRandomVector_CircleCylinder,oe as getRandomVector_CircleCylinderAnnular,ee as getRandomVector_Square,te as getRandomVector_SquareAnnular,re as getRandomVector_SquareCylinder,ie as getRandomVector_SquareCylinderAnnular,ue as valueGradient_Default,ye as valuesAccumulate_Default};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@soonspacejs/plugin-effect",
|
|
3
3
|
"pluginName": "EffectPlugin",
|
|
4
|
-
"version": "2.11.
|
|
4
|
+
"version": "2.11.4",
|
|
5
5
|
"description": "Effect plugin for SoonSpace.js",
|
|
6
6
|
"main": "dist/index.esm.js",
|
|
7
7
|
"module": "dist/index.esm.js",
|
|
@@ -17,8 +17,8 @@
|
|
|
17
17
|
"@three3d/particle": "^1.0.4",
|
|
18
18
|
"heatmap-ts": "^0.0.4"
|
|
19
19
|
},
|
|
20
|
-
"gitHead": "
|
|
20
|
+
"gitHead": "08b73e935b976663479ecb0a7bce4b122b5ede66",
|
|
21
21
|
"peerDependencies": {
|
|
22
|
-
"soonspacejs": "2.11.
|
|
22
|
+
"soonspacejs": "2.11.4"
|
|
23
23
|
}
|
|
24
24
|
}
|