文件名从 public/CIMSDK/Workers/Transforms-f3654378.js 修改 |
| | |
| | | define(["require","exports","./Matrix3-6e56fbc7","./defaultValue-865ac579","./Math-76ce6367","./Matrix2-23dd5853","./combine-5e110d09","./RuntimeError-9e0724f9"],(function(e,t,n,r,o,i,s,a){"use strict";function u(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}function c(e){let t;this.name="DeveloperError",this.message=e;try{throw new Error}catch(e){t=e.stack}this.stack=t}r.defined(Object.create)&&(c.prototype=Object.create(Error.prototype),c.prototype.constructor=c),c.prototype.toString=function(){let e=`${this.name}: ${this.message}`;return r.defined(this.stack)&&(e+=`\n${this.stack.toString()}`),e},c.throwInstantiationError=function(){throw new c("This function defines an interface and should not be called directly.")};const l={};function d(e,t,n){return`Expected ${n} to be typeof ${t}, actual typeof was ${e}`}l.typeOf={},l.defined=function(e,t){if(!r.defined(t))throw new c(function(e){return`${e} is required, actual value was undefined`}(e))},l.typeOf.func=function(e,t){if("function"!=typeof t)throw new c(d(typeof t,"function",e))},l.typeOf.string=function(e,t){if("string"!=typeof t)throw new c(d(typeof t,"string",e))},l.typeOf.number=function(e,t){if("number"!=typeof t)throw new c(d(typeof t,"number",e))},l.typeOf.number.lessThan=function(e,t,n){if(l.typeOf.number(e,t),t>=n)throw new c(`Expected ${e} to be less than ${n}, actual value was ${t}`)},l.typeOf.number.lessThanOrEquals=function(e,t,n){if(l.typeOf.number(e,t),t>n)throw new c(`Expected ${e} to be less than or equal to ${n}, actual value was ${t}`)},l.typeOf.number.greaterThan=function(e,t,n){if(l.typeOf.number(e,t),t<=n)throw new c(`Expected ${e} to be greater than ${n}, actual value was ${t}`)},l.typeOf.number.greaterThanOrEquals=function(e,t,n){if(l.typeOf.number(e,t),t<n)throw new c(`Expected ${e} to be greater than or equal to ${n}, actual value was ${t}`)},l.typeOf.object=function(e,t){if("object"!=typeof t)throw new c(d(typeof t,"object",e))},l.typeOf.bool=function(e,t){if("boolean"!=typeof t)throw new c(d(typeof t,"boolean",e))},l.typeOf.bigint=function(e,t){if("bigint"!=typeof t)throw new c(d(typeof t,"bigint",e))},l.typeOf.number.equals=function(e,t,n,r){if(l.typeOf.number(e,n),l.typeOf.number(t,r),n!==r)throw new c(`${e} must be equal to ${t}, the actual values are ${n} and ${r}`)};var f=l,p="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function h(e){this._ellipsoid=r.defaultValue(e,n.Ellipsoid.WGS84),this._semimajorAxis=this._ellipsoid.maximumRadius,this._oneOverSemimajorAxis=1/this._semimajorAxis}Object.defineProperties(h.prototype,{ellipsoid:{get:function(){return this._ellipsoid}}}),h.prototype.project=function(e,t){const o=this._semimajorAxis,i=e.longitude*o,s=e.latitude*o,a=e.height;return r.defined(t)?(t.x=i,t.y=s,t.z=a,t):new n.Cartesian3(i,s,a)},h.prototype.unproject=function(e,t){const o=this._oneOverSemimajorAxis,i=e.x*o,s=e.y*o,a=e.z;return r.defined(t)?(t.longitude=i,t.latitude=s,t.height=a,t):new n.Cartographic(i,s,a)};var m=Object.freeze({OUTSIDE:-1,INTERSECTING:0,INSIDE:1});function g(e,t){this.start=r.defaultValue(e,0),this.stop=r.defaultValue(t,0)}function y(e,t){this.center=n.Cartesian3.clone(r.defaultValue(e,n.Cartesian3.ZERO)),this.radius=r.defaultValue(t,0)}const v=new n.Cartesian3,w=new n.Cartesian3,_=new n.Cartesian3,C=new n.Cartesian3,b=new n.Cartesian3,x=new n.Cartesian3,S=new n.Cartesian3,A=new n.Cartesian3,E=new n.Cartesian3,O=new n.Cartesian3,I=new n.Cartesian3,P=new n.Cartesian3,R=4/3*o.CesiumMath.PI;y.fromPoints=function(e,t){if(r.defined(t)||(t=new y),!r.defined(e)||0===e.length)return t.center=n.Cartesian3.clone(n.Cartesian3.ZERO,t.center),t.radius=0,t;const o=n.Cartesian3.clone(e[0],S),i=n.Cartesian3.clone(o,v),s=n.Cartesian3.clone(o,w),a=n.Cartesian3.clone(o,_),u=n.Cartesian3.clone(o,C),c=n.Cartesian3.clone(o,b),l=n.Cartesian3.clone(o,x),d=e.length;let f;for(f=1;f<d;f++){n.Cartesian3.clone(e[f],o);const t=o.x,r=o.y,d=o.z;t<i.x&&n.Cartesian3.clone(o,i),t>u.x&&n.Cartesian3.clone(o,u),r<s.y&&n.Cartesian3.clone(o,s),r>c.y&&n.Cartesian3.clone(o,c),d<a.z&&n.Cartesian3.clone(o,a),d>l.z&&n.Cartesian3.clone(o,l)}const p=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(u,i,A)),h=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(c,s,A)),m=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(l,a,A));let g=i,R=u,T=p;h>T&&(T=h,g=s,R=c),m>T&&(T=m,g=a,R=l);const q=E;q.x=.5*(g.x+R.x),q.y=.5*(g.y+R.y),q.z=.5*(g.z+R.z);let z=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(R,q,A)),M=Math.sqrt(z);const D=O;D.x=i.x,D.y=s.y,D.z=a.z;const U=I;U.x=u.x,U.y=c.y,U.z=l.z;const k=n.Cartesian3.midpoint(D,U,P);let F=0;for(f=0;f<d;f++){n.Cartesian3.clone(e[f],o);const t=n.Cartesian3.magnitude(n.Cartesian3.subtract(o,k,A));t>F&&(F=t);const r=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(o,q,A));if(r>z){const e=Math.sqrt(r);M=.5*(M+e),z=M*M;const t=e-M;q.x=(M*q.x+t*o.x)/e,q.y=(M*q.y+t*o.y)/e,q.z=(M*q.z+t*o.z)/e}}return M<F?(n.Cartesian3.clone(q,t.center),t.radius=M):(n.Cartesian3.clone(k,t.center),t.radius=F),t};const T=new h,q=new n.Cartesian3,z=new n.Cartesian3,M=new n.Cartographic,D=new n.Cartographic;y.fromRectangle2D=function(e,t,n){return y.fromRectangleWithHeights2D(e,t,0,0,n)},y.fromRectangleWithHeights2D=function(e,t,o,s,a){if(r.defined(a)||(a=new y),!r.defined(e))return a.center=n.Cartesian3.clone(n.Cartesian3.ZERO,a.center),a.radius=0,a;t=r.defaultValue(t,T),i.Rectangle.southwest(e,M),M.height=o,i.Rectangle.northeast(e,D),D.height=s;const u=t.project(M,q),c=t.project(D,z),l=c.x-u.x,d=c.y-u.y,f=c.z-u.z;a.radius=.5*Math.sqrt(l*l+d*d+f*f);const p=a.center;return p.x=u.x+.5*l,p.y=u.y+.5*d,p.z=u.z+.5*f,a};const U=[];y.fromRectangle3D=function(e,t,o,s){if(t=r.defaultValue(t,n.Ellipsoid.WGS84),o=r.defaultValue(o,0),r.defined(s)||(s=new y),!r.defined(e))return s.center=n.Cartesian3.clone(n.Cartesian3.ZERO,s.center),s.radius=0,s;const a=i.Rectangle.subsample(e,t,o,U);return y.fromPoints(a,s)},y.fromVertices=function(e,t,o,i){if(r.defined(i)||(i=new y),!r.defined(e)||0===e.length)return i.center=n.Cartesian3.clone(n.Cartesian3.ZERO,i.center),i.radius=0,i;t=r.defaultValue(t,n.Cartesian3.ZERO),o=r.defaultValue(o,3);const s=S;s.x=e[0]+t.x,s.y=e[1]+t.y,s.z=e[2]+t.z;const a=n.Cartesian3.clone(s,v),u=n.Cartesian3.clone(s,w),c=n.Cartesian3.clone(s,_),l=n.Cartesian3.clone(s,C),d=n.Cartesian3.clone(s,b),f=n.Cartesian3.clone(s,x),p=e.length;let h;for(h=0;h<p;h+=o){const r=e[h]+t.x,o=e[h+1]+t.y,i=e[h+2]+t.z;s.x=r,s.y=o,s.z=i,r<a.x&&n.Cartesian3.clone(s,a),r>l.x&&n.Cartesian3.clone(s,l),o<u.y&&n.Cartesian3.clone(s,u),o>d.y&&n.Cartesian3.clone(s,d),i<c.z&&n.Cartesian3.clone(s,c),i>f.z&&n.Cartesian3.clone(s,f)}const m=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(l,a,A)),g=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(d,u,A)),R=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(f,c,A));let T=a,q=l,z=m;g>z&&(z=g,T=u,q=d),R>z&&(z=R,T=c,q=f);const M=E;M.x=.5*(T.x+q.x),M.y=.5*(T.y+q.y),M.z=.5*(T.z+q.z);let D=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(q,M,A)),U=Math.sqrt(D);const k=O;k.x=a.x,k.y=u.y,k.z=c.z;const F=I;F.x=l.x,F.y=d.y,F.z=f.z;const N=n.Cartesian3.midpoint(k,F,P);let j=0;for(h=0;h<p;h+=o){s.x=e[h]+t.x,s.y=e[h+1]+t.y,s.z=e[h+2]+t.z;const r=n.Cartesian3.magnitude(n.Cartesian3.subtract(s,N,A));r>j&&(j=r);const o=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(s,M,A));if(o>D){const e=Math.sqrt(o);U=.5*(U+e),D=U*U;const t=e-U;M.x=(U*M.x+t*s.x)/e,M.y=(U*M.y+t*s.y)/e,M.z=(U*M.z+t*s.z)/e}}return U<j?(n.Cartesian3.clone(M,i.center),i.radius=U):(n.Cartesian3.clone(N,i.center),i.radius=j),i},y.fromEncodedCartesianVertices=function(e,t,o){if(r.defined(o)||(o=new y),!r.defined(e)||!r.defined(t)||e.length!==t.length||0===e.length)return o.center=n.Cartesian3.clone(n.Cartesian3.ZERO,o.center),o.radius=0,o;const i=S;i.x=e[0]+t[0],i.y=e[1]+t[1],i.z=e[2]+t[2];const s=n.Cartesian3.clone(i,v),a=n.Cartesian3.clone(i,w),u=n.Cartesian3.clone(i,_),c=n.Cartesian3.clone(i,C),l=n.Cartesian3.clone(i,b),d=n.Cartesian3.clone(i,x),f=e.length;let p;for(p=0;p<f;p+=3){const r=e[p]+t[p],o=e[p+1]+t[p+1],f=e[p+2]+t[p+2];i.x=r,i.y=o,i.z=f,r<s.x&&n.Cartesian3.clone(i,s),r>c.x&&n.Cartesian3.clone(i,c),o<a.y&&n.Cartesian3.clone(i,a),o>l.y&&n.Cartesian3.clone(i,l),f<u.z&&n.Cartesian3.clone(i,u),f>d.z&&n.Cartesian3.clone(i,d)}const h=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(c,s,A)),m=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(l,a,A)),g=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(d,u,A));let R=s,T=c,q=h;m>q&&(q=m,R=a,T=l),g>q&&(q=g,R=u,T=d);const z=E;z.x=.5*(R.x+T.x),z.y=.5*(R.y+T.y),z.z=.5*(R.z+T.z);let M=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(T,z,A)),D=Math.sqrt(M);const U=O;U.x=s.x,U.y=a.y,U.z=u.z;const k=I;k.x=c.x,k.y=l.y,k.z=d.z;const F=n.Cartesian3.midpoint(U,k,P);let N=0;for(p=0;p<f;p+=3){i.x=e[p]+t[p],i.y=e[p+1]+t[p+1],i.z=e[p+2]+t[p+2];const r=n.Cartesian3.magnitude(n.Cartesian3.subtract(i,F,A));r>N&&(N=r);const o=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(i,z,A));if(o>M){const e=Math.sqrt(o);D=.5*(D+e),M=D*D;const t=e-D;z.x=(D*z.x+t*i.x)/e,z.y=(D*z.y+t*i.y)/e,z.z=(D*z.z+t*i.z)/e}}return D<N?(n.Cartesian3.clone(z,o.center),o.radius=D):(n.Cartesian3.clone(F,o.center),o.radius=N),o},y.fromCornerPoints=function(e,t,o){r.defined(o)||(o=new y);const i=n.Cartesian3.midpoint(e,t,o.center);return o.radius=n.Cartesian3.distance(i,t),o},y.fromEllipsoid=function(e,t){return r.defined(t)||(t=new y),n.Cartesian3.clone(n.Cartesian3.ZERO,t.center),t.radius=e.maximumRadius,t};const k=new n.Cartesian3;y.fromBoundingSpheres=function(e,t){if(r.defined(t)||(t=new y),!r.defined(e)||0===e.length)return t.center=n.Cartesian3.clone(n.Cartesian3.ZERO,t.center),t.radius=0,t;const o=e.length;if(1===o)return y.clone(e[0],t);if(2===o)return y.union(e[0],e[1],t);const i=[];let s;for(s=0;s<o;s++)i.push(e[s].center);const a=(t=y.fromPoints(i,t)).center;let u=t.radius;for(s=0;s<o;s++){const t=e[s];u=Math.max(u,n.Cartesian3.distance(a,t.center,k)+t.radius)}return t.radius=u,t};const F=new n.Cartesian3,N=new n.Cartesian3,j=new n.Cartesian3;y.fromOrientedBoundingBox=function(e,t){r.defined(t)||(t=new y);const o=e.halfAxes,i=n.Matrix3.getColumn(o,0,F),s=n.Matrix3.getColumn(o,1,N),a=n.Matrix3.getColumn(o,2,j);return n.Cartesian3.add(i,s,i),n.Cartesian3.add(i,a,i),t.center=n.Cartesian3.clone(e.center,t.center),t.radius=n.Cartesian3.magnitude(i),t};const B=new n.Cartesian3,V=new n.Cartesian3;y.fromTransformation=function(e,t){r.defined(t)||(t=new y);const o=i.Matrix4.getTranslation(e,B),s=i.Matrix4.getScale(e,V),a=.5*n.Cartesian3.magnitude(s);return t.center=n.Cartesian3.clone(o,t.center),t.radius=a,t},y.clone=function(e,t){if(r.defined(e))return r.defined(t)?(t.center=n.Cartesian3.clone(e.center,t.center),t.radius=e.radius,t):new y(e.center,e.radius)},y.packedLength=4,y.pack=function(e,t,n){n=r.defaultValue(n,0);const o=e.center;return t[n++]=o.x,t[n++]=o.y,t[n++]=o.z,t[n]=e.radius,t},y.unpack=function(e,t,n){t=r.defaultValue(t,0),r.defined(n)||(n=new y);const o=n.center;return o.x=e[t++],o.y=e[t++],o.z=e[t++],n.radius=e[t],n};const $=new n.Cartesian3,L=new n.Cartesian3;y.union=function(e,t,o){r.defined(o)||(o=new y);const i=e.center,s=e.radius,a=t.center,u=t.radius,c=n.Cartesian3.subtract(a,i,$),l=n.Cartesian3.magnitude(c);if(s>=l+u)return e.clone(o),o;if(u>=l+s)return t.clone(o),o;const d=.5*(s+l+u),f=n.Cartesian3.multiplyByScalar(c,(-s+d)/l,L);return n.Cartesian3.add(f,i,f),n.Cartesian3.clone(f,o.center),o.radius=d,o};const Q=new n.Cartesian3;y.expand=function(e,t,r){r=y.clone(e,r);const o=n.Cartesian3.magnitude(n.Cartesian3.subtract(t,r.center,Q));return o>r.radius&&(r.radius=o),r},y.intersectPlane=function(e,t){const r=e.center,o=e.radius,i=t.normal,s=n.Cartesian3.dot(i,r)+t.distance;return s<-o?m.OUTSIDE:s<o?m.INTERSECTING:m.INSIDE},y.transform=function(e,t,n){return r.defined(n)||(n=new y),n.center=i.Matrix4.multiplyByPoint(t,e.center,n.center),n.radius=i.Matrix4.getMaximumScale(t)*e.radius,n};const W=new n.Cartesian3;y.distanceSquaredTo=function(e,t){const r=n.Cartesian3.subtract(e.center,t,W),o=n.Cartesian3.magnitude(r)-e.radius;return o<=0?0:o*o},y.transformWithoutScale=function(e,t,n){return r.defined(n)||(n=new y),n.center=i.Matrix4.multiplyByPoint(t,e.center,n.center),n.radius=e.radius,n};const H=new n.Cartesian3;y.computePlaneDistances=function(e,t,o,i){r.defined(i)||(i=new g);const s=n.Cartesian3.subtract(e.center,t,H),a=n.Cartesian3.dot(o,s);return i.start=a-e.radius,i.stop=a+e.radius,i};const Y=new n.Cartesian3,Z=new n.Cartesian3,G=new n.Cartesian3,J=new n.Cartesian3,X=new n.Cartesian3,K=new n.Cartographic,ee=new Array(8);for(let e=0;e<8;++e)ee[e]=new n.Cartesian3;const te=new h;let ne;y.projectTo2D=function(e,t,o){const i=(t=r.defaultValue(t,te)).ellipsoid;let s=e.center;const a=e.radius;let u;u=n.Cartesian3.equals(s,n.Cartesian3.ZERO)?n.Cartesian3.clone(n.Cartesian3.UNIT_X,Y):i.geodeticSurfaceNormal(s,Y);const c=n.Cartesian3.cross(n.Cartesian3.UNIT_Z,u,Z);n.Cartesian3.normalize(c,c);const l=n.Cartesian3.cross(u,c,G);n.Cartesian3.normalize(l,l),n.Cartesian3.multiplyByScalar(u,a,u),n.Cartesian3.multiplyByScalar(l,a,l),n.Cartesian3.multiplyByScalar(c,a,c);const d=n.Cartesian3.negate(l,X),f=n.Cartesian3.negate(c,J),p=ee;let h=p[0];n.Cartesian3.add(u,l,h),n.Cartesian3.add(h,c,h),h=p[1],n.Cartesian3.add(u,l,h),n.Cartesian3.add(h,f,h),h=p[2],n.Cartesian3.add(u,d,h),n.Cartesian3.add(h,f,h),h=p[3],n.Cartesian3.add(u,d,h),n.Cartesian3.add(h,c,h),n.Cartesian3.negate(u,u),h=p[4],n.Cartesian3.add(u,l,h),n.Cartesian3.add(h,c,h),h=p[5],n.Cartesian3.add(u,l,h),n.Cartesian3.add(h,f,h),h=p[6],n.Cartesian3.add(u,d,h),n.Cartesian3.add(h,f,h),h=p[7],n.Cartesian3.add(u,d,h),n.Cartesian3.add(h,c,h);const m=p.length;for(let e=0;e<m;++e){const r=p[e];n.Cartesian3.add(s,r,r);const o=i.cartesianToCartographic(r,K);t.project(o,r)}s=(o=y.fromPoints(p,o)).center;const g=s.x,v=s.y,w=s.z;return s.x=w,s.y=g,s.z=v,o},y.isOccluded=function(e,t){return!t.isBoundingSphereVisible(e)},y.equals=function(e,t){return e===t||r.defined(e)&&r.defined(t)&&n.Cartesian3.equals(e.center,t.center)&&e.radius===t.radius},y.prototype.intersectPlane=function(e){return y.intersectPlane(this,e)},y.prototype.distanceSquaredTo=function(e){return y.distanceSquaredTo(this,e)},y.prototype.computePlaneDistances=function(e,t,n){return y.computePlaneDistances(this,e,t,n)},y.prototype.isOccluded=function(e){return y.isOccluded(this,e)},y.prototype.equals=function(e){return y.equals(this,e)},y.prototype.clone=function(e){return y.clone(this,e)},y.prototype.volume=function(){const e=this.radius;return R*e*e*e};const re={requestFullscreen:void 0,exitFullscreen:void 0,fullscreenEnabled:void 0,fullscreenElement:void 0,fullscreenchange:void 0,fullscreenerror:void 0},oe={};Object.defineProperties(oe,{element:{get:function(){if(oe.supportsFullscreen())return document[re.fullscreenElement]}},changeEventName:{get:function(){if(oe.supportsFullscreen())return re.fullscreenchange}},errorEventName:{get:function(){if(oe.supportsFullscreen())return re.fullscreenerror}},enabled:{get:function(){if(oe.supportsFullscreen())return document[re.fullscreenEnabled]}},fullscreen:{get:function(){if(oe.supportsFullscreen())return null!==oe.element}}}),oe.supportsFullscreen=function(){if(r.defined(ne))return ne;ne=!1;const e=document.body;if("function"==typeof e.requestFullscreen)return re.requestFullscreen="requestFullscreen",re.exitFullscreen="exitFullscreen",re.fullscreenEnabled="fullscreenEnabled",re.fullscreenElement="fullscreenElement",re.fullscreenchange="fullscreenchange",re.fullscreenerror="fullscreenerror",ne=!0,ne;const t=["webkit","moz","o","ms","khtml"];let n;for(let r=0,o=t.length;r<o;++r){const o=t[r];n=`${o}RequestFullscreen`,"function"==typeof e[n]?(re.requestFullscreen=n,ne=!0):(n=`${o}RequestFullScreen`,"function"==typeof e[n]&&(re.requestFullscreen=n,ne=!0)),n=`${o}ExitFullscreen`,"function"==typeof document[n]?re.exitFullscreen=n:(n=`${o}CancelFullScreen`,"function"==typeof document[n]&&(re.exitFullscreen=n)),n=`${o}FullscreenEnabled`,void 0!==document[n]?re.fullscreenEnabled=n:(n=`${o}FullScreenEnabled`,void 0!==document[n]&&(re.fullscreenEnabled=n)),n=`${o}FullscreenElement`,void 0!==document[n]?re.fullscreenElement=n:(n=`${o}FullScreenElement`,void 0!==document[n]&&(re.fullscreenElement=n)),n=`${o}fullscreenchange`,void 0!==document[`on${n}`]&&("ms"===o&&(n="MSFullscreenChange"),re.fullscreenchange=n),n=`${o}fullscreenerror`,void 0!==document[`on${n}`]&&("ms"===o&&(n="MSFullscreenError"),re.fullscreenerror=n)}return ne},oe.requestFullscreen=function(e,t){oe.supportsFullscreen()&&e[re.requestFullscreen]({vrDisplay:t})},oe.exitFullscreen=function(){oe.supportsFullscreen()&&document[re.exitFullscreen]()},oe._names=re;var ie=oe;let se,ae,ue,ce,le,de,fe,pe,he,me,ge,ye,ve,we,_e,Ce,be,xe;function Se(e){const t=e.split(".");for(let e=0,n=t.length;e<n;++e)t[e]=parseInt(t[e],10);return t}function Ae(){if(!r.defined(ae)&&(ae=!1,!Pe())){const e=/ Chrome\/([\.0-9]+)/.exec(se.userAgent);null!==e&&(ae=!0,ue=Se(e[1]))}return ae}function Ee(){if(!r.defined(ce)&&(ce=!1,!Ae()&&!Pe()&&/ Safari\/[\.0-9]+/.test(se.userAgent))){const e=/ Version\/([\.0-9]+)/.exec(se.userAgent);null!==e&&(ce=!0,le=Se(e[1]))}return ce}function Oe(){if(!r.defined(de)){de=!1;const e=/ AppleWebKit\/([\.0-9]+)(\+?)/.exec(se.userAgent);null!==e&&(de=!0,fe=Se(e[1]),fe.isNightly=!!e[2])}return de}function Ie(){if(!r.defined(pe)){let e;pe=!1,"Microsoft Internet Explorer"===se.appName?(e=/MSIE ([0-9]{1,}[\.0-9]{0,})/.exec(se.userAgent),null!==e&&(pe=!0,he=Se(e[1]))):"Netscape"===se.appName&&(e=/Trident\/.*rv:([0-9]{1,}[\.0-9]{0,})/.exec(se.userAgent),null!==e&&(pe=!0,he=Se(e[1])))}return pe}function Pe(){if(!r.defined(me)){me=!1;const e=/ Edg\/([\.0-9]+)/.exec(se.userAgent);null!==e&&(me=!0,ge=Se(e[1]))}return me}function Re(){if(!r.defined(ye)){ye=!1;const e=/Firefox\/([\.0-9]+)/.exec(se.userAgent);null!==e&&(ye=!0,ve=Se(e[1]))}return ye}function Te(){if(!r.defined(xe)){const e=document.createElement("canvas");e.setAttribute("style","image-rendering: -moz-crisp-edges;image-rendering: pixelated;");const t=e.style.imageRendering;xe=r.defined(t)&&""!==t,xe&&(be=t)}return xe}function qe(){return qe._result}se="undefined"!=typeof navigator?navigator:{},qe._promise=void 0,qe._result=void 0,qe.initialize=function(){return r.defined(qe._promise)||(qe._promise=new Promise((e=>{const t=new Image;t.onload=function(){qe._result=t.width>0&&t.height>0,e(qe._result)},t.onerror=function(){qe._result=!1,e(qe._result)},t.src="data:image/webp;base64,UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA"}))),qe._promise},Object.defineProperties(qe,{initialized:{get:function(){return r.defined(qe._result)}}});const ze=[];"undefined"!=typeof ArrayBuffer&&(ze.push(Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array),"undefined"!=typeof Uint8ClampedArray&&ze.push(Uint8ClampedArray),"undefined"!=typeof Uint8ClampedArray&&ze.push(Uint8ClampedArray),"undefined"!=typeof BigInt64Array&&ze.push(BigInt64Array),"undefined"!=typeof BigUint64Array&&ze.push(BigUint64Array));const Me={isChrome:Ae,chromeVersion:function(){return Ae()&&ue},isSafari:Ee,safariVersion:function(){return Ee()&&le},isWebkit:Oe,webkitVersion:function(){return Oe()&&fe},isInternetExplorer:Ie,internetExplorerVersion:function(){return Ie()&&he},isEdge:Pe,edgeVersion:function(){return Pe()&&ge},isFirefox:Re,firefoxVersion:function(){return Re()&&ve},isWindows:function(){return r.defined(we)||(we=/Windows/i.test(se.appVersion)),we},isIPadOrIOS:function(){return r.defined(_e)||(_e="iPhone"===navigator.platform||"iPod"===navigator.platform||"iPad"===navigator.platform),_e},hardwareConcurrency:r.defaultValue(se.hardwareConcurrency,3),supportsPointerEvents:function(){return r.defined(Ce)||(Ce=!Re()&&"undefined"!=typeof PointerEvent&&(!r.defined(se.pointerEnabled)||se.pointerEnabled)),Ce},supportsImageRenderingPixelated:Te,supportsWebP:qe,imageRenderingValue:function(){return Te()?be:void 0},typedArrayTypes:ze,supportsBasis:function(e){return Me.supportsWebAssembly()&&e.context.supportsBasis},supportsFullscreen:function(){return ie.supportsFullscreen()},supportsTypedArrays:function(){return"undefined"!=typeof ArrayBuffer},supportsBigInt64Array:function(){return"undefined"!=typeof BigInt64Array},supportsBigUint64Array:function(){return"undefined"!=typeof BigUint64Array},supportsBigInt:function(){return"undefined"!=typeof BigInt},supportsWebWorkers:function(){return"undefined"!=typeof Worker},supportsWebAssembly:function(){return"undefined"!=typeof WebAssembly}};var De=Me;function Ue(e,t,n,o){this.x=r.defaultValue(e,0),this.y=r.defaultValue(t,0),this.z=r.defaultValue(n,0),this.w=r.defaultValue(o,0)}let ke=new n.Cartesian3;Ue.fromAxisAngle=function(e,t,o){const i=t/2,s=Math.sin(i);ke=n.Cartesian3.normalize(e,ke);const a=ke.x*s,u=ke.y*s,c=ke.z*s,l=Math.cos(i);return r.defined(o)?(o.x=a,o.y=u,o.z=c,o.w=l,o):new Ue(a,u,c,l)};const Fe=[1,2,0],Ne=new Array(3);Ue.fromRotationMatrix=function(e,t){let o,i,s,a,u;const c=e[n.Matrix3.COLUMN0ROW0],l=e[n.Matrix3.COLUMN1ROW1],d=e[n.Matrix3.COLUMN2ROW2],f=c+l+d;if(f>0)o=Math.sqrt(f+1),u=.5*o,o=.5/o,i=(e[n.Matrix3.COLUMN1ROW2]-e[n.Matrix3.COLUMN2ROW1])*o,s=(e[n.Matrix3.COLUMN2ROW0]-e[n.Matrix3.COLUMN0ROW2])*o,a=(e[n.Matrix3.COLUMN0ROW1]-e[n.Matrix3.COLUMN1ROW0])*o;else{const t=Fe;let r=0;l>c&&(r=1),d>c&&d>l&&(r=2);const f=t[r],p=t[f];o=Math.sqrt(e[n.Matrix3.getElementIndex(r,r)]-e[n.Matrix3.getElementIndex(f,f)]-e[n.Matrix3.getElementIndex(p,p)]+1);const h=Ne;h[r]=.5*o,o=.5/o,u=(e[n.Matrix3.getElementIndex(p,f)]-e[n.Matrix3.getElementIndex(f,p)])*o,h[f]=(e[n.Matrix3.getElementIndex(f,r)]+e[n.Matrix3.getElementIndex(r,f)])*o,h[p]=(e[n.Matrix3.getElementIndex(p,r)]+e[n.Matrix3.getElementIndex(r,p)])*o,i=-h[0],s=-h[1],a=-h[2]}return r.defined(t)?(t.x=i,t.y=s,t.z=a,t.w=u,t):new Ue(i,s,a,u)};const je=new Ue;let Be=new Ue,Ve=new Ue,$e=new Ue;Ue.fromHeadingPitchRoll=function(e,t){return $e=Ue.fromAxisAngle(n.Cartesian3.UNIT_X,e.roll,je),Ve=Ue.fromAxisAngle(n.Cartesian3.UNIT_Y,-e.pitch,t),t=Ue.multiply(Ve,$e,Ve),Be=Ue.fromAxisAngle(n.Cartesian3.UNIT_Z,-e.heading,je),Ue.multiply(Be,t,t)};const Le=new n.Cartesian3,Qe=new n.Cartesian3,We=new Ue,He=new Ue,Ye=new Ue;Ue.packedLength=4,Ue.pack=function(e,t,n){return n=r.defaultValue(n,0),t[n++]=e.x,t[n++]=e.y,t[n++]=e.z,t[n]=e.w,t},Ue.unpack=function(e,t,n){return t=r.defaultValue(t,0),r.defined(n)||(n=new Ue),n.x=e[t],n.y=e[t+1],n.z=e[t+2],n.w=e[t+3],n},Ue.packedInterpolationLength=3,Ue.convertPackedArrayForInterpolation=function(e,t,n,o){Ue.unpack(e,4*n,Ye),Ue.conjugate(Ye,Ye);for(let i=0,s=n-t+1;i<s;i++){const n=3*i;Ue.unpack(e,4*(t+i),We),Ue.multiply(We,Ye,We),We.w<0&&Ue.negate(We,We),Ue.computeAxis(We,Le);const s=Ue.computeAngle(We);r.defined(o)||(o=[]),o[n]=Le.x*s,o[n+1]=Le.y*s,o[n+2]=Le.z*s}},Ue.unpackInterpolationResult=function(e,t,o,i,s){r.defined(s)||(s=new Ue),n.Cartesian3.fromArray(e,0,Qe);const a=n.Cartesian3.magnitude(Qe);return Ue.unpack(t,4*i,He),0===a?Ue.clone(Ue.IDENTITY,We):Ue.fromAxisAngle(Qe,a,We),Ue.multiply(We,He,s)},Ue.clone=function(e,t){if(r.defined(e))return r.defined(t)?(t.x=e.x,t.y=e.y,t.z=e.z,t.w=e.w,t):new Ue(e.x,e.y,e.z,e.w)},Ue.conjugate=function(e,t){return t.x=-e.x,t.y=-e.y,t.z=-e.z,t.w=e.w,t},Ue.magnitudeSquared=function(e){return e.x*e.x+e.y*e.y+e.z*e.z+e.w*e.w},Ue.magnitude=function(e){return Math.sqrt(Ue.magnitudeSquared(e))},Ue.normalize=function(e,t){const n=1/Ue.magnitude(e),r=e.x*n,o=e.y*n,i=e.z*n,s=e.w*n;return t.x=r,t.y=o,t.z=i,t.w=s,t},Ue.inverse=function(e,t){const n=Ue.magnitudeSquared(e);return t=Ue.conjugate(e,t),Ue.multiplyByScalar(t,1/n,t)},Ue.add=function(e,t,n){return n.x=e.x+t.x,n.y=e.y+t.y,n.z=e.z+t.z,n.w=e.w+t.w,n},Ue.subtract=function(e,t,n){return n.x=e.x-t.x,n.y=e.y-t.y,n.z=e.z-t.z,n.w=e.w-t.w,n},Ue.negate=function(e,t){return t.x=-e.x,t.y=-e.y,t.z=-e.z,t.w=-e.w,t},Ue.dot=function(e,t){return e.x*t.x+e.y*t.y+e.z*t.z+e.w*t.w},Ue.multiply=function(e,t,n){const r=e.x,o=e.y,i=e.z,s=e.w,a=t.x,u=t.y,c=t.z,l=t.w,d=s*a+r*l+o*c-i*u,f=s*u-r*c+o*l+i*a,p=s*c+r*u-o*a+i*l,h=s*l-r*a-o*u-i*c;return n.x=d,n.y=f,n.z=p,n.w=h,n},Ue.multiplyByScalar=function(e,t,n){return n.x=e.x*t,n.y=e.y*t,n.z=e.z*t,n.w=e.w*t,n},Ue.divideByScalar=function(e,t,n){return n.x=e.x/t,n.y=e.y/t,n.z=e.z/t,n.w=e.w/t,n},Ue.computeAxis=function(e,t){const n=e.w;if(Math.abs(n-1)<o.CesiumMath.EPSILON6)return t.x=t.y=t.z=0,t;const r=1/Math.sqrt(1-n*n);return t.x=e.x*r,t.y=e.y*r,t.z=e.z*r,t},Ue.computeAngle=function(e){return Math.abs(e.w-1)<o.CesiumMath.EPSILON6?0:2*Math.acos(e.w)};let Ze=new Ue;Ue.lerp=function(e,t,n,r){return Ze=Ue.multiplyByScalar(t,n,Ze),r=Ue.multiplyByScalar(e,1-n,r),Ue.add(Ze,r,r)};let Ge=new Ue,Je=new Ue,Xe=new Ue;Ue.slerp=function(e,t,n,r){let i=Ue.dot(e,t),s=t;if(i<0&&(i=-i,s=Ge=Ue.negate(t,Ge)),1-i<o.CesiumMath.EPSILON6)return Ue.lerp(e,s,n,r);const a=Math.acos(i);return Je=Ue.multiplyByScalar(e,Math.sin((1-n)*a),Je),Xe=Ue.multiplyByScalar(s,Math.sin(n*a),Xe),r=Ue.add(Je,Xe,r),Ue.multiplyByScalar(r,1/Math.sin(a),r)},Ue.log=function(e,t){const r=o.CesiumMath.acosClamped(e.w);let i=0;return 0!==r&&(i=r/Math.sin(r)),n.Cartesian3.multiplyByScalar(e,i,t)},Ue.exp=function(e,t){const r=n.Cartesian3.magnitude(e);let o=0;return 0!==r&&(o=Math.sin(r)/r),t.x=e.x*o,t.y=e.y*o,t.z=e.z*o,t.w=Math.cos(r),t};const Ke=new n.Cartesian3,et=new n.Cartesian3,tt=new Ue,nt=new Ue;Ue.computeInnerQuadrangle=function(e,t,r,o){const i=Ue.conjugate(t,tt);Ue.multiply(i,r,nt);const s=Ue.log(nt,Ke);Ue.multiply(i,e,nt);const a=Ue.log(nt,et);return n.Cartesian3.add(s,a,s),n.Cartesian3.multiplyByScalar(s,.25,s),n.Cartesian3.negate(s,s),Ue.exp(s,tt),Ue.multiply(t,tt,o)},Ue.squad=function(e,t,n,r,o,i){const s=Ue.slerp(e,t,o,tt),a=Ue.slerp(n,r,o,nt);return Ue.slerp(s,a,2*o*(1-o),i)};const rt=new Ue,ot=1.9011074535173003,it=De.supportsTypedArrays()?new Float32Array(8):[],st=De.supportsTypedArrays()?new Float32Array(8):[],at=De.supportsTypedArrays()?new Float32Array(8):[],ut=De.supportsTypedArrays()?new Float32Array(8):[];for(let e=0;e<7;++e){const t=e+1,n=2*t+1;it[e]=1/(t*n),st[e]=t/n}function ct(e,t,n){let r,o,i=0,s=e.length-1;for(;i<=s;)if(r=~~((i+s)/2),o=n(e[r],t),o<0)i=r+1;else{if(!(o>0))return r;s=r-1}return~(s+1)}function lt(e,t,n,r,o){this.xPoleWander=e,this.yPoleWander=t,this.xPoleOffset=n,this.yPoleOffset=r,this.ut1MinusUtc=o}function dt(e,t,n,r,o,i,s,a){this.year=e,this.month=t,this.day=n,this.hour=r,this.minute=o,this.second=i,this.millisecond=s,this.isLeapSecond=a}function ft(e){return e%4==0&&e%100!=0||e%400==0}function pt(e,t){this.julianDate=e,this.offset=t}it[7]=ot/136,st[7]=8*ot/17,Ue.fastSlerp=function(e,t,n,r){let o,i=Ue.dot(e,t);i>=0?o=1:(o=-1,i=-i);const s=i-1,a=1-n,u=n*n,c=a*a;for(let e=7;e>=0;--e)at[e]=(it[e]*u-st[e])*s,ut[e]=(it[e]*c-st[e])*s;const l=o*n*(1+at[0]*(1+at[1]*(1+at[2]*(1+at[3]*(1+at[4]*(1+at[5]*(1+at[6]*(1+at[7])))))))),d=a*(1+ut[0]*(1+ut[1]*(1+ut[2]*(1+ut[3]*(1+ut[4]*(1+ut[5]*(1+ut[6]*(1+ut[7])))))))),f=Ue.multiplyByScalar(e,d,rt);return Ue.multiplyByScalar(t,l,r),Ue.add(f,r,r)},Ue.fastSquad=function(e,t,n,r,o,i){const s=Ue.fastSlerp(e,t,o,tt),a=Ue.fastSlerp(n,r,o,nt);return Ue.fastSlerp(s,a,2*o*(1-o),i)},Ue.equals=function(e,t){return e===t||r.defined(e)&&r.defined(t)&&e.x===t.x&&e.y===t.y&&e.z===t.z&&e.w===t.w},Ue.equalsEpsilon=function(e,t,n){return n=r.defaultValue(n,0),e===t||r.defined(e)&&r.defined(t)&&Math.abs(e.x-t.x)<=n&&Math.abs(e.y-t.y)<=n&&Math.abs(e.z-t.z)<=n&&Math.abs(e.w-t.w)<=n},Ue.ZERO=Object.freeze(new Ue(0,0,0,0)),Ue.IDENTITY=Object.freeze(new Ue(0,0,0,1)),Ue.prototype.clone=function(e){return Ue.clone(this,e)},Ue.prototype.equals=function(e){return Ue.equals(this,e)},Ue.prototype.equalsEpsilon=function(e,t){return Ue.equalsEpsilon(this,e,t)},Ue.prototype.toString=function(){return`(${this.x}, ${this.y}, ${this.z}, ${this.w})`};var ht=Object.freeze({SECONDS_PER_MILLISECOND:.001,SECONDS_PER_MINUTE:60,MINUTES_PER_HOUR:60,HOURS_PER_DAY:24,SECONDS_PER_HOUR:3600,MINUTES_PER_DAY:1440,SECONDS_PER_DAY:86400,DAYS_PER_JULIAN_CENTURY:36525,PICOSECOND:1e-9,MODIFIED_JULIAN_DATE_DIFFERENCE:2400000.5});var mt=Object.freeze({UTC:0,TAI:1});const gt=new dt,yt=[31,28,31,30,31,30,31,31,30,31,30,31];function vt(e,t){return zt.compare(e.julianDate,t.julianDate)}const wt=new pt;function _t(e){wt.julianDate=e;const t=zt.leapSeconds;let n=ct(t,wt,vt);n<0&&(n=~n),n>=t.length&&(n=t.length-1);let r=t[n].offset;if(n>0){zt.secondsDifference(t[n].julianDate,e)>r&&(n--,r=t[n].offset)}zt.addSeconds(e,r,e)}function Ct(e,t){wt.julianDate=e;const n=zt.leapSeconds;let r=ct(n,wt,vt);if(r<0&&(r=~r),0===r)return zt.addSeconds(e,-n[0].offset,t);if(r>=n.length)return zt.addSeconds(e,-n[r-1].offset,t);const o=zt.secondsDifference(n[r].julianDate,e);return 0===o?zt.addSeconds(e,-n[r].offset,t):o<=1?void 0:zt.addSeconds(e,-n[--r].offset,t)}function bt(e,t,n){const r=t/ht.SECONDS_PER_DAY|0;return e+=r,(t-=ht.SECONDS_PER_DAY*r)<0&&(e--,t+=ht.SECONDS_PER_DAY),n.dayNumber=e,n.secondsOfDay=t,n}function xt(e,t,n,r,o,i,s){const a=(t-14)/12|0,u=e+4800+a;let c=(1461*u/4|0)+(367*(t-2-12*a)/12|0)-(3*((u+100)/100|0)/4|0)+n-32075;(r-=12)<0&&(r+=24);const l=i+(r*ht.SECONDS_PER_HOUR+o*ht.SECONDS_PER_MINUTE+s*ht.SECONDS_PER_MILLISECOND);return l>=43200&&(c-=1),[c,l]}const St=/^(\d{4})$/,At=/^(\d{4})-(\d{2})$/,Et=/^(\d{4})-?(\d{3})$/,Ot=/^(\d{4})-?W(\d{2})-?(\d{1})?$/,It=/^(\d{4})-?(\d{2})-?(\d{2})$/,Pt=/([Z+\-])?(\d{2})?:?(\d{2})?$/,Rt=/^(\d{2})(\.\d+)?/.source+Pt.source,Tt=/^(\d{2}):?(\d{2})(\.\d+)?/.source+Pt.source,qt=/^(\d{2}):?(\d{2}):?(\d{2})(\.\d+)?/.source+Pt.source;function zt(e,t,n){this.dayNumber=void 0,this.secondsOfDay=void 0,e=r.defaultValue(e,0),t=r.defaultValue(t,0),n=r.defaultValue(n,mt.UTC);const o=0|e;bt(o,t+=(e-o)*ht.SECONDS_PER_DAY,this),n===mt.UTC&&_t(this)}zt.fromGregorianDate=function(e,t){const n=xt(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond);return r.defined(t)?(bt(n[0],n[1],t),_t(t),t):new zt(n[0],n[1],mt.UTC)},zt.fromDate=function(e,t){const n=xt(e.getUTCFullYear(),e.getUTCMonth()+1,e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds());return r.defined(t)?(bt(n[0],n[1],t),_t(t),t):new zt(n[0],n[1],mt.UTC)},zt.fromIso8601=function(e,t){let n,o=(e=e.replace(",",".")).split("T"),i=1,s=1,a=0,u=0,c=0,l=0;const d=o[0],f=o[1];let p,h,m;if(o=d.match(It),null!==o)n=+o[1],i=+o[2],s=+o[3];else if(o=d.match(At),null!==o)n=+o[1],i=+o[2];else if(o=d.match(St),null!==o)n=+o[1];else{let e;if(o=d.match(Et),null!==o)n=+o[1],e=+o[2],h=ft(n);else if(o=d.match(Ot),null!==o){n=+o[1];e=7*+o[2]+(+o[3]||0)-new Date(Date.UTC(n,0,4)).getUTCDay()-3}p=new Date(Date.UTC(n,0,1)),p.setUTCDate(e),i=p.getUTCMonth()+1,s=p.getUTCDate()}if(h=ft(n),r.defined(f)){o=f.match(qt),null!==o?(a=+o[1],u=+o[2],c=+o[3],l=1e3*+(o[4]||0),m=5):(o=f.match(Tt),null!==o?(a=+o[1],u=+o[2],c=60*+(o[3]||0),m=4):(o=f.match(Rt),null!==o&&(a=+o[1],u=60*+(o[2]||0),m=3)));const e=o[m],t=+o[m+1],r=+(o[m+2]||0);switch(e){case"+":a-=t,u-=r;break;case"-":a+=t,u+=r;break;case"Z":break;default:u+=new Date(Date.UTC(n,i-1,s,a,u)).getTimezoneOffset()}}const g=60===c;for(g&&c--;u>=60;)u-=60,a++;for(;a>=24;)a-=24,s++;for(p=h&&2===i?29:yt[i-1];s>p;)s-=p,i++,i>12&&(i-=12,n++),p=h&&2===i?29:yt[i-1];for(;u<0;)u+=60,a--;for(;a<0;)a+=24,s--;for(;s<1;)i--,i<1&&(i+=12,n--),p=h&&2===i?29:yt[i-1],s+=p;const y=xt(n,i,s,a,u,c,l);return r.defined(t)?(bt(y[0],y[1],t),_t(t)):t=new zt(y[0],y[1],mt.UTC),g&&zt.addSeconds(t,1,t),t},zt.now=function(e){return zt.fromDate(new Date,e)};const Mt=new zt(0,0,mt.TAI);zt.toGregorianDate=function(e,t){let n=!1,o=Ct(e,Mt);r.defined(o)||(zt.addSeconds(e,-1,Mt),o=Ct(Mt,Mt),n=!0);let i=o.dayNumber;const s=o.secondsOfDay;s>=43200&&(i+=1);let a=i+68569|0;const u=4*a/146097|0;a=a-((146097*u+3)/4|0)|0;const c=4e3*(a+1)/1461001|0;a=a-(1461*c/4|0)+31|0;const l=80*a/2447|0,d=a-(2447*l/80|0)|0;a=l/11|0;const f=l+2-12*a|0,p=100*(u-49)+c+a|0;let h=s/ht.SECONDS_PER_HOUR|0,m=s-h*ht.SECONDS_PER_HOUR;const g=m/ht.SECONDS_PER_MINUTE|0;m-=g*ht.SECONDS_PER_MINUTE;let y=0|m;const v=(m-y)/ht.SECONDS_PER_MILLISECOND;return h+=12,h>23&&(h-=24),n&&(y+=1),r.defined(t)?(t.year=p,t.month=f,t.day=d,t.hour=h,t.minute=g,t.second=y,t.millisecond=v,t.isLeapSecond=n,t):new dt(p,f,d,h,g,y,v,n)},zt.toDate=function(e){const t=zt.toGregorianDate(e,gt);let n=t.second;return t.isLeapSecond&&(n-=1),new Date(Date.UTC(t.year,t.month-1,t.day,t.hour,t.minute,n,t.millisecond))},zt.toIso8601=function(e,t){const n=zt.toGregorianDate(e,gt);let o=n.year,i=n.month,s=n.day,a=n.hour;const u=n.minute,c=n.second,l=n.millisecond;let d;return 1e4===o&&1===i&&1===s&&0===a&&0===u&&0===c&&0===l&&(o=9999,i=12,s=31,a=24),r.defined(t)||0===l?r.defined(t)&&0!==t?(d=(.01*l).toFixed(t).replace(".","").slice(0,t),`${o.toString().padStart(4,"0")}-${i.toString().padStart(2,"0")}-${s.toString().padStart(2,"0")}T${a.toString().padStart(2,"0")}:${u.toString().padStart(2,"0")}:${c.toString().padStart(2,"0")}.${d}Z`):`${o.toString().padStart(4,"0")}-${i.toString().padStart(2,"0")}-${s.toString().padStart(2,"0")}T${a.toString().padStart(2,"0")}:${u.toString().padStart(2,"0")}:${c.toString().padStart(2,"0")}Z`:(d=(.01*l).toString().replace(".",""),`${o.toString().padStart(4,"0")}-${i.toString().padStart(2,"0")}-${s.toString().padStart(2,"0")}T${a.toString().padStart(2,"0")}:${u.toString().padStart(2,"0")}:${c.toString().padStart(2,"0")}.${d}Z`)},zt.clone=function(e,t){if(r.defined(e))return r.defined(t)?(t.dayNumber=e.dayNumber,t.secondsOfDay=e.secondsOfDay,t):new zt(e.dayNumber,e.secondsOfDay,mt.TAI)},zt.compare=function(e,t){const n=e.dayNumber-t.dayNumber;return 0!==n?n:e.secondsOfDay-t.secondsOfDay},zt.equals=function(e,t){return e===t||r.defined(e)&&r.defined(t)&&e.dayNumber===t.dayNumber&&e.secondsOfDay===t.secondsOfDay},zt.equalsEpsilon=function(e,t,n){return n=r.defaultValue(n,0),e===t||r.defined(e)&&r.defined(t)&&Math.abs(zt.secondsDifference(e,t))<=n},zt.totalDays=function(e){return e.dayNumber+e.secondsOfDay/ht.SECONDS_PER_DAY},zt.secondsDifference=function(e,t){return(e.dayNumber-t.dayNumber)*ht.SECONDS_PER_DAY+(e.secondsOfDay-t.secondsOfDay)},zt.daysDifference=function(e,t){return e.dayNumber-t.dayNumber+(e.secondsOfDay-t.secondsOfDay)/ht.SECONDS_PER_DAY},zt.computeTaiMinusUtc=function(e){wt.julianDate=e;const t=zt.leapSeconds;let n=ct(t,wt,vt);return n<0&&(n=~n,--n,n<0&&(n=0)),t[n].offset},zt.addSeconds=function(e,t,n){return bt(e.dayNumber,e.secondsOfDay+t,n)},zt.addMinutes=function(e,t,n){const r=e.secondsOfDay+t*ht.SECONDS_PER_MINUTE;return bt(e.dayNumber,r,n)},zt.addHours=function(e,t,n){const r=e.secondsOfDay+t*ht.SECONDS_PER_HOUR;return bt(e.dayNumber,r,n)},zt.addDays=function(e,t,n){return bt(e.dayNumber+t,e.secondsOfDay,n)},zt.lessThan=function(e,t){return zt.compare(e,t)<0},zt.lessThanOrEquals=function(e,t){return zt.compare(e,t)<=0},zt.greaterThan=function(e,t){return zt.compare(e,t)>0},zt.greaterThanOrEquals=function(e,t){return zt.compare(e,t)>=0},zt.prototype.clone=function(e){return zt.clone(this,e)},zt.prototype.equals=function(e){return zt.equals(this,e)},zt.prototype.equalsEpsilon=function(e,t){return zt.equalsEpsilon(this,e,t)},zt.prototype.toString=function(){return zt.toIso8601(this)},zt.leapSeconds=[new pt(new zt(2441317,43210,mt.TAI),10),new pt(new zt(2441499,43211,mt.TAI),11),new pt(new zt(2441683,43212,mt.TAI),12),new pt(new zt(2442048,43213,mt.TAI),13),new pt(new zt(2442413,43214,mt.TAI),14),new pt(new zt(2442778,43215,mt.TAI),15),new pt(new zt(2443144,43216,mt.TAI),16),new pt(new zt(2443509,43217,mt.TAI),17),new pt(new zt(2443874,43218,mt.TAI),18),new pt(new zt(2444239,43219,mt.TAI),19),new pt(new zt(2444786,43220,mt.TAI),20),new pt(new zt(2445151,43221,mt.TAI),21),new pt(new zt(2445516,43222,mt.TAI),22),new pt(new zt(2446247,43223,mt.TAI),23),new pt(new zt(2447161,43224,mt.TAI),24),new pt(new zt(2447892,43225,mt.TAI),25),new pt(new zt(2448257,43226,mt.TAI),26),new pt(new zt(2448804,43227,mt.TAI),27),new pt(new zt(2449169,43228,mt.TAI),28),new pt(new zt(2449534,43229,mt.TAI),29),new pt(new zt(2450083,43230,mt.TAI),30),new pt(new zt(2450630,43231,mt.TAI),31),new pt(new zt(2451179,43232,mt.TAI),32),new pt(new zt(2453736,43233,mt.TAI),33),new pt(new zt(2454832,43234,mt.TAI),34),new pt(new zt(2456109,43235,mt.TAI),35),new pt(new zt(2457204,43236,mt.TAI),36),new pt(new zt(2457754,43237,mt.TAI),37)];var Dt,Ut={exports:{}},kt={exports:{}};var Ft,Nt={exports:{}}; |
| | | define(["require","exports","./Matrix3-a3d5aaa7","./defaultValue-865ac579","./Math-76ce6367","./Matrix2-4d660f1f","./combine-5e110d09","./RuntimeError-9e0724f9"],(function(e,t,n,r,o,i,s,a){"use strict";function u(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}function c(e){let t;this.name="DeveloperError",this.message=e;try{throw new Error}catch(e){t=e.stack}this.stack=t}r.defined(Object.create)&&(c.prototype=Object.create(Error.prototype),c.prototype.constructor=c),c.prototype.toString=function(){let e=`${this.name}: ${this.message}`;return r.defined(this.stack)&&(e+=`\n${this.stack.toString()}`),e},c.throwInstantiationError=function(){throw new c("This function defines an interface and should not be called directly.")};const l={};function d(e,t,n){return`Expected ${n} to be typeof ${t}, actual typeof was ${e}`}l.typeOf={},l.defined=function(e,t){if(!r.defined(t))throw new c(function(e){return`${e} is required, actual value was undefined`}(e))},l.typeOf.func=function(e,t){if("function"!=typeof t)throw new c(d(typeof t,"function",e))},l.typeOf.string=function(e,t){if("string"!=typeof t)throw new c(d(typeof t,"string",e))},l.typeOf.number=function(e,t){if("number"!=typeof t)throw new c(d(typeof t,"number",e))},l.typeOf.number.lessThan=function(e,t,n){if(l.typeOf.number(e,t),t>=n)throw new c(`Expected ${e} to be less than ${n}, actual value was ${t}`)},l.typeOf.number.lessThanOrEquals=function(e,t,n){if(l.typeOf.number(e,t),t>n)throw new c(`Expected ${e} to be less than or equal to ${n}, actual value was ${t}`)},l.typeOf.number.greaterThan=function(e,t,n){if(l.typeOf.number(e,t),t<=n)throw new c(`Expected ${e} to be greater than ${n}, actual value was ${t}`)},l.typeOf.number.greaterThanOrEquals=function(e,t,n){if(l.typeOf.number(e,t),t<n)throw new c(`Expected ${e} to be greater than or equal to ${n}, actual value was ${t}`)},l.typeOf.object=function(e,t){if("object"!=typeof t)throw new c(d(typeof t,"object",e))},l.typeOf.bool=function(e,t){if("boolean"!=typeof t)throw new c(d(typeof t,"boolean",e))},l.typeOf.bigint=function(e,t){if("bigint"!=typeof t)throw new c(d(typeof t,"bigint",e))},l.typeOf.number.equals=function(e,t,n,r){if(l.typeOf.number(e,n),l.typeOf.number(t,r),n!==r)throw new c(`${e} must be equal to ${t}, the actual values are ${n} and ${r}`)};var f=l,p="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function h(e){this._ellipsoid=r.defaultValue(e,n.Ellipsoid.WGS84),this._semimajorAxis=this._ellipsoid.maximumRadius,this._oneOverSemimajorAxis=1/this._semimajorAxis}Object.defineProperties(h.prototype,{ellipsoid:{get:function(){return this._ellipsoid}}}),h.prototype.project=function(e,t){const o=this._semimajorAxis,i=e.longitude*o,s=e.latitude*o,a=e.height;return r.defined(t)?(t.x=i,t.y=s,t.z=a,t):new n.Cartesian3(i,s,a)},h.prototype.unproject=function(e,t){const o=this._oneOverSemimajorAxis,i=e.x*o,s=e.y*o,a=e.z;return r.defined(t)?(t.longitude=i,t.latitude=s,t.height=a,t):new n.Cartographic(i,s,a)};var m=Object.freeze({OUTSIDE:-1,INTERSECTING:0,INSIDE:1});function g(e,t){this.start=r.defaultValue(e,0),this.stop=r.defaultValue(t,0)}function y(e,t){this.center=n.Cartesian3.clone(r.defaultValue(e,n.Cartesian3.ZERO)),this.radius=r.defaultValue(t,0)}const v=new n.Cartesian3,w=new n.Cartesian3,_=new n.Cartesian3,C=new n.Cartesian3,b=new n.Cartesian3,x=new n.Cartesian3,S=new n.Cartesian3,A=new n.Cartesian3,E=new n.Cartesian3,O=new n.Cartesian3,I=new n.Cartesian3,P=new n.Cartesian3,R=4/3*o.CesiumMath.PI;y.fromPoints=function(e,t){if(r.defined(t)||(t=new y),!r.defined(e)||0===e.length)return t.center=n.Cartesian3.clone(n.Cartesian3.ZERO,t.center),t.radius=0,t;const o=n.Cartesian3.clone(e[0],S),i=n.Cartesian3.clone(o,v),s=n.Cartesian3.clone(o,w),a=n.Cartesian3.clone(o,_),u=n.Cartesian3.clone(o,C),c=n.Cartesian3.clone(o,b),l=n.Cartesian3.clone(o,x),d=e.length;let f;for(f=1;f<d;f++){n.Cartesian3.clone(e[f],o);const t=o.x,r=o.y,d=o.z;t<i.x&&n.Cartesian3.clone(o,i),t>u.x&&n.Cartesian3.clone(o,u),r<s.y&&n.Cartesian3.clone(o,s),r>c.y&&n.Cartesian3.clone(o,c),d<a.z&&n.Cartesian3.clone(o,a),d>l.z&&n.Cartesian3.clone(o,l)}const p=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(u,i,A)),h=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(c,s,A)),m=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(l,a,A));let g=i,R=u,T=p;h>T&&(T=h,g=s,R=c),m>T&&(T=m,g=a,R=l);const q=E;q.x=.5*(g.x+R.x),q.y=.5*(g.y+R.y),q.z=.5*(g.z+R.z);let z=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(R,q,A)),M=Math.sqrt(z);const D=O;D.x=i.x,D.y=s.y,D.z=a.z;const U=I;U.x=u.x,U.y=c.y,U.z=l.z;const k=n.Cartesian3.midpoint(D,U,P);let F=0;for(f=0;f<d;f++){n.Cartesian3.clone(e[f],o);const t=n.Cartesian3.magnitude(n.Cartesian3.subtract(o,k,A));t>F&&(F=t);const r=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(o,q,A));if(r>z){const e=Math.sqrt(r);M=.5*(M+e),z=M*M;const t=e-M;q.x=(M*q.x+t*o.x)/e,q.y=(M*q.y+t*o.y)/e,q.z=(M*q.z+t*o.z)/e}}return M<F?(n.Cartesian3.clone(q,t.center),t.radius=M):(n.Cartesian3.clone(k,t.center),t.radius=F),t};const T=new h,q=new n.Cartesian3,z=new n.Cartesian3,M=new n.Cartographic,D=new n.Cartographic;y.fromRectangle2D=function(e,t,n){return y.fromRectangleWithHeights2D(e,t,0,0,n)},y.fromRectangleWithHeights2D=function(e,t,o,s,a){if(r.defined(a)||(a=new y),!r.defined(e))return a.center=n.Cartesian3.clone(n.Cartesian3.ZERO,a.center),a.radius=0,a;t=r.defaultValue(t,T),i.Rectangle.southwest(e,M),M.height=o,i.Rectangle.northeast(e,D),D.height=s;const u=t.project(M,q),c=t.project(D,z),l=c.x-u.x,d=c.y-u.y,f=c.z-u.z;a.radius=.5*Math.sqrt(l*l+d*d+f*f);const p=a.center;return p.x=u.x+.5*l,p.y=u.y+.5*d,p.z=u.z+.5*f,a};const U=[];y.fromRectangle3D=function(e,t,o,s){if(t=r.defaultValue(t,n.Ellipsoid.WGS84),o=r.defaultValue(o,0),r.defined(s)||(s=new y),!r.defined(e))return s.center=n.Cartesian3.clone(n.Cartesian3.ZERO,s.center),s.radius=0,s;const a=i.Rectangle.subsample(e,t,o,U);return y.fromPoints(a,s)},y.fromVertices=function(e,t,o,i){if(r.defined(i)||(i=new y),!r.defined(e)||0===e.length)return i.center=n.Cartesian3.clone(n.Cartesian3.ZERO,i.center),i.radius=0,i;t=r.defaultValue(t,n.Cartesian3.ZERO),o=r.defaultValue(o,3);const s=S;s.x=e[0]+t.x,s.y=e[1]+t.y,s.z=e[2]+t.z;const a=n.Cartesian3.clone(s,v),u=n.Cartesian3.clone(s,w),c=n.Cartesian3.clone(s,_),l=n.Cartesian3.clone(s,C),d=n.Cartesian3.clone(s,b),f=n.Cartesian3.clone(s,x),p=e.length;let h;for(h=0;h<p;h+=o){const r=e[h]+t.x,o=e[h+1]+t.y,i=e[h+2]+t.z;s.x=r,s.y=o,s.z=i,r<a.x&&n.Cartesian3.clone(s,a),r>l.x&&n.Cartesian3.clone(s,l),o<u.y&&n.Cartesian3.clone(s,u),o>d.y&&n.Cartesian3.clone(s,d),i<c.z&&n.Cartesian3.clone(s,c),i>f.z&&n.Cartesian3.clone(s,f)}const m=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(l,a,A)),g=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(d,u,A)),R=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(f,c,A));let T=a,q=l,z=m;g>z&&(z=g,T=u,q=d),R>z&&(z=R,T=c,q=f);const M=E;M.x=.5*(T.x+q.x),M.y=.5*(T.y+q.y),M.z=.5*(T.z+q.z);let D=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(q,M,A)),U=Math.sqrt(D);const k=O;k.x=a.x,k.y=u.y,k.z=c.z;const F=I;F.x=l.x,F.y=d.y,F.z=f.z;const N=n.Cartesian3.midpoint(k,F,P);let j=0;for(h=0;h<p;h+=o){s.x=e[h]+t.x,s.y=e[h+1]+t.y,s.z=e[h+2]+t.z;const r=n.Cartesian3.magnitude(n.Cartesian3.subtract(s,N,A));r>j&&(j=r);const o=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(s,M,A));if(o>D){const e=Math.sqrt(o);U=.5*(U+e),D=U*U;const t=e-U;M.x=(U*M.x+t*s.x)/e,M.y=(U*M.y+t*s.y)/e,M.z=(U*M.z+t*s.z)/e}}return U<j?(n.Cartesian3.clone(M,i.center),i.radius=U):(n.Cartesian3.clone(N,i.center),i.radius=j),i},y.fromEncodedCartesianVertices=function(e,t,o){if(r.defined(o)||(o=new y),!r.defined(e)||!r.defined(t)||e.length!==t.length||0===e.length)return o.center=n.Cartesian3.clone(n.Cartesian3.ZERO,o.center),o.radius=0,o;const i=S;i.x=e[0]+t[0],i.y=e[1]+t[1],i.z=e[2]+t[2];const s=n.Cartesian3.clone(i,v),a=n.Cartesian3.clone(i,w),u=n.Cartesian3.clone(i,_),c=n.Cartesian3.clone(i,C),l=n.Cartesian3.clone(i,b),d=n.Cartesian3.clone(i,x),f=e.length;let p;for(p=0;p<f;p+=3){const r=e[p]+t[p],o=e[p+1]+t[p+1],f=e[p+2]+t[p+2];i.x=r,i.y=o,i.z=f,r<s.x&&n.Cartesian3.clone(i,s),r>c.x&&n.Cartesian3.clone(i,c),o<a.y&&n.Cartesian3.clone(i,a),o>l.y&&n.Cartesian3.clone(i,l),f<u.z&&n.Cartesian3.clone(i,u),f>d.z&&n.Cartesian3.clone(i,d)}const h=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(c,s,A)),m=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(l,a,A)),g=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(d,u,A));let R=s,T=c,q=h;m>q&&(q=m,R=a,T=l),g>q&&(q=g,R=u,T=d);const z=E;z.x=.5*(R.x+T.x),z.y=.5*(R.y+T.y),z.z=.5*(R.z+T.z);let M=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(T,z,A)),D=Math.sqrt(M);const U=O;U.x=s.x,U.y=a.y,U.z=u.z;const k=I;k.x=c.x,k.y=l.y,k.z=d.z;const F=n.Cartesian3.midpoint(U,k,P);let N=0;for(p=0;p<f;p+=3){i.x=e[p]+t[p],i.y=e[p+1]+t[p+1],i.z=e[p+2]+t[p+2];const r=n.Cartesian3.magnitude(n.Cartesian3.subtract(i,F,A));r>N&&(N=r);const o=n.Cartesian3.magnitudeSquared(n.Cartesian3.subtract(i,z,A));if(o>M){const e=Math.sqrt(o);D=.5*(D+e),M=D*D;const t=e-D;z.x=(D*z.x+t*i.x)/e,z.y=(D*z.y+t*i.y)/e,z.z=(D*z.z+t*i.z)/e}}return D<N?(n.Cartesian3.clone(z,o.center),o.radius=D):(n.Cartesian3.clone(F,o.center),o.radius=N),o},y.fromCornerPoints=function(e,t,o){r.defined(o)||(o=new y);const i=n.Cartesian3.midpoint(e,t,o.center);return o.radius=n.Cartesian3.distance(i,t),o},y.fromEllipsoid=function(e,t){return r.defined(t)||(t=new y),n.Cartesian3.clone(n.Cartesian3.ZERO,t.center),t.radius=e.maximumRadius,t};const k=new n.Cartesian3;y.fromBoundingSpheres=function(e,t){if(r.defined(t)||(t=new y),!r.defined(e)||0===e.length)return t.center=n.Cartesian3.clone(n.Cartesian3.ZERO,t.center),t.radius=0,t;const o=e.length;if(1===o)return y.clone(e[0],t);if(2===o)return y.union(e[0],e[1],t);const i=[];let s;for(s=0;s<o;s++)i.push(e[s].center);const a=(t=y.fromPoints(i,t)).center;let u=t.radius;for(s=0;s<o;s++){const t=e[s];u=Math.max(u,n.Cartesian3.distance(a,t.center,k)+t.radius)}return t.radius=u,t};const F=new n.Cartesian3,N=new n.Cartesian3,j=new n.Cartesian3;y.fromOrientedBoundingBox=function(e,t){r.defined(t)||(t=new y);const o=e.halfAxes,i=n.Matrix3.getColumn(o,0,F),s=n.Matrix3.getColumn(o,1,N),a=n.Matrix3.getColumn(o,2,j);return n.Cartesian3.add(i,s,i),n.Cartesian3.add(i,a,i),t.center=n.Cartesian3.clone(e.center,t.center),t.radius=n.Cartesian3.magnitude(i),t};const B=new n.Cartesian3,V=new n.Cartesian3;y.fromTransformation=function(e,t){r.defined(t)||(t=new y);const o=i.Matrix4.getTranslation(e,B),s=i.Matrix4.getScale(e,V),a=.5*n.Cartesian3.magnitude(s);return t.center=n.Cartesian3.clone(o,t.center),t.radius=a,t},y.clone=function(e,t){if(r.defined(e))return r.defined(t)?(t.center=n.Cartesian3.clone(e.center,t.center),t.radius=e.radius,t):new y(e.center,e.radius)},y.packedLength=4,y.pack=function(e,t,n){n=r.defaultValue(n,0);const o=e.center;return t[n++]=o.x,t[n++]=o.y,t[n++]=o.z,t[n]=e.radius,t},y.unpack=function(e,t,n){t=r.defaultValue(t,0),r.defined(n)||(n=new y);const o=n.center;return o.x=e[t++],o.y=e[t++],o.z=e[t++],n.radius=e[t],n};const $=new n.Cartesian3,L=new n.Cartesian3;y.union=function(e,t,o){r.defined(o)||(o=new y);const i=e.center,s=e.radius,a=t.center,u=t.radius,c=n.Cartesian3.subtract(a,i,$),l=n.Cartesian3.magnitude(c);if(s>=l+u)return e.clone(o),o;if(u>=l+s)return t.clone(o),o;const d=.5*(s+l+u),f=n.Cartesian3.multiplyByScalar(c,(-s+d)/l,L);return n.Cartesian3.add(f,i,f),n.Cartesian3.clone(f,o.center),o.radius=d,o};const Q=new n.Cartesian3;y.expand=function(e,t,r){r=y.clone(e,r);const o=n.Cartesian3.magnitude(n.Cartesian3.subtract(t,r.center,Q));return o>r.radius&&(r.radius=o),r},y.intersectPlane=function(e,t){const r=e.center,o=e.radius,i=t.normal,s=n.Cartesian3.dot(i,r)+t.distance;return s<-o?m.OUTSIDE:s<o?m.INTERSECTING:m.INSIDE},y.transform=function(e,t,n){return r.defined(n)||(n=new y),n.center=i.Matrix4.multiplyByPoint(t,e.center,n.center),n.radius=i.Matrix4.getMaximumScale(t)*e.radius,n};const W=new n.Cartesian3;y.distanceSquaredTo=function(e,t){const r=n.Cartesian3.subtract(e.center,t,W),o=n.Cartesian3.magnitude(r)-e.radius;return o<=0?0:o*o},y.transformWithoutScale=function(e,t,n){return r.defined(n)||(n=new y),n.center=i.Matrix4.multiplyByPoint(t,e.center,n.center),n.radius=e.radius,n};const H=new n.Cartesian3;y.computePlaneDistances=function(e,t,o,i){r.defined(i)||(i=new g);const s=n.Cartesian3.subtract(e.center,t,H),a=n.Cartesian3.dot(o,s);return i.start=a-e.radius,i.stop=a+e.radius,i};const Y=new n.Cartesian3,Z=new n.Cartesian3,G=new n.Cartesian3,J=new n.Cartesian3,X=new n.Cartesian3,K=new n.Cartographic,ee=new Array(8);for(let e=0;e<8;++e)ee[e]=new n.Cartesian3;const te=new h;let ne;y.projectTo2D=function(e,t,o){const i=(t=r.defaultValue(t,te)).ellipsoid;let s=e.center;const a=e.radius;let u;u=n.Cartesian3.equals(s,n.Cartesian3.ZERO)?n.Cartesian3.clone(n.Cartesian3.UNIT_X,Y):i.geodeticSurfaceNormal(s,Y);const c=n.Cartesian3.cross(n.Cartesian3.UNIT_Z,u,Z);n.Cartesian3.normalize(c,c);const l=n.Cartesian3.cross(u,c,G);n.Cartesian3.normalize(l,l),n.Cartesian3.multiplyByScalar(u,a,u),n.Cartesian3.multiplyByScalar(l,a,l),n.Cartesian3.multiplyByScalar(c,a,c);const d=n.Cartesian3.negate(l,X),f=n.Cartesian3.negate(c,J),p=ee;let h=p[0];n.Cartesian3.add(u,l,h),n.Cartesian3.add(h,c,h),h=p[1],n.Cartesian3.add(u,l,h),n.Cartesian3.add(h,f,h),h=p[2],n.Cartesian3.add(u,d,h),n.Cartesian3.add(h,f,h),h=p[3],n.Cartesian3.add(u,d,h),n.Cartesian3.add(h,c,h),n.Cartesian3.negate(u,u),h=p[4],n.Cartesian3.add(u,l,h),n.Cartesian3.add(h,c,h),h=p[5],n.Cartesian3.add(u,l,h),n.Cartesian3.add(h,f,h),h=p[6],n.Cartesian3.add(u,d,h),n.Cartesian3.add(h,f,h),h=p[7],n.Cartesian3.add(u,d,h),n.Cartesian3.add(h,c,h);const m=p.length;for(let e=0;e<m;++e){const r=p[e];n.Cartesian3.add(s,r,r);const o=i.cartesianToCartographic(r,K);t.project(o,r)}s=(o=y.fromPoints(p,o)).center;const g=s.x,v=s.y,w=s.z;return s.x=w,s.y=g,s.z=v,o},y.isOccluded=function(e,t){return!t.isBoundingSphereVisible(e)},y.equals=function(e,t){return e===t||r.defined(e)&&r.defined(t)&&n.Cartesian3.equals(e.center,t.center)&&e.radius===t.radius},y.prototype.intersectPlane=function(e){return y.intersectPlane(this,e)},y.prototype.distanceSquaredTo=function(e){return y.distanceSquaredTo(this,e)},y.prototype.computePlaneDistances=function(e,t,n){return y.computePlaneDistances(this,e,t,n)},y.prototype.isOccluded=function(e){return y.isOccluded(this,e)},y.prototype.equals=function(e){return y.equals(this,e)},y.prototype.clone=function(e){return y.clone(this,e)},y.prototype.volume=function(){const e=this.radius;return R*e*e*e};const re={requestFullscreen:void 0,exitFullscreen:void 0,fullscreenEnabled:void 0,fullscreenElement:void 0,fullscreenchange:void 0,fullscreenerror:void 0},oe={};Object.defineProperties(oe,{element:{get:function(){if(oe.supportsFullscreen())return document[re.fullscreenElement]}},changeEventName:{get:function(){if(oe.supportsFullscreen())return re.fullscreenchange}},errorEventName:{get:function(){if(oe.supportsFullscreen())return re.fullscreenerror}},enabled:{get:function(){if(oe.supportsFullscreen())return document[re.fullscreenEnabled]}},fullscreen:{get:function(){if(oe.supportsFullscreen())return null!==oe.element}}}),oe.supportsFullscreen=function(){if(r.defined(ne))return ne;ne=!1;const e=document.body;if("function"==typeof e.requestFullscreen)return re.requestFullscreen="requestFullscreen",re.exitFullscreen="exitFullscreen",re.fullscreenEnabled="fullscreenEnabled",re.fullscreenElement="fullscreenElement",re.fullscreenchange="fullscreenchange",re.fullscreenerror="fullscreenerror",ne=!0,ne;const t=["webkit","moz","o","ms","khtml"];let n;for(let r=0,o=t.length;r<o;++r){const o=t[r];n=`${o}RequestFullscreen`,"function"==typeof e[n]?(re.requestFullscreen=n,ne=!0):(n=`${o}RequestFullScreen`,"function"==typeof e[n]&&(re.requestFullscreen=n,ne=!0)),n=`${o}ExitFullscreen`,"function"==typeof document[n]?re.exitFullscreen=n:(n=`${o}CancelFullScreen`,"function"==typeof document[n]&&(re.exitFullscreen=n)),n=`${o}FullscreenEnabled`,void 0!==document[n]?re.fullscreenEnabled=n:(n=`${o}FullScreenEnabled`,void 0!==document[n]&&(re.fullscreenEnabled=n)),n=`${o}FullscreenElement`,void 0!==document[n]?re.fullscreenElement=n:(n=`${o}FullScreenElement`,void 0!==document[n]&&(re.fullscreenElement=n)),n=`${o}fullscreenchange`,void 0!==document[`on${n}`]&&("ms"===o&&(n="MSFullscreenChange"),re.fullscreenchange=n),n=`${o}fullscreenerror`,void 0!==document[`on${n}`]&&("ms"===o&&(n="MSFullscreenError"),re.fullscreenerror=n)}return ne},oe.requestFullscreen=function(e,t){oe.supportsFullscreen()&&e[re.requestFullscreen]({vrDisplay:t})},oe.exitFullscreen=function(){oe.supportsFullscreen()&&document[re.exitFullscreen]()},oe._names=re;var ie=oe;let se,ae,ue,ce,le,de,fe,pe,he,me,ge,ye,ve,we,_e,Ce,be,xe;function Se(e){const t=e.split(".");for(let e=0,n=t.length;e<n;++e)t[e]=parseInt(t[e],10);return t}function Ae(){if(!r.defined(ae)&&(ae=!1,!Pe())){const e=/ Chrome\/([\.0-9]+)/.exec(se.userAgent);null!==e&&(ae=!0,ue=Se(e[1]))}return ae}function Ee(){if(!r.defined(ce)&&(ce=!1,!Ae()&&!Pe()&&/ Safari\/[\.0-9]+/.test(se.userAgent))){const e=/ Version\/([\.0-9]+)/.exec(se.userAgent);null!==e&&(ce=!0,le=Se(e[1]))}return ce}function Oe(){if(!r.defined(de)){de=!1;const e=/ AppleWebKit\/([\.0-9]+)(\+?)/.exec(se.userAgent);null!==e&&(de=!0,fe=Se(e[1]),fe.isNightly=!!e[2])}return de}function Ie(){if(!r.defined(pe)){let e;pe=!1,"Microsoft Internet Explorer"===se.appName?(e=/MSIE ([0-9]{1,}[\.0-9]{0,})/.exec(se.userAgent),null!==e&&(pe=!0,he=Se(e[1]))):"Netscape"===se.appName&&(e=/Trident\/.*rv:([0-9]{1,}[\.0-9]{0,})/.exec(se.userAgent),null!==e&&(pe=!0,he=Se(e[1])))}return pe}function Pe(){if(!r.defined(me)){me=!1;const e=/ Edg\/([\.0-9]+)/.exec(se.userAgent);null!==e&&(me=!0,ge=Se(e[1]))}return me}function Re(){if(!r.defined(ye)){ye=!1;const e=/Firefox\/([\.0-9]+)/.exec(se.userAgent);null!==e&&(ye=!0,ve=Se(e[1]))}return ye}function Te(){if(!r.defined(xe)){const e=document.createElement("canvas");e.setAttribute("style","image-rendering: -moz-crisp-edges;image-rendering: pixelated;");const t=e.style.imageRendering;xe=r.defined(t)&&""!==t,xe&&(be=t)}return xe}function qe(){return qe._result}se="undefined"!=typeof navigator?navigator:{},qe._promise=void 0,qe._result=void 0,qe.initialize=function(){return r.defined(qe._promise)||(qe._promise=new Promise((e=>{const t=new Image;t.onload=function(){qe._result=t.width>0&&t.height>0,e(qe._result)},t.onerror=function(){qe._result=!1,e(qe._result)},t.src="data:image/webp;base64,UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA"}))),qe._promise},Object.defineProperties(qe,{initialized:{get:function(){return r.defined(qe._result)}}});const ze=[];"undefined"!=typeof ArrayBuffer&&(ze.push(Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array),"undefined"!=typeof Uint8ClampedArray&&ze.push(Uint8ClampedArray),"undefined"!=typeof Uint8ClampedArray&&ze.push(Uint8ClampedArray),"undefined"!=typeof BigInt64Array&&ze.push(BigInt64Array),"undefined"!=typeof BigUint64Array&&ze.push(BigUint64Array));const Me={isChrome:Ae,chromeVersion:function(){return Ae()&&ue},isSafari:Ee,safariVersion:function(){return Ee()&&le},isWebkit:Oe,webkitVersion:function(){return Oe()&&fe},isInternetExplorer:Ie,internetExplorerVersion:function(){return Ie()&&he},isEdge:Pe,edgeVersion:function(){return Pe()&&ge},isFirefox:Re,firefoxVersion:function(){return Re()&&ve},isWindows:function(){return r.defined(we)||(we=/Windows/i.test(se.appVersion)),we},isIPadOrIOS:function(){return r.defined(_e)||(_e="iPhone"===navigator.platform||"iPod"===navigator.platform||"iPad"===navigator.platform),_e},hardwareConcurrency:r.defaultValue(se.hardwareConcurrency,3),supportsPointerEvents:function(){return r.defined(Ce)||(Ce=!Re()&&"undefined"!=typeof PointerEvent&&(!r.defined(se.pointerEnabled)||se.pointerEnabled)),Ce},supportsImageRenderingPixelated:Te,supportsWebP:qe,imageRenderingValue:function(){return Te()?be:void 0},typedArrayTypes:ze,supportsBasis:function(e){return Me.supportsWebAssembly()&&e.context.supportsBasis},supportsFullscreen:function(){return ie.supportsFullscreen()},supportsTypedArrays:function(){return"undefined"!=typeof ArrayBuffer},supportsBigInt64Array:function(){return"undefined"!=typeof BigInt64Array},supportsBigUint64Array:function(){return"undefined"!=typeof BigUint64Array},supportsBigInt:function(){return"undefined"!=typeof BigInt},supportsWebWorkers:function(){return"undefined"!=typeof Worker},supportsWebAssembly:function(){return"undefined"!=typeof WebAssembly}};var De=Me;function Ue(e,t,n,o){this.x=r.defaultValue(e,0),this.y=r.defaultValue(t,0),this.z=r.defaultValue(n,0),this.w=r.defaultValue(o,0)}let ke=new n.Cartesian3;Ue.fromAxisAngle=function(e,t,o){const i=t/2,s=Math.sin(i);ke=n.Cartesian3.normalize(e,ke);const a=ke.x*s,u=ke.y*s,c=ke.z*s,l=Math.cos(i);return r.defined(o)?(o.x=a,o.y=u,o.z=c,o.w=l,o):new Ue(a,u,c,l)};const Fe=[1,2,0],Ne=new Array(3);Ue.fromRotationMatrix=function(e,t){let o,i,s,a,u;const c=e[n.Matrix3.COLUMN0ROW0],l=e[n.Matrix3.COLUMN1ROW1],d=e[n.Matrix3.COLUMN2ROW2],f=c+l+d;if(f>0)o=Math.sqrt(f+1),u=.5*o,o=.5/o,i=(e[n.Matrix3.COLUMN1ROW2]-e[n.Matrix3.COLUMN2ROW1])*o,s=(e[n.Matrix3.COLUMN2ROW0]-e[n.Matrix3.COLUMN0ROW2])*o,a=(e[n.Matrix3.COLUMN0ROW1]-e[n.Matrix3.COLUMN1ROW0])*o;else{const t=Fe;let r=0;l>c&&(r=1),d>c&&d>l&&(r=2);const f=t[r],p=t[f];o=Math.sqrt(e[n.Matrix3.getElementIndex(r,r)]-e[n.Matrix3.getElementIndex(f,f)]-e[n.Matrix3.getElementIndex(p,p)]+1);const h=Ne;h[r]=.5*o,o=.5/o,u=(e[n.Matrix3.getElementIndex(p,f)]-e[n.Matrix3.getElementIndex(f,p)])*o,h[f]=(e[n.Matrix3.getElementIndex(f,r)]+e[n.Matrix3.getElementIndex(r,f)])*o,h[p]=(e[n.Matrix3.getElementIndex(p,r)]+e[n.Matrix3.getElementIndex(r,p)])*o,i=-h[0],s=-h[1],a=-h[2]}return r.defined(t)?(t.x=i,t.y=s,t.z=a,t.w=u,t):new Ue(i,s,a,u)};const je=new Ue;let Be=new Ue,Ve=new Ue,$e=new Ue;Ue.fromHeadingPitchRoll=function(e,t){return $e=Ue.fromAxisAngle(n.Cartesian3.UNIT_X,e.roll,je),Ve=Ue.fromAxisAngle(n.Cartesian3.UNIT_Y,-e.pitch,t),t=Ue.multiply(Ve,$e,Ve),Be=Ue.fromAxisAngle(n.Cartesian3.UNIT_Z,-e.heading,je),Ue.multiply(Be,t,t)};const Le=new n.Cartesian3,Qe=new n.Cartesian3,We=new Ue,He=new Ue,Ye=new Ue;Ue.packedLength=4,Ue.pack=function(e,t,n){return n=r.defaultValue(n,0),t[n++]=e.x,t[n++]=e.y,t[n++]=e.z,t[n]=e.w,t},Ue.unpack=function(e,t,n){return t=r.defaultValue(t,0),r.defined(n)||(n=new Ue),n.x=e[t],n.y=e[t+1],n.z=e[t+2],n.w=e[t+3],n},Ue.packedInterpolationLength=3,Ue.convertPackedArrayForInterpolation=function(e,t,n,o){Ue.unpack(e,4*n,Ye),Ue.conjugate(Ye,Ye);for(let i=0,s=n-t+1;i<s;i++){const n=3*i;Ue.unpack(e,4*(t+i),We),Ue.multiply(We,Ye,We),We.w<0&&Ue.negate(We,We),Ue.computeAxis(We,Le);const s=Ue.computeAngle(We);r.defined(o)||(o=[]),o[n]=Le.x*s,o[n+1]=Le.y*s,o[n+2]=Le.z*s}},Ue.unpackInterpolationResult=function(e,t,o,i,s){r.defined(s)||(s=new Ue),n.Cartesian3.fromArray(e,0,Qe);const a=n.Cartesian3.magnitude(Qe);return Ue.unpack(t,4*i,He),0===a?Ue.clone(Ue.IDENTITY,We):Ue.fromAxisAngle(Qe,a,We),Ue.multiply(We,He,s)},Ue.clone=function(e,t){if(r.defined(e))return r.defined(t)?(t.x=e.x,t.y=e.y,t.z=e.z,t.w=e.w,t):new Ue(e.x,e.y,e.z,e.w)},Ue.conjugate=function(e,t){return t.x=-e.x,t.y=-e.y,t.z=-e.z,t.w=e.w,t},Ue.magnitudeSquared=function(e){return e.x*e.x+e.y*e.y+e.z*e.z+e.w*e.w},Ue.magnitude=function(e){return Math.sqrt(Ue.magnitudeSquared(e))},Ue.normalize=function(e,t){const n=1/Ue.magnitude(e),r=e.x*n,o=e.y*n,i=e.z*n,s=e.w*n;return t.x=r,t.y=o,t.z=i,t.w=s,t},Ue.inverse=function(e,t){const n=Ue.magnitudeSquared(e);return t=Ue.conjugate(e,t),Ue.multiplyByScalar(t,1/n,t)},Ue.add=function(e,t,n){return n.x=e.x+t.x,n.y=e.y+t.y,n.z=e.z+t.z,n.w=e.w+t.w,n},Ue.subtract=function(e,t,n){return n.x=e.x-t.x,n.y=e.y-t.y,n.z=e.z-t.z,n.w=e.w-t.w,n},Ue.negate=function(e,t){return t.x=-e.x,t.y=-e.y,t.z=-e.z,t.w=-e.w,t},Ue.dot=function(e,t){return e.x*t.x+e.y*t.y+e.z*t.z+e.w*t.w},Ue.multiply=function(e,t,n){const r=e.x,o=e.y,i=e.z,s=e.w,a=t.x,u=t.y,c=t.z,l=t.w,d=s*a+r*l+o*c-i*u,f=s*u-r*c+o*l+i*a,p=s*c+r*u-o*a+i*l,h=s*l-r*a-o*u-i*c;return n.x=d,n.y=f,n.z=p,n.w=h,n},Ue.multiplyByScalar=function(e,t,n){return n.x=e.x*t,n.y=e.y*t,n.z=e.z*t,n.w=e.w*t,n},Ue.divideByScalar=function(e,t,n){return n.x=e.x/t,n.y=e.y/t,n.z=e.z/t,n.w=e.w/t,n},Ue.computeAxis=function(e,t){const n=e.w;if(Math.abs(n-1)<o.CesiumMath.EPSILON6)return t.x=t.y=t.z=0,t;const r=1/Math.sqrt(1-n*n);return t.x=e.x*r,t.y=e.y*r,t.z=e.z*r,t},Ue.computeAngle=function(e){return Math.abs(e.w-1)<o.CesiumMath.EPSILON6?0:2*Math.acos(e.w)};let Ze=new Ue;Ue.lerp=function(e,t,n,r){return Ze=Ue.multiplyByScalar(t,n,Ze),r=Ue.multiplyByScalar(e,1-n,r),Ue.add(Ze,r,r)};let Ge=new Ue,Je=new Ue,Xe=new Ue;Ue.slerp=function(e,t,n,r){let i=Ue.dot(e,t),s=t;if(i<0&&(i=-i,s=Ge=Ue.negate(t,Ge)),1-i<o.CesiumMath.EPSILON6)return Ue.lerp(e,s,n,r);const a=Math.acos(i);return Je=Ue.multiplyByScalar(e,Math.sin((1-n)*a),Je),Xe=Ue.multiplyByScalar(s,Math.sin(n*a),Xe),r=Ue.add(Je,Xe,r),Ue.multiplyByScalar(r,1/Math.sin(a),r)},Ue.log=function(e,t){const r=o.CesiumMath.acosClamped(e.w);let i=0;return 0!==r&&(i=r/Math.sin(r)),n.Cartesian3.multiplyByScalar(e,i,t)},Ue.exp=function(e,t){const r=n.Cartesian3.magnitude(e);let o=0;return 0!==r&&(o=Math.sin(r)/r),t.x=e.x*o,t.y=e.y*o,t.z=e.z*o,t.w=Math.cos(r),t};const Ke=new n.Cartesian3,et=new n.Cartesian3,tt=new Ue,nt=new Ue;Ue.computeInnerQuadrangle=function(e,t,r,o){const i=Ue.conjugate(t,tt);Ue.multiply(i,r,nt);const s=Ue.log(nt,Ke);Ue.multiply(i,e,nt);const a=Ue.log(nt,et);return n.Cartesian3.add(s,a,s),n.Cartesian3.multiplyByScalar(s,.25,s),n.Cartesian3.negate(s,s),Ue.exp(s,tt),Ue.multiply(t,tt,o)},Ue.squad=function(e,t,n,r,o,i){const s=Ue.slerp(e,t,o,tt),a=Ue.slerp(n,r,o,nt);return Ue.slerp(s,a,2*o*(1-o),i)};const rt=new Ue,ot=1.9011074535173003,it=De.supportsTypedArrays()?new Float32Array(8):[],st=De.supportsTypedArrays()?new Float32Array(8):[],at=De.supportsTypedArrays()?new Float32Array(8):[],ut=De.supportsTypedArrays()?new Float32Array(8):[];for(let e=0;e<7;++e){const t=e+1,n=2*t+1;it[e]=1/(t*n),st[e]=t/n}function ct(e,t,n){let r,o,i=0,s=e.length-1;for(;i<=s;)if(r=~~((i+s)/2),o=n(e[r],t),o<0)i=r+1;else{if(!(o>0))return r;s=r-1}return~(s+1)}function lt(e,t,n,r,o){this.xPoleWander=e,this.yPoleWander=t,this.xPoleOffset=n,this.yPoleOffset=r,this.ut1MinusUtc=o}function dt(e,t,n,r,o,i,s,a){this.year=e,this.month=t,this.day=n,this.hour=r,this.minute=o,this.second=i,this.millisecond=s,this.isLeapSecond=a}function ft(e){return e%4==0&&e%100!=0||e%400==0}function pt(e,t){this.julianDate=e,this.offset=t}it[7]=ot/136,st[7]=8*ot/17,Ue.fastSlerp=function(e,t,n,r){let o,i=Ue.dot(e,t);i>=0?o=1:(o=-1,i=-i);const s=i-1,a=1-n,u=n*n,c=a*a;for(let e=7;e>=0;--e)at[e]=(it[e]*u-st[e])*s,ut[e]=(it[e]*c-st[e])*s;const l=o*n*(1+at[0]*(1+at[1]*(1+at[2]*(1+at[3]*(1+at[4]*(1+at[5]*(1+at[6]*(1+at[7])))))))),d=a*(1+ut[0]*(1+ut[1]*(1+ut[2]*(1+ut[3]*(1+ut[4]*(1+ut[5]*(1+ut[6]*(1+ut[7])))))))),f=Ue.multiplyByScalar(e,d,rt);return Ue.multiplyByScalar(t,l,r),Ue.add(f,r,r)},Ue.fastSquad=function(e,t,n,r,o,i){const s=Ue.fastSlerp(e,t,o,tt),a=Ue.fastSlerp(n,r,o,nt);return Ue.fastSlerp(s,a,2*o*(1-o),i)},Ue.equals=function(e,t){return e===t||r.defined(e)&&r.defined(t)&&e.x===t.x&&e.y===t.y&&e.z===t.z&&e.w===t.w},Ue.equalsEpsilon=function(e,t,n){return n=r.defaultValue(n,0),e===t||r.defined(e)&&r.defined(t)&&Math.abs(e.x-t.x)<=n&&Math.abs(e.y-t.y)<=n&&Math.abs(e.z-t.z)<=n&&Math.abs(e.w-t.w)<=n},Ue.ZERO=Object.freeze(new Ue(0,0,0,0)),Ue.IDENTITY=Object.freeze(new Ue(0,0,0,1)),Ue.prototype.clone=function(e){return Ue.clone(this,e)},Ue.prototype.equals=function(e){return Ue.equals(this,e)},Ue.prototype.equalsEpsilon=function(e,t){return Ue.equalsEpsilon(this,e,t)},Ue.prototype.toString=function(){return`(${this.x}, ${this.y}, ${this.z}, ${this.w})`};var ht=Object.freeze({SECONDS_PER_MILLISECOND:.001,SECONDS_PER_MINUTE:60,MINUTES_PER_HOUR:60,HOURS_PER_DAY:24,SECONDS_PER_HOUR:3600,MINUTES_PER_DAY:1440,SECONDS_PER_DAY:86400,DAYS_PER_JULIAN_CENTURY:36525,PICOSECOND:1e-9,MODIFIED_JULIAN_DATE_DIFFERENCE:2400000.5});var mt=Object.freeze({UTC:0,TAI:1});const gt=new dt,yt=[31,28,31,30,31,30,31,31,30,31,30,31];function vt(e,t){return zt.compare(e.julianDate,t.julianDate)}const wt=new pt;function _t(e){wt.julianDate=e;const t=zt.leapSeconds;let n=ct(t,wt,vt);n<0&&(n=~n),n>=t.length&&(n=t.length-1);let r=t[n].offset;if(n>0){zt.secondsDifference(t[n].julianDate,e)>r&&(n--,r=t[n].offset)}zt.addSeconds(e,r,e)}function Ct(e,t){wt.julianDate=e;const n=zt.leapSeconds;let r=ct(n,wt,vt);if(r<0&&(r=~r),0===r)return zt.addSeconds(e,-n[0].offset,t);if(r>=n.length)return zt.addSeconds(e,-n[r-1].offset,t);const o=zt.secondsDifference(n[r].julianDate,e);return 0===o?zt.addSeconds(e,-n[r].offset,t):o<=1?void 0:zt.addSeconds(e,-n[--r].offset,t)}function bt(e,t,n){const r=t/ht.SECONDS_PER_DAY|0;return e+=r,(t-=ht.SECONDS_PER_DAY*r)<0&&(e--,t+=ht.SECONDS_PER_DAY),n.dayNumber=e,n.secondsOfDay=t,n}function xt(e,t,n,r,o,i,s){const a=(t-14)/12|0,u=e+4800+a;let c=(1461*u/4|0)+(367*(t-2-12*a)/12|0)-(3*((u+100)/100|0)/4|0)+n-32075;(r-=12)<0&&(r+=24);const l=i+(r*ht.SECONDS_PER_HOUR+o*ht.SECONDS_PER_MINUTE+s*ht.SECONDS_PER_MILLISECOND);return l>=43200&&(c-=1),[c,l]}const St=/^(\d{4})$/,At=/^(\d{4})-(\d{2})$/,Et=/^(\d{4})-?(\d{3})$/,Ot=/^(\d{4})-?W(\d{2})-?(\d{1})?$/,It=/^(\d{4})-?(\d{2})-?(\d{2})$/,Pt=/([Z+\-])?(\d{2})?:?(\d{2})?$/,Rt=/^(\d{2})(\.\d+)?/.source+Pt.source,Tt=/^(\d{2}):?(\d{2})(\.\d+)?/.source+Pt.source,qt=/^(\d{2}):?(\d{2}):?(\d{2})(\.\d+)?/.source+Pt.source;function zt(e,t,n){this.dayNumber=void 0,this.secondsOfDay=void 0,e=r.defaultValue(e,0),t=r.defaultValue(t,0),n=r.defaultValue(n,mt.UTC);const o=0|e;bt(o,t+=(e-o)*ht.SECONDS_PER_DAY,this),n===mt.UTC&&_t(this)}zt.fromGregorianDate=function(e,t){const n=xt(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond);return r.defined(t)?(bt(n[0],n[1],t),_t(t),t):new zt(n[0],n[1],mt.UTC)},zt.fromDate=function(e,t){const n=xt(e.getUTCFullYear(),e.getUTCMonth()+1,e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds());return r.defined(t)?(bt(n[0],n[1],t),_t(t),t):new zt(n[0],n[1],mt.UTC)},zt.fromIso8601=function(e,t){let n,o=(e=e.replace(",",".")).split("T"),i=1,s=1,a=0,u=0,c=0,l=0;const d=o[0],f=o[1];let p,h,m;if(o=d.match(It),null!==o)n=+o[1],i=+o[2],s=+o[3];else if(o=d.match(At),null!==o)n=+o[1],i=+o[2];else if(o=d.match(St),null!==o)n=+o[1];else{let e;if(o=d.match(Et),null!==o)n=+o[1],e=+o[2],h=ft(n);else if(o=d.match(Ot),null!==o){n=+o[1];e=7*+o[2]+(+o[3]||0)-new Date(Date.UTC(n,0,4)).getUTCDay()-3}p=new Date(Date.UTC(n,0,1)),p.setUTCDate(e),i=p.getUTCMonth()+1,s=p.getUTCDate()}if(h=ft(n),r.defined(f)){o=f.match(qt),null!==o?(a=+o[1],u=+o[2],c=+o[3],l=1e3*+(o[4]||0),m=5):(o=f.match(Tt),null!==o?(a=+o[1],u=+o[2],c=60*+(o[3]||0),m=4):(o=f.match(Rt),null!==o&&(a=+o[1],u=60*+(o[2]||0),m=3)));const e=o[m],t=+o[m+1],r=+(o[m+2]||0);switch(e){case"+":a-=t,u-=r;break;case"-":a+=t,u+=r;break;case"Z":break;default:u+=new Date(Date.UTC(n,i-1,s,a,u)).getTimezoneOffset()}}const g=60===c;for(g&&c--;u>=60;)u-=60,a++;for(;a>=24;)a-=24,s++;for(p=h&&2===i?29:yt[i-1];s>p;)s-=p,i++,i>12&&(i-=12,n++),p=h&&2===i?29:yt[i-1];for(;u<0;)u+=60,a--;for(;a<0;)a+=24,s--;for(;s<1;)i--,i<1&&(i+=12,n--),p=h&&2===i?29:yt[i-1],s+=p;const y=xt(n,i,s,a,u,c,l);return r.defined(t)?(bt(y[0],y[1],t),_t(t)):t=new zt(y[0],y[1],mt.UTC),g&&zt.addSeconds(t,1,t),t},zt.now=function(e){return zt.fromDate(new Date,e)};const Mt=new zt(0,0,mt.TAI);zt.toGregorianDate=function(e,t){let n=!1,o=Ct(e,Mt);r.defined(o)||(zt.addSeconds(e,-1,Mt),o=Ct(Mt,Mt),n=!0);let i=o.dayNumber;const s=o.secondsOfDay;s>=43200&&(i+=1);let a=i+68569|0;const u=4*a/146097|0;a=a-((146097*u+3)/4|0)|0;const c=4e3*(a+1)/1461001|0;a=a-(1461*c/4|0)+31|0;const l=80*a/2447|0,d=a-(2447*l/80|0)|0;a=l/11|0;const f=l+2-12*a|0,p=100*(u-49)+c+a|0;let h=s/ht.SECONDS_PER_HOUR|0,m=s-h*ht.SECONDS_PER_HOUR;const g=m/ht.SECONDS_PER_MINUTE|0;m-=g*ht.SECONDS_PER_MINUTE;let y=0|m;const v=(m-y)/ht.SECONDS_PER_MILLISECOND;return h+=12,h>23&&(h-=24),n&&(y+=1),r.defined(t)?(t.year=p,t.month=f,t.day=d,t.hour=h,t.minute=g,t.second=y,t.millisecond=v,t.isLeapSecond=n,t):new dt(p,f,d,h,g,y,v,n)},zt.toDate=function(e){const t=zt.toGregorianDate(e,gt);let n=t.second;return t.isLeapSecond&&(n-=1),new Date(Date.UTC(t.year,t.month-1,t.day,t.hour,t.minute,n,t.millisecond))},zt.toIso8601=function(e,t){const n=zt.toGregorianDate(e,gt);let o=n.year,i=n.month,s=n.day,a=n.hour;const u=n.minute,c=n.second,l=n.millisecond;let d;return 1e4===o&&1===i&&1===s&&0===a&&0===u&&0===c&&0===l&&(o=9999,i=12,s=31,a=24),r.defined(t)||0===l?r.defined(t)&&0!==t?(d=(.01*l).toFixed(t).replace(".","").slice(0,t),`${o.toString().padStart(4,"0")}-${i.toString().padStart(2,"0")}-${s.toString().padStart(2,"0")}T${a.toString().padStart(2,"0")}:${u.toString().padStart(2,"0")}:${c.toString().padStart(2,"0")}.${d}Z`):`${o.toString().padStart(4,"0")}-${i.toString().padStart(2,"0")}-${s.toString().padStart(2,"0")}T${a.toString().padStart(2,"0")}:${u.toString().padStart(2,"0")}:${c.toString().padStart(2,"0")}Z`:(d=(.01*l).toString().replace(".",""),`${o.toString().padStart(4,"0")}-${i.toString().padStart(2,"0")}-${s.toString().padStart(2,"0")}T${a.toString().padStart(2,"0")}:${u.toString().padStart(2,"0")}:${c.toString().padStart(2,"0")}.${d}Z`)},zt.clone=function(e,t){if(r.defined(e))return r.defined(t)?(t.dayNumber=e.dayNumber,t.secondsOfDay=e.secondsOfDay,t):new zt(e.dayNumber,e.secondsOfDay,mt.TAI)},zt.compare=function(e,t){const n=e.dayNumber-t.dayNumber;return 0!==n?n:e.secondsOfDay-t.secondsOfDay},zt.equals=function(e,t){return e===t||r.defined(e)&&r.defined(t)&&e.dayNumber===t.dayNumber&&e.secondsOfDay===t.secondsOfDay},zt.equalsEpsilon=function(e,t,n){return n=r.defaultValue(n,0),e===t||r.defined(e)&&r.defined(t)&&Math.abs(zt.secondsDifference(e,t))<=n},zt.totalDays=function(e){return e.dayNumber+e.secondsOfDay/ht.SECONDS_PER_DAY},zt.secondsDifference=function(e,t){return(e.dayNumber-t.dayNumber)*ht.SECONDS_PER_DAY+(e.secondsOfDay-t.secondsOfDay)},zt.daysDifference=function(e,t){return e.dayNumber-t.dayNumber+(e.secondsOfDay-t.secondsOfDay)/ht.SECONDS_PER_DAY},zt.computeTaiMinusUtc=function(e){wt.julianDate=e;const t=zt.leapSeconds;let n=ct(t,wt,vt);return n<0&&(n=~n,--n,n<0&&(n=0)),t[n].offset},zt.addSeconds=function(e,t,n){return bt(e.dayNumber,e.secondsOfDay+t,n)},zt.addMinutes=function(e,t,n){const r=e.secondsOfDay+t*ht.SECONDS_PER_MINUTE;return bt(e.dayNumber,r,n)},zt.addHours=function(e,t,n){const r=e.secondsOfDay+t*ht.SECONDS_PER_HOUR;return bt(e.dayNumber,r,n)},zt.addDays=function(e,t,n){return bt(e.dayNumber+t,e.secondsOfDay,n)},zt.lessThan=function(e,t){return zt.compare(e,t)<0},zt.lessThanOrEquals=function(e,t){return zt.compare(e,t)<=0},zt.greaterThan=function(e,t){return zt.compare(e,t)>0},zt.greaterThanOrEquals=function(e,t){return zt.compare(e,t)>=0},zt.prototype.clone=function(e){return zt.clone(this,e)},zt.prototype.equals=function(e){return zt.equals(this,e)},zt.prototype.equalsEpsilon=function(e,t){return zt.equalsEpsilon(this,e,t)},zt.prototype.toString=function(){return zt.toIso8601(this)},zt.leapSeconds=[new pt(new zt(2441317,43210,mt.TAI),10),new pt(new zt(2441499,43211,mt.TAI),11),new pt(new zt(2441683,43212,mt.TAI),12),new pt(new zt(2442048,43213,mt.TAI),13),new pt(new zt(2442413,43214,mt.TAI),14),new pt(new zt(2442778,43215,mt.TAI),15),new pt(new zt(2443144,43216,mt.TAI),16),new pt(new zt(2443509,43217,mt.TAI),17),new pt(new zt(2443874,43218,mt.TAI),18),new pt(new zt(2444239,43219,mt.TAI),19),new pt(new zt(2444786,43220,mt.TAI),20),new pt(new zt(2445151,43221,mt.TAI),21),new pt(new zt(2445516,43222,mt.TAI),22),new pt(new zt(2446247,43223,mt.TAI),23),new pt(new zt(2447161,43224,mt.TAI),24),new pt(new zt(2447892,43225,mt.TAI),25),new pt(new zt(2448257,43226,mt.TAI),26),new pt(new zt(2448804,43227,mt.TAI),27),new pt(new zt(2449169,43228,mt.TAI),28),new pt(new zt(2449534,43229,mt.TAI),29),new pt(new zt(2450083,43230,mt.TAI),30),new pt(new zt(2450630,43231,mt.TAI),31),new pt(new zt(2451179,43232,mt.TAI),32),new pt(new zt(2453736,43233,mt.TAI),33),new pt(new zt(2454832,43234,mt.TAI),34),new pt(new zt(2456109,43235,mt.TAI),35),new pt(new zt(2457204,43236,mt.TAI),36),new pt(new zt(2457754,43237,mt.TAI),37)];var Dt,Ut={exports:{}},kt={exports:{}};var Ft,Nt={exports:{}}; |
| | | /*! |
| | | * URI.js - Mutating URLs |
| | | * IPv6 Support |