chunk-GMFQULD7.js 47 KB

123456789101112131415161718192021222324252627282930
  1. /**
  2. * @license
  3. * Cesium - https://github.com/CesiumGS/cesium
  4. * Version 1.110.1
  5. *
  6. * Copyright 2011-2022 Cesium Contributors
  7. *
  8. * Licensed under the Apache License, Version 2.0 (the "License");
  9. * you may not use this file except in compliance with the License.
  10. * You may obtain a copy of the License at
  11. *
  12. * http://www.apache.org/licenses/LICENSE-2.0
  13. *
  14. * Unless required by applicable law or agreed to in writing, software
  15. * distributed under the License is distributed on an "AS IS" BASIS,
  16. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  17. * See the License for the specific language governing permissions and
  18. * limitations under the License.
  19. *
  20. * Columbus View (Pat. Pend.)
  21. *
  22. * Portions licensed separately.
  23. * See https://github.com/CesiumGS/cesium/blob/main/LICENSE.md for full licensing details.
  24. */
  25. import{a as L,b as x,c as dn,d as cn}from"./chunk-4ZQSV4FU.js";import{a as E}from"./chunk-CLQ5X6HS.js";import{a as Rn}from"./chunk-7DENS74L.js";import{a as T}from"./chunk-FOJGNIAW.js";import{a as H,b as f}from"./chunk-UGI536VH.js";import{e as M}from"./chunk-BQUQ5TPM.js";function b(n,o,c,y){this.x=T(n,0),this.y=T(o,0),this.z=T(c,0),this.w=T(y,0)}b.fromElements=function(n,o,c,y,p){return M(p)?(p.x=n,p.y=o,p.z=c,p.w=y,p):new b(n,o,c,y)};b.fromColor=function(n,o){return f.typeOf.object("color",n),M(o)?(o.x=n.red,o.y=n.green,o.z=n.blue,o.w=n.alpha,o):new b(n.red,n.green,n.blue,n.alpha)};b.clone=function(n,o){if(M(n))return M(o)?(o.x=n.x,o.y=n.y,o.z=n.z,o.w=n.w,o):new b(n.x,n.y,n.z,n.w)};b.packedLength=4;b.pack=function(n,o,c){return f.typeOf.object("value",n),f.defined("array",o),c=T(c,0),o[c++]=n.x,o[c++]=n.y,o[c++]=n.z,o[c]=n.w,o};b.unpack=function(n,o,c){return f.defined("array",n),o=T(o,0),M(c)||(c=new b),c.x=n[o++],c.y=n[o++],c.z=n[o++],c.w=n[o],c};b.packArray=function(n,o){f.defined("array",n);let c=n.length,y=c*4;if(!M(o))o=new Array(y);else{if(!Array.isArray(o)&&o.length!==y)throw new H("If result is a typed array, it must have exactly array.length * 4 elements");o.length!==y&&(o.length=y)}for(let p=0;p<c;++p)b.pack(n[p],o,p*4);return o};b.unpackArray=function(n,o){if(f.defined("array",n),f.typeOf.number.greaterThanOrEquals("array.length",n.length,4),n.length%4!==0)throw new H("array length must be a multiple of 4.");let c=n.length;M(o)?o.length=c/4:o=new Array(c/4);for(let y=0;y<c;y+=4){let p=y/4;o[p]=b.unpack(n,y,o[p])}return o};b.fromArray=b.unpack;b.maximumComponent=function(n){return f.typeOf.object("cartesian",n),Math.max(n.x,n.y,n.z,n.w)};b.minimumComponent=function(n){return f.typeOf.object("cartesian",n),Math.min(n.x,n.y,n.z,n.w)};b.minimumByComponent=function(n,o,c){return f.typeOf.object("first",n),f.typeOf.object("second",o),f.typeOf.object("result",c),c.x=Math.min(n.x,o.x),c.y=Math.min(n.y,o.y),c.z=Math.min(n.z,o.z),c.w=Math.min(n.w,o.w),c};b.maximumByComponent=function(n,o,c){return f.typeOf.object("first",n),f.typeOf.object("second",o),f.typeOf.object("result",c),c.x=Math.max(n.x,o.x),c.y=Math.max(n.y,o.y),c.z=Math.max(n.z,o.z),c.w=Math.max(n.w,o.w),c};b.clamp=function(n,o,c,y){f.typeOf.object("value",n),f.typeOf.object("min",o),f.typeOf.object("max",c),f.typeOf.object("result",y);let p=E.clamp(n.x,o.x,c.x),O=E.clamp(n.y,o.y,c.y),e=E.clamp(n.z,o.z,c.z),h=E.clamp(n.w,o.w,c.w);return y.x=p,y.y=O,y.z=e,y.w=h,y};b.magnitudeSquared=function(n){return f.typeOf.object("cartesian",n),n.x*n.x+n.y*n.y+n.z*n.z+n.w*n.w};b.magnitude=function(n){return Math.sqrt(b.magnitudeSquared(n))};var yn=new b;b.distance=function(n,o){return f.typeOf.object("left",n),f.typeOf.object("right",o),b.subtract(n,o,yn),b.magnitude(yn)};b.distanceSquared=function(n,o){return f.typeOf.object("left",n),f.typeOf.object("right",o),b.subtract(n,o,yn),b.magnitudeSquared(yn)};b.normalize=function(n,o){f.typeOf.object("cartesian",n),f.typeOf.object("result",o);let c=b.magnitude(n);if(o.x=n.x/c,o.y=n.y/c,o.z=n.z/c,o.w=n.w/c,isNaN(o.x)||isNaN(o.y)||isNaN(o.z)||isNaN(o.w))throw new H("normalized result is not a number");return o};b.dot=function(n,o){return f.typeOf.object("left",n),f.typeOf.object("right",o),n.x*o.x+n.y*o.y+n.z*o.z+n.w*o.w};b.multiplyComponents=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c.x=n.x*o.x,c.y=n.y*o.y,c.z=n.z*o.z,c.w=n.w*o.w,c};b.divideComponents=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c.x=n.x/o.x,c.y=n.y/o.y,c.z=n.z/o.z,c.w=n.w/o.w,c};b.add=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c.x=n.x+o.x,c.y=n.y+o.y,c.z=n.z+o.z,c.w=n.w+o.w,c};b.subtract=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c.x=n.x-o.x,c.y=n.y-o.y,c.z=n.z-o.z,c.w=n.w-o.w,c};b.multiplyByScalar=function(n,o,c){return f.typeOf.object("cartesian",n),f.typeOf.number("scalar",o),f.typeOf.object("result",c),c.x=n.x*o,c.y=n.y*o,c.z=n.z*o,c.w=n.w*o,c};b.divideByScalar=function(n,o,c){return f.typeOf.object("cartesian",n),f.typeOf.number("scalar",o),f.typeOf.object("result",c),c.x=n.x/o,c.y=n.y/o,c.z=n.z/o,c.w=n.w/o,c};b.negate=function(n,o){return f.typeOf.object("cartesian",n),f.typeOf.object("result",o),o.x=-n.x,o.y=-n.y,o.z=-n.z,o.w=-n.w,o};b.abs=function(n,o){return f.typeOf.object("cartesian",n),f.typeOf.object("result",o),o.x=Math.abs(n.x),o.y=Math.abs(n.y),o.z=Math.abs(n.z),o.w=Math.abs(n.w),o};var En=new b;b.lerp=function(n,o,c,y){return f.typeOf.object("start",n),f.typeOf.object("end",o),f.typeOf.number("t",c),f.typeOf.object("result",y),b.multiplyByScalar(o,c,En),y=b.multiplyByScalar(n,1-c,y),b.add(En,y,y)};var kn=new b;b.mostOrthogonalAxis=function(n,o){f.typeOf.object("cartesian",n),f.typeOf.object("result",o);let c=b.normalize(n,kn);return b.abs(c,c),c.x<=c.y?c.x<=c.z?c.x<=c.w?o=b.clone(b.UNIT_X,o):o=b.clone(b.UNIT_W,o):c.z<=c.w?o=b.clone(b.UNIT_Z,o):o=b.clone(b.UNIT_W,o):c.y<=c.z?c.y<=c.w?o=b.clone(b.UNIT_Y,o):o=b.clone(b.UNIT_W,o):c.z<=c.w?o=b.clone(b.UNIT_Z,o):o=b.clone(b.UNIT_W,o),o};b.equals=function(n,o){return n===o||M(n)&&M(o)&&n.x===o.x&&n.y===o.y&&n.z===o.z&&n.w===o.w};b.equalsArray=function(n,o,c){return n.x===o[c]&&n.y===o[c+1]&&n.z===o[c+2]&&n.w===o[c+3]};b.equalsEpsilon=function(n,o,c,y){return n===o||M(n)&&M(o)&&E.equalsEpsilon(n.x,o.x,c,y)&&E.equalsEpsilon(n.y,o.y,c,y)&&E.equalsEpsilon(n.z,o.z,c,y)&&E.equalsEpsilon(n.w,o.w,c,y)};b.ZERO=Object.freeze(new b(0,0,0,0));b.ONE=Object.freeze(new b(1,1,1,1));b.UNIT_X=Object.freeze(new b(1,0,0,0));b.UNIT_Y=Object.freeze(new b(0,1,0,0));b.UNIT_Z=Object.freeze(new b(0,0,1,0));b.UNIT_W=Object.freeze(new b(0,0,0,1));b.prototype.clone=function(n){return b.clone(this,n)};b.prototype.equals=function(n){return b.equals(this,n)};b.prototype.equalsEpsilon=function(n,o,c){return b.equalsEpsilon(this,n,o,c)};b.prototype.toString=function(){return`(${this.x}, ${this.y}, ${this.z}, ${this.w})`};var zn=new Float32Array(1),Q=new Uint8Array(zn.buffer),Vn=new Uint32Array([287454020]),Xn=new Uint8Array(Vn.buffer),mn=Xn[0]===68;b.packFloat=function(n,o){return f.typeOf.number("value",n),M(o)||(o=new b),zn[0]=n,mn?(o.x=Q[0],o.y=Q[1],o.z=Q[2],o.w=Q[3]):(o.x=Q[3],o.y=Q[2],o.z=Q[1],o.w=Q[0]),o};b.unpackFloat=function(n){return f.typeOf.object("packedFloat",n),mn?(Q[0]=n.x,Q[1]=n.y,Q[2]=n.z,Q[3]=n.w):(Q[0]=n.w,Q[1]=n.z,Q[2]=n.y,Q[3]=n.x),zn[0]};var pn=b;function t(n,o,c,y,p,O,e,h,d,j,R,m,A,C,N,S){this[0]=T(n,0),this[1]=T(p,0),this[2]=T(d,0),this[3]=T(A,0),this[4]=T(o,0),this[5]=T(O,0),this[6]=T(j,0),this[7]=T(C,0),this[8]=T(c,0),this[9]=T(e,0),this[10]=T(R,0),this[11]=T(N,0),this[12]=T(y,0),this[13]=T(h,0),this[14]=T(m,0),this[15]=T(S,0)}t.packedLength=16;t.pack=function(n,o,c){return f.typeOf.object("value",n),f.defined("array",o),c=T(c,0),o[c++]=n[0],o[c++]=n[1],o[c++]=n[2],o[c++]=n[3],o[c++]=n[4],o[c++]=n[5],o[c++]=n[6],o[c++]=n[7],o[c++]=n[8],o[c++]=n[9],o[c++]=n[10],o[c++]=n[11],o[c++]=n[12],o[c++]=n[13],o[c++]=n[14],o[c]=n[15],o};t.unpack=function(n,o,c){return f.defined("array",n),o=T(o,0),M(c)||(c=new t),c[0]=n[o++],c[1]=n[o++],c[2]=n[o++],c[3]=n[o++],c[4]=n[o++],c[5]=n[o++],c[6]=n[o++],c[7]=n[o++],c[8]=n[o++],c[9]=n[o++],c[10]=n[o++],c[11]=n[o++],c[12]=n[o++],c[13]=n[o++],c[14]=n[o++],c[15]=n[o],c};t.packArray=function(n,o){f.defined("array",n);let c=n.length,y=c*16;if(!M(o))o=new Array(y);else{if(!Array.isArray(o)&&o.length!==y)throw new H("If result is a typed array, it must have exactly array.length * 16 elements");o.length!==y&&(o.length=y)}for(let p=0;p<c;++p)t.pack(n[p],o,p*16);return o};t.unpackArray=function(n,o){if(f.defined("array",n),f.typeOf.number.greaterThanOrEquals("array.length",n.length,16),n.length%16!==0)throw new H("array length must be a multiple of 16.");let c=n.length;M(o)?o.length=c/16:o=new Array(c/16);for(let y=0;y<c;y+=16){let p=y/16;o[p]=t.unpack(n,y,o[p])}return o};t.clone=function(n,o){if(M(n))return M(o)?(o[0]=n[0],o[1]=n[1],o[2]=n[2],o[3]=n[3],o[4]=n[4],o[5]=n[5],o[6]=n[6],o[7]=n[7],o[8]=n[8],o[9]=n[9],o[10]=n[10],o[11]=n[11],o[12]=n[12],o[13]=n[13],o[14]=n[14],o[15]=n[15],o):new t(n[0],n[4],n[8],n[12],n[1],n[5],n[9],n[13],n[2],n[6],n[10],n[14],n[3],n[7],n[11],n[15])};t.fromArray=t.unpack;t.fromColumnMajorArray=function(n,o){return f.defined("values",n),t.clone(n,o)};t.fromRowMajorArray=function(n,o){return f.defined("values",n),M(o)?(o[0]=n[0],o[1]=n[4],o[2]=n[8],o[3]=n[12],o[4]=n[1],o[5]=n[5],o[6]=n[9],o[7]=n[13],o[8]=n[2],o[9]=n[6],o[10]=n[10],o[11]=n[14],o[12]=n[3],o[13]=n[7],o[14]=n[11],o[15]=n[15],o):new t(n[0],n[1],n[2],n[3],n[4],n[5],n[6],n[7],n[8],n[9],n[10],n[11],n[12],n[13],n[14],n[15])};t.fromRotationTranslation=function(n,o,c){return f.typeOf.object("rotation",n),o=T(o,L.ZERO),M(c)?(c[0]=n[0],c[1]=n[1],c[2]=n[2],c[3]=0,c[4]=n[3],c[5]=n[4],c[6]=n[5],c[7]=0,c[8]=n[6],c[9]=n[7],c[10]=n[8],c[11]=0,c[12]=o.x,c[13]=o.y,c[14]=o.z,c[15]=1,c):new t(n[0],n[3],n[6],o.x,n[1],n[4],n[7],o.y,n[2],n[5],n[8],o.z,0,0,0,1)};t.fromTranslationQuaternionRotationScale=function(n,o,c,y){f.typeOf.object("translation",n),f.typeOf.object("rotation",o),f.typeOf.object("scale",c),M(y)||(y=new t);let p=c.x,O=c.y,e=c.z,h=o.x*o.x,d=o.x*o.y,j=o.x*o.z,R=o.x*o.w,m=o.y*o.y,A=o.y*o.z,C=o.y*o.w,N=o.z*o.z,S=o.z*o.w,P=o.w*o.w,_=h-m-N+P,U=2*(d-S),W=2*(j+C),i=2*(d+S),k=-h+m-N+P,V=2*(A-R),X=2*(j-C),B=2*(A+R),$=-h-m+N+P;return y[0]=_*p,y[1]=i*p,y[2]=X*p,y[3]=0,y[4]=U*O,y[5]=k*O,y[6]=B*O,y[7]=0,y[8]=W*e,y[9]=V*e,y[10]=$*e,y[11]=0,y[12]=n.x,y[13]=n.y,y[14]=n.z,y[15]=1,y};t.fromTranslationRotationScale=function(n,o){return f.typeOf.object("translationRotationScale",n),t.fromTranslationQuaternionRotationScale(n.translation,n.rotation,n.scale,o)};t.fromTranslation=function(n,o){return f.typeOf.object("translation",n),t.fromRotationTranslation(cn.IDENTITY,n,o)};t.fromScale=function(n,o){return f.typeOf.object("scale",n),M(o)?(o[0]=n.x,o[1]=0,o[2]=0,o[3]=0,o[4]=0,o[5]=n.y,o[6]=0,o[7]=0,o[8]=0,o[9]=0,o[10]=n.z,o[11]=0,o[12]=0,o[13]=0,o[14]=0,o[15]=1,o):new t(n.x,0,0,0,0,n.y,0,0,0,0,n.z,0,0,0,0,1)};t.fromUniformScale=function(n,o){return f.typeOf.number("scale",n),M(o)?(o[0]=n,o[1]=0,o[2]=0,o[3]=0,o[4]=0,o[5]=n,o[6]=0,o[7]=0,o[8]=0,o[9]=0,o[10]=n,o[11]=0,o[12]=0,o[13]=0,o[14]=0,o[15]=1,o):new t(n,0,0,0,0,n,0,0,0,0,n,0,0,0,0,1)};t.fromRotation=function(n,o){return f.typeOf.object("rotation",n),M(o)||(o=new t),o[0]=n[0],o[1]=n[1],o[2]=n[2],o[3]=0,o[4]=n[3],o[5]=n[4],o[6]=n[5],o[7]=0,o[8]=n[6],o[9]=n[7],o[10]=n[8],o[11]=0,o[12]=0,o[13]=0,o[14]=0,o[15]=1,o};var a=new L,s=new L,fn=new L;t.fromCamera=function(n,o){f.typeOf.object("camera",n);let c=n.position,y=n.direction,p=n.up;f.typeOf.object("camera.position",c),f.typeOf.object("camera.direction",y),f.typeOf.object("camera.up",p),L.normalize(y,a),L.normalize(L.cross(a,p,s),s),L.normalize(L.cross(s,a,fn),fn);let O=s.x,e=s.y,h=s.z,d=a.x,j=a.y,R=a.z,m=fn.x,A=fn.y,C=fn.z,N=c.x,S=c.y,P=c.z,_=O*-N+e*-S+h*-P,U=m*-N+A*-S+C*-P,W=d*N+j*S+R*P;return M(o)?(o[0]=O,o[1]=m,o[2]=-d,o[3]=0,o[4]=e,o[5]=A,o[6]=-j,o[7]=0,o[8]=h,o[9]=C,o[10]=-R,o[11]=0,o[12]=_,o[13]=U,o[14]=W,o[15]=1,o):new t(O,e,h,_,m,A,C,U,-d,-j,-R,W,0,0,0,1)};t.computePerspectiveFieldOfView=function(n,o,c,y,p){f.typeOf.number.greaterThan("fovY",n,0),f.typeOf.number.lessThan("fovY",n,Math.PI),f.typeOf.number.greaterThan("near",c,0),f.typeOf.number.greaterThan("far",y,0),f.typeOf.object("result",p);let e=1/Math.tan(n*.5),h=e/o,d=(y+c)/(c-y),j=2*y*c/(c-y);return p[0]=h,p[1]=0,p[2]=0,p[3]=0,p[4]=0,p[5]=e,p[6]=0,p[7]=0,p[8]=0,p[9]=0,p[10]=d,p[11]=-1,p[12]=0,p[13]=0,p[14]=j,p[15]=0,p};t.computeOrthographicOffCenter=function(n,o,c,y,p,O,e){f.typeOf.number("left",n),f.typeOf.number("right",o),f.typeOf.number("bottom",c),f.typeOf.number("top",y),f.typeOf.number("near",p),f.typeOf.number("far",O),f.typeOf.object("result",e);let h=1/(o-n),d=1/(y-c),j=1/(O-p),R=-(o+n)*h,m=-(y+c)*d,A=-(O+p)*j;return h*=2,d*=2,j*=-2,e[0]=h,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=d,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=j,e[11]=0,e[12]=R,e[13]=m,e[14]=A,e[15]=1,e};t.computePerspectiveOffCenter=function(n,o,c,y,p,O,e){f.typeOf.number("left",n),f.typeOf.number("right",o),f.typeOf.number("bottom",c),f.typeOf.number("top",y),f.typeOf.number("near",p),f.typeOf.number("far",O),f.typeOf.object("result",e);let h=2*p/(o-n),d=2*p/(y-c),j=(o+n)/(o-n),R=(y+c)/(y-c),m=-(O+p)/(O-p),A=-1,C=-2*O*p/(O-p);return e[0]=h,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=d,e[6]=0,e[7]=0,e[8]=j,e[9]=R,e[10]=m,e[11]=A,e[12]=0,e[13]=0,e[14]=C,e[15]=0,e};t.computeInfinitePerspectiveOffCenter=function(n,o,c,y,p,O){f.typeOf.number("left",n),f.typeOf.number("right",o),f.typeOf.number("bottom",c),f.typeOf.number("top",y),f.typeOf.number("near",p),f.typeOf.object("result",O);let e=2*p/(o-n),h=2*p/(y-c),d=(o+n)/(o-n),j=(y+c)/(y-c),R=-1,m=-1,A=-2*p;return O[0]=e,O[1]=0,O[2]=0,O[3]=0,O[4]=0,O[5]=h,O[6]=0,O[7]=0,O[8]=d,O[9]=j,O[10]=R,O[11]=m,O[12]=0,O[13]=0,O[14]=A,O[15]=0,O};t.computeViewportTransformation=function(n,o,c,y){M(y)||(y=new t),n=T(n,T.EMPTY_OBJECT);let p=T(n.x,0),O=T(n.y,0),e=T(n.width,0),h=T(n.height,0);o=T(o,0),c=T(c,1);let d=e*.5,j=h*.5,R=(c-o)*.5,m=d,A=j,C=R,N=p+d,S=O+j,P=o+R,_=1;return y[0]=m,y[1]=0,y[2]=0,y[3]=0,y[4]=0,y[5]=A,y[6]=0,y[7]=0,y[8]=0,y[9]=0,y[10]=C,y[11]=0,y[12]=N,y[13]=S,y[14]=P,y[15]=_,y};t.computeView=function(n,o,c,y,p){return f.typeOf.object("position",n),f.typeOf.object("direction",o),f.typeOf.object("up",c),f.typeOf.object("right",y),f.typeOf.object("result",p),p[0]=y.x,p[1]=c.x,p[2]=-o.x,p[3]=0,p[4]=y.y,p[5]=c.y,p[6]=-o.y,p[7]=0,p[8]=y.z,p[9]=c.z,p[10]=-o.z,p[11]=0,p[12]=-L.dot(y,n),p[13]=-L.dot(c,n),p[14]=L.dot(o,n),p[15]=1,p};t.toArray=function(n,o){return f.typeOf.object("matrix",n),M(o)?(o[0]=n[0],o[1]=n[1],o[2]=n[2],o[3]=n[3],o[4]=n[4],o[5]=n[5],o[6]=n[6],o[7]=n[7],o[8]=n[8],o[9]=n[9],o[10]=n[10],o[11]=n[11],o[12]=n[12],o[13]=n[13],o[14]=n[14],o[15]=n[15],o):[n[0],n[1],n[2],n[3],n[4],n[5],n[6],n[7],n[8],n[9],n[10],n[11],n[12],n[13],n[14],n[15]]};t.getElementIndex=function(n,o){return f.typeOf.number.greaterThanOrEquals("row",o,0),f.typeOf.number.lessThanOrEquals("row",o,3),f.typeOf.number.greaterThanOrEquals("column",n,0),f.typeOf.number.lessThanOrEquals("column",n,3),n*4+o};t.getColumn=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.number.greaterThanOrEquals("index",o,0),f.typeOf.number.lessThanOrEquals("index",o,3),f.typeOf.object("result",c);let y=o*4,p=n[y],O=n[y+1],e=n[y+2],h=n[y+3];return c.x=p,c.y=O,c.z=e,c.w=h,c};t.setColumn=function(n,o,c,y){f.typeOf.object("matrix",n),f.typeOf.number.greaterThanOrEquals("index",o,0),f.typeOf.number.lessThanOrEquals("index",o,3),f.typeOf.object("cartesian",c),f.typeOf.object("result",y),y=t.clone(n,y);let p=o*4;return y[p]=c.x,y[p+1]=c.y,y[p+2]=c.z,y[p+3]=c.w,y};t.getRow=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.number.greaterThanOrEquals("index",o,0),f.typeOf.number.lessThanOrEquals("index",o,3),f.typeOf.object("result",c);let y=n[o],p=n[o+4],O=n[o+8],e=n[o+12];return c.x=y,c.y=p,c.z=O,c.w=e,c};t.setRow=function(n,o,c,y){return f.typeOf.object("matrix",n),f.typeOf.number.greaterThanOrEquals("index",o,0),f.typeOf.number.lessThanOrEquals("index",o,3),f.typeOf.object("cartesian",c),f.typeOf.object("result",y),y=t.clone(n,y),y[o]=c.x,y[o+4]=c.y,y[o+8]=c.z,y[o+12]=c.w,y};t.setTranslation=function(n,o,c){return f.typeOf.object("matrix",n),f.typeOf.object("translation",o),f.typeOf.object("result",c),c[0]=n[0],c[1]=n[1],c[2]=n[2],c[3]=n[3],c[4]=n[4],c[5]=n[5],c[6]=n[6],c[7]=n[7],c[8]=n[8],c[9]=n[9],c[10]=n[10],c[11]=n[11],c[12]=o.x,c[13]=o.y,c[14]=o.z,c[15]=n[15],c};var Bn=new L;t.setScale=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("scale",o),f.typeOf.object("result",c);let y=t.getScale(n,Bn),p=o.x/y.x,O=o.y/y.y,e=o.z/y.z;return c[0]=n[0]*p,c[1]=n[1]*p,c[2]=n[2]*p,c[3]=n[3],c[4]=n[4]*O,c[5]=n[5]*O,c[6]=n[6]*O,c[7]=n[7],c[8]=n[8]*e,c[9]=n[9]*e,c[10]=n[10]*e,c[11]=n[11],c[12]=n[12],c[13]=n[13],c[14]=n[14],c[15]=n[15],c};var $n=new L;t.setUniformScale=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.number("scale",o),f.typeOf.object("result",c);let y=t.getScale(n,$n),p=o/y.x,O=o/y.y,e=o/y.z;return c[0]=n[0]*p,c[1]=n[1]*p,c[2]=n[2]*p,c[3]=n[3],c[4]=n[4]*O,c[5]=n[5]*O,c[6]=n[6]*O,c[7]=n[7],c[8]=n[8]*e,c[9]=n[9]*e,c[10]=n[10]*e,c[11]=n[11],c[12]=n[12],c[13]=n[13],c[14]=n[14],c[15]=n[15],c};var Tn=new L;t.getScale=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),o.x=L.magnitude(L.fromElements(n[0],n[1],n[2],Tn)),o.y=L.magnitude(L.fromElements(n[4],n[5],n[6],Tn)),o.z=L.magnitude(L.fromElements(n[8],n[9],n[10],Tn)),o};var qn=new L;t.getMaximumScale=function(n){return t.getScale(n,qn),L.maximumComponent(qn)};var Yn=new L;t.setRotation=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("result",c);let y=t.getScale(n,Yn);return c[0]=o[0]*y.x,c[1]=o[1]*y.x,c[2]=o[2]*y.x,c[3]=n[3],c[4]=o[3]*y.y,c[5]=o[4]*y.y,c[6]=o[5]*y.y,c[7]=n[7],c[8]=o[6]*y.z,c[9]=o[7]*y.z,c[10]=o[8]*y.z,c[11]=n[11],c[12]=n[12],c[13]=n[13],c[14]=n[14],c[15]=n[15],c};var Zn=new L;t.getRotation=function(n,o){f.typeOf.object("matrix",n),f.typeOf.object("result",o);let c=t.getScale(n,Zn);return o[0]=n[0]/c.x,o[1]=n[1]/c.x,o[2]=n[2]/c.x,o[3]=n[4]/c.y,o[4]=n[5]/c.y,o[5]=n[6]/c.y,o[6]=n[8]/c.z,o[7]=n[9]/c.z,o[8]=n[10]/c.z,o};t.multiply=function(n,o,c){f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c);let y=n[0],p=n[1],O=n[2],e=n[3],h=n[4],d=n[5],j=n[6],R=n[7],m=n[8],A=n[9],C=n[10],N=n[11],S=n[12],P=n[13],_=n[14],U=n[15],W=o[0],i=o[1],k=o[2],V=o[3],X=o[4],B=o[5],$=o[6],Z=o[7],I=o[8],D=o[9],G=o[10],K=o[11],F=o[12],v=o[13],g=o[14],u=o[15],l=y*W+h*i+m*k+S*V,r=p*W+d*i+A*k+P*V,nn=O*W+j*i+C*k+_*V,on=e*W+R*i+N*k+U*V,en=y*X+h*B+m*$+S*Z,tn=p*X+d*B+A*$+P*Z,bn=O*X+j*B+C*$+_*Z,hn=e*X+R*B+N*$+U*Z,wn=y*I+h*D+m*G+S*K,jn=p*I+d*D+A*G+P*K,Mn=O*I+j*D+C*G+_*K,Y=e*I+R*D+N*G+U*K,_n=y*F+h*v+m*g+S*u,Un=p*F+d*v+A*g+P*u,Wn=O*F+j*v+C*g+_*u,Ln=e*F+R*v+N*g+U*u;return c[0]=l,c[1]=r,c[2]=nn,c[3]=on,c[4]=en,c[5]=tn,c[6]=bn,c[7]=hn,c[8]=wn,c[9]=jn,c[10]=Mn,c[11]=Y,c[12]=_n,c[13]=Un,c[14]=Wn,c[15]=Ln,c};t.add=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c[0]=n[0]+o[0],c[1]=n[1]+o[1],c[2]=n[2]+o[2],c[3]=n[3]+o[3],c[4]=n[4]+o[4],c[5]=n[5]+o[5],c[6]=n[6]+o[6],c[7]=n[7]+o[7],c[8]=n[8]+o[8],c[9]=n[9]+o[9],c[10]=n[10]+o[10],c[11]=n[11]+o[11],c[12]=n[12]+o[12],c[13]=n[13]+o[13],c[14]=n[14]+o[14],c[15]=n[15]+o[15],c};t.subtract=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c[0]=n[0]-o[0],c[1]=n[1]-o[1],c[2]=n[2]-o[2],c[3]=n[3]-o[3],c[4]=n[4]-o[4],c[5]=n[5]-o[5],c[6]=n[6]-o[6],c[7]=n[7]-o[7],c[8]=n[8]-o[8],c[9]=n[9]-o[9],c[10]=n[10]-o[10],c[11]=n[11]-o[11],c[12]=n[12]-o[12],c[13]=n[13]-o[13],c[14]=n[14]-o[14],c[15]=n[15]-o[15],c};t.multiplyTransformation=function(n,o,c){f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c);let y=n[0],p=n[1],O=n[2],e=n[4],h=n[5],d=n[6],j=n[8],R=n[9],m=n[10],A=n[12],C=n[13],N=n[14],S=o[0],P=o[1],_=o[2],U=o[4],W=o[5],i=o[6],k=o[8],V=o[9],X=o[10],B=o[12],$=o[13],Z=o[14],I=y*S+e*P+j*_,D=p*S+h*P+R*_,G=O*S+d*P+m*_,K=y*U+e*W+j*i,F=p*U+h*W+R*i,v=O*U+d*W+m*i,g=y*k+e*V+j*X,u=p*k+h*V+R*X,l=O*k+d*V+m*X,r=y*B+e*$+j*Z+A,nn=p*B+h*$+R*Z+C,on=O*B+d*$+m*Z+N;return c[0]=I,c[1]=D,c[2]=G,c[3]=0,c[4]=K,c[5]=F,c[6]=v,c[7]=0,c[8]=g,c[9]=u,c[10]=l,c[11]=0,c[12]=r,c[13]=nn,c[14]=on,c[15]=1,c};t.multiplyByMatrix3=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("rotation",o),f.typeOf.object("result",c);let y=n[0],p=n[1],O=n[2],e=n[4],h=n[5],d=n[6],j=n[8],R=n[9],m=n[10],A=o[0],C=o[1],N=o[2],S=o[3],P=o[4],_=o[5],U=o[6],W=o[7],i=o[8],k=y*A+e*C+j*N,V=p*A+h*C+R*N,X=O*A+d*C+m*N,B=y*S+e*P+j*_,$=p*S+h*P+R*_,Z=O*S+d*P+m*_,I=y*U+e*W+j*i,D=p*U+h*W+R*i,G=O*U+d*W+m*i;return c[0]=k,c[1]=V,c[2]=X,c[3]=0,c[4]=B,c[5]=$,c[6]=Z,c[7]=0,c[8]=I,c[9]=D,c[10]=G,c[11]=0,c[12]=n[12],c[13]=n[13],c[14]=n[14],c[15]=n[15],c};t.multiplyByTranslation=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("translation",o),f.typeOf.object("result",c);let y=o.x,p=o.y,O=o.z,e=y*n[0]+p*n[4]+O*n[8]+n[12],h=y*n[1]+p*n[5]+O*n[9]+n[13],d=y*n[2]+p*n[6]+O*n[10]+n[14];return c[0]=n[0],c[1]=n[1],c[2]=n[2],c[3]=n[3],c[4]=n[4],c[5]=n[5],c[6]=n[6],c[7]=n[7],c[8]=n[8],c[9]=n[9],c[10]=n[10],c[11]=n[11],c[12]=e,c[13]=h,c[14]=d,c[15]=n[15],c};t.multiplyByScale=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("scale",o),f.typeOf.object("result",c);let y=o.x,p=o.y,O=o.z;return y===1&&p===1&&O===1?t.clone(n,c):(c[0]=y*n[0],c[1]=y*n[1],c[2]=y*n[2],c[3]=n[3],c[4]=p*n[4],c[5]=p*n[5],c[6]=p*n[6],c[7]=n[7],c[8]=O*n[8],c[9]=O*n[9],c[10]=O*n[10],c[11]=n[11],c[12]=n[12],c[13]=n[13],c[14]=n[14],c[15]=n[15],c)};t.multiplyByUniformScale=function(n,o,c){return f.typeOf.object("matrix",n),f.typeOf.number("scale",o),f.typeOf.object("result",c),c[0]=n[0]*o,c[1]=n[1]*o,c[2]=n[2]*o,c[3]=n[3],c[4]=n[4]*o,c[5]=n[5]*o,c[6]=n[6]*o,c[7]=n[7],c[8]=n[8]*o,c[9]=n[9]*o,c[10]=n[10]*o,c[11]=n[11],c[12]=n[12],c[13]=n[13],c[14]=n[14],c[15]=n[15],c};t.multiplyByVector=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("cartesian",o),f.typeOf.object("result",c);let y=o.x,p=o.y,O=o.z,e=o.w,h=n[0]*y+n[4]*p+n[8]*O+n[12]*e,d=n[1]*y+n[5]*p+n[9]*O+n[13]*e,j=n[2]*y+n[6]*p+n[10]*O+n[14]*e,R=n[3]*y+n[7]*p+n[11]*O+n[15]*e;return c.x=h,c.y=d,c.z=j,c.w=R,c};t.multiplyByPointAsVector=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("cartesian",o),f.typeOf.object("result",c);let y=o.x,p=o.y,O=o.z,e=n[0]*y+n[4]*p+n[8]*O,h=n[1]*y+n[5]*p+n[9]*O,d=n[2]*y+n[6]*p+n[10]*O;return c.x=e,c.y=h,c.z=d,c};t.multiplyByPoint=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("cartesian",o),f.typeOf.object("result",c);let y=o.x,p=o.y,O=o.z,e=n[0]*y+n[4]*p+n[8]*O+n[12],h=n[1]*y+n[5]*p+n[9]*O+n[13],d=n[2]*y+n[6]*p+n[10]*O+n[14];return c.x=e,c.y=h,c.z=d,c};t.multiplyByScalar=function(n,o,c){return f.typeOf.object("matrix",n),f.typeOf.number("scalar",o),f.typeOf.object("result",c),c[0]=n[0]*o,c[1]=n[1]*o,c[2]=n[2]*o,c[3]=n[3]*o,c[4]=n[4]*o,c[5]=n[5]*o,c[6]=n[6]*o,c[7]=n[7]*o,c[8]=n[8]*o,c[9]=n[9]*o,c[10]=n[10]*o,c[11]=n[11]*o,c[12]=n[12]*o,c[13]=n[13]*o,c[14]=n[14]*o,c[15]=n[15]*o,c};t.negate=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),o[0]=-n[0],o[1]=-n[1],o[2]=-n[2],o[3]=-n[3],o[4]=-n[4],o[5]=-n[5],o[6]=-n[6],o[7]=-n[7],o[8]=-n[8],o[9]=-n[9],o[10]=-n[10],o[11]=-n[11],o[12]=-n[12],o[13]=-n[13],o[14]=-n[14],o[15]=-n[15],o};t.transpose=function(n,o){f.typeOf.object("matrix",n),f.typeOf.object("result",o);let c=n[1],y=n[2],p=n[3],O=n[6],e=n[7],h=n[11];return o[0]=n[0],o[1]=n[4],o[2]=n[8],o[3]=n[12],o[4]=c,o[5]=n[5],o[6]=n[9],o[7]=n[13],o[8]=y,o[9]=O,o[10]=n[10],o[11]=n[14],o[12]=p,o[13]=e,o[14]=h,o[15]=n[15],o};t.abs=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),o[0]=Math.abs(n[0]),o[1]=Math.abs(n[1]),o[2]=Math.abs(n[2]),o[3]=Math.abs(n[3]),o[4]=Math.abs(n[4]),o[5]=Math.abs(n[5]),o[6]=Math.abs(n[6]),o[7]=Math.abs(n[7]),o[8]=Math.abs(n[8]),o[9]=Math.abs(n[9]),o[10]=Math.abs(n[10]),o[11]=Math.abs(n[11]),o[12]=Math.abs(n[12]),o[13]=Math.abs(n[13]),o[14]=Math.abs(n[14]),o[15]=Math.abs(n[15]),o};t.equals=function(n,o){return n===o||M(n)&&M(o)&&n[12]===o[12]&&n[13]===o[13]&&n[14]===o[14]&&n[0]===o[0]&&n[1]===o[1]&&n[2]===o[2]&&n[4]===o[4]&&n[5]===o[5]&&n[6]===o[6]&&n[8]===o[8]&&n[9]===o[9]&&n[10]===o[10]&&n[3]===o[3]&&n[7]===o[7]&&n[11]===o[11]&&n[15]===o[15]};t.equalsEpsilon=function(n,o,c){return c=T(c,0),n===o||M(n)&&M(o)&&Math.abs(n[0]-o[0])<=c&&Math.abs(n[1]-o[1])<=c&&Math.abs(n[2]-o[2])<=c&&Math.abs(n[3]-o[3])<=c&&Math.abs(n[4]-o[4])<=c&&Math.abs(n[5]-o[5])<=c&&Math.abs(n[6]-o[6])<=c&&Math.abs(n[7]-o[7])<=c&&Math.abs(n[8]-o[8])<=c&&Math.abs(n[9]-o[9])<=c&&Math.abs(n[10]-o[10])<=c&&Math.abs(n[11]-o[11])<=c&&Math.abs(n[12]-o[12])<=c&&Math.abs(n[13]-o[13])<=c&&Math.abs(n[14]-o[14])<=c&&Math.abs(n[15]-o[15])<=c};t.getTranslation=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),o.x=n[12],o.y=n[13],o.z=n[14],o};t.getMatrix3=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),o[0]=n[0],o[1]=n[1],o[2]=n[2],o[3]=n[4],o[4]=n[5],o[5]=n[6],o[6]=n[8],o[7]=n[9],o[8]=n[10],o};var In=new cn,Dn=new cn,Gn=new pn,Qn=new pn(0,0,0,1);t.inverse=function(n,o){f.typeOf.object("matrix",n),f.typeOf.object("result",o);let c=n[0],y=n[4],p=n[8],O=n[12],e=n[1],h=n[5],d=n[9],j=n[13],R=n[2],m=n[6],A=n[10],C=n[14],N=n[3],S=n[7],P=n[11],_=n[15],U=A*_,W=C*P,i=m*_,k=C*S,V=m*P,X=A*S,B=R*_,$=C*N,Z=R*P,I=A*N,D=R*S,G=m*N,K=U*h+k*d+V*j-(W*h+i*d+X*j),F=W*e+B*d+I*j-(U*e+$*d+Z*j),v=i*e+$*h+D*j-(k*e+B*h+G*j),g=X*e+Z*h+G*d-(V*e+I*h+D*d),u=W*y+i*p+X*O-(U*y+k*p+V*O),l=U*c+$*p+Z*O-(W*c+B*p+I*O),r=k*c+B*y+G*O-(i*c+$*y+D*O),nn=V*c+I*y+D*p-(X*c+Z*y+G*p);U=p*j,W=O*d,i=y*j,k=O*h,V=y*d,X=p*h,B=c*j,$=O*e,Z=c*d,I=p*e,D=c*h,G=y*e;let on=U*S+k*P+V*_-(W*S+i*P+X*_),en=W*N+B*P+I*_-(U*N+$*P+Z*_),tn=i*N+$*S+D*_-(k*N+B*S+G*_),bn=X*N+Z*S+G*P-(V*N+I*S+D*P),hn=i*A+X*C+W*m-(V*C+U*m+k*A),wn=Z*C+U*R+$*A-(B*A+I*C+W*R),jn=B*m+G*C+k*R-(D*C+i*R+$*m),Mn=D*A+V*R+I*m-(Z*m+G*A+X*R),Y=c*K+y*F+p*v+O*g;if(Math.abs(Y)<E.EPSILON21){if(cn.equalsEpsilon(t.getMatrix3(n,In),Dn,E.EPSILON7)&&pn.equals(t.getRow(n,3,Gn),Qn))return o[0]=0,o[1]=0,o[2]=0,o[3]=0,o[4]=0,o[5]=0,o[6]=0,o[7]=0,o[8]=0,o[9]=0,o[10]=0,o[11]=0,o[12]=-n[12],o[13]=-n[13],o[14]=-n[14],o[15]=1,o;throw new Rn("matrix is not invertible because its determinate is zero.")}return Y=1/Y,o[0]=K*Y,o[1]=F*Y,o[2]=v*Y,o[3]=g*Y,o[4]=u*Y,o[5]=l*Y,o[6]=r*Y,o[7]=nn*Y,o[8]=on*Y,o[9]=en*Y,o[10]=tn*Y,o[11]=bn*Y,o[12]=hn*Y,o[13]=wn*Y,o[14]=jn*Y,o[15]=Mn*Y,o};t.inverseTransformation=function(n,o){f.typeOf.object("matrix",n),f.typeOf.object("result",o);let c=n[0],y=n[1],p=n[2],O=n[4],e=n[5],h=n[6],d=n[8],j=n[9],R=n[10],m=n[12],A=n[13],C=n[14],N=-c*m-y*A-p*C,S=-O*m-e*A-h*C,P=-d*m-j*A-R*C;return o[0]=c,o[1]=O,o[2]=d,o[3]=0,o[4]=y,o[5]=e,o[6]=j,o[7]=0,o[8]=p,o[9]=h,o[10]=R,o[11]=0,o[12]=N,o[13]=S,o[14]=P,o[15]=1,o};var Hn=new t;t.inverseTranspose=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),t.inverse(t.transpose(n,Hn),o)};t.IDENTITY=Object.freeze(new t(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1));t.ZERO=Object.freeze(new t(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0));t.COLUMN0ROW0=0;t.COLUMN0ROW1=1;t.COLUMN0ROW2=2;t.COLUMN0ROW3=3;t.COLUMN1ROW0=4;t.COLUMN1ROW1=5;t.COLUMN1ROW2=6;t.COLUMN1ROW3=7;t.COLUMN2ROW0=8;t.COLUMN2ROW1=9;t.COLUMN2ROW2=10;t.COLUMN2ROW3=11;t.COLUMN3ROW0=12;t.COLUMN3ROW1=13;t.COLUMN3ROW2=14;t.COLUMN3ROW3=15;Object.defineProperties(t.prototype,{length:{get:function(){return t.packedLength}}});t.prototype.clone=function(n){return t.clone(this,n)};t.prototype.equals=function(n){return t.equals(this,n)};t.equalsArray=function(n,o,c){return n[0]===o[c]&&n[1]===o[c+1]&&n[2]===o[c+2]&&n[3]===o[c+3]&&n[4]===o[c+4]&&n[5]===o[c+5]&&n[6]===o[c+6]&&n[7]===o[c+7]&&n[8]===o[c+8]&&n[9]===o[c+9]&&n[10]===o[c+10]&&n[11]===o[c+11]&&n[12]===o[c+12]&&n[13]===o[c+13]&&n[14]===o[c+14]&&n[15]===o[c+15]};t.prototype.equalsEpsilon=function(n,o){return t.equalsEpsilon(this,n,o)};t.prototype.toString=function(){return`(${this[0]}, ${this[4]}, ${this[8]}, ${this[12]})
  26. (${this[1]}, ${this[5]}, ${this[9]}, ${this[13]})
  27. (${this[2]}, ${this[6]}, ${this[10]}, ${this[14]})
  28. (${this[3]}, ${this[7]}, ${this[11]}, ${this[15]})`};var ho=t;function q(n,o,c,y){this.west=T(n,0),this.south=T(o,0),this.east=T(c,0),this.north=T(y,0)}Object.defineProperties(q.prototype,{width:{get:function(){return q.computeWidth(this)}},height:{get:function(){return q.computeHeight(this)}}});q.packedLength=4;q.pack=function(n,o,c){return f.typeOf.object("value",n),f.defined("array",o),c=T(c,0),o[c++]=n.west,o[c++]=n.south,o[c++]=n.east,o[c]=n.north,o};q.unpack=function(n,o,c){return f.defined("array",n),o=T(o,0),M(c)||(c=new q),c.west=n[o++],c.south=n[o++],c.east=n[o++],c.north=n[o],c};q.computeWidth=function(n){f.typeOf.object("rectangle",n);let o=n.east,c=n.west;return o<c&&(o+=E.TWO_PI),o-c};q.computeHeight=function(n){return f.typeOf.object("rectangle",n),n.north-n.south};q.fromDegrees=function(n,o,c,y,p){return n=E.toRadians(T(n,0)),o=E.toRadians(T(o,0)),c=E.toRadians(T(c,0)),y=E.toRadians(T(y,0)),M(p)?(p.west=n,p.south=o,p.east=c,p.north=y,p):new q(n,o,c,y)};q.fromRadians=function(n,o,c,y,p){return M(p)?(p.west=T(n,0),p.south=T(o,0),p.east=T(c,0),p.north=T(y,0),p):new q(n,o,c,y)};q.fromCartographicArray=function(n,o){f.defined("cartographics",n);let c=Number.MAX_VALUE,y=-Number.MAX_VALUE,p=Number.MAX_VALUE,O=-Number.MAX_VALUE,e=Number.MAX_VALUE,h=-Number.MAX_VALUE;for(let d=0,j=n.length;d<j;d++){let R=n[d];c=Math.min(c,R.longitude),y=Math.max(y,R.longitude),e=Math.min(e,R.latitude),h=Math.max(h,R.latitude);let m=R.longitude>=0?R.longitude:R.longitude+E.TWO_PI;p=Math.min(p,m),O=Math.max(O,m)}return y-c>O-p&&(c=p,y=O,y>E.PI&&(y=y-E.TWO_PI),c>E.PI&&(c=c-E.TWO_PI)),M(o)?(o.west=c,o.south=e,o.east=y,o.north=h,o):new q(c,e,y,h)};q.fromCartesianArray=function(n,o,c){f.defined("cartesians",n),o=T(o,dn.WGS84);let y=Number.MAX_VALUE,p=-Number.MAX_VALUE,O=Number.MAX_VALUE,e=-Number.MAX_VALUE,h=Number.MAX_VALUE,d=-Number.MAX_VALUE;for(let j=0,R=n.length;j<R;j++){let m=o.cartesianToCartographic(n[j]);y=Math.min(y,m.longitude),p=Math.max(p,m.longitude),h=Math.min(h,m.latitude),d=Math.max(d,m.latitude);let A=m.longitude>=0?m.longitude:m.longitude+E.TWO_PI;O=Math.min(O,A),e=Math.max(e,A)}return p-y>e-O&&(y=O,p=e,p>E.PI&&(p=p-E.TWO_PI),y>E.PI&&(y=y-E.TWO_PI)),M(c)?(c.west=y,c.south=h,c.east=p,c.north=d,c):new q(y,h,p,d)};q.clone=function(n,o){if(M(n))return M(o)?(o.west=n.west,o.south=n.south,o.east=n.east,o.north=n.north,o):new q(n.west,n.south,n.east,n.north)};q.equalsEpsilon=function(n,o,c){return c=T(c,0),n===o||M(n)&&M(o)&&Math.abs(n.west-o.west)<=c&&Math.abs(n.south-o.south)<=c&&Math.abs(n.east-o.east)<=c&&Math.abs(n.north-o.north)<=c};q.prototype.clone=function(n){return q.clone(this,n)};q.prototype.equals=function(n){return q.equals(this,n)};q.equals=function(n,o){return n===o||M(n)&&M(o)&&n.west===o.west&&n.south===o.south&&n.east===o.east&&n.north===o.north};q.prototype.equalsEpsilon=function(n,o){return q.equalsEpsilon(this,n,o)};q.validate=function(n){f.typeOf.object("rectangle",n);let o=n.north;f.typeOf.number.greaterThanOrEquals("north",o,-E.PI_OVER_TWO),f.typeOf.number.lessThanOrEquals("north",o,E.PI_OVER_TWO);let c=n.south;f.typeOf.number.greaterThanOrEquals("south",c,-E.PI_OVER_TWO),f.typeOf.number.lessThanOrEquals("south",c,E.PI_OVER_TWO);let y=n.west;f.typeOf.number.greaterThanOrEquals("west",y,-Math.PI),f.typeOf.number.lessThanOrEquals("west",y,Math.PI);let p=n.east;f.typeOf.number.greaterThanOrEquals("east",p,-Math.PI),f.typeOf.number.lessThanOrEquals("east",p,Math.PI)};q.southwest=function(n,o){return f.typeOf.object("rectangle",n),M(o)?(o.longitude=n.west,o.latitude=n.south,o.height=0,o):new x(n.west,n.south)};q.northwest=function(n,o){return f.typeOf.object("rectangle",n),M(o)?(o.longitude=n.west,o.latitude=n.north,o.height=0,o):new x(n.west,n.north)};q.northeast=function(n,o){return f.typeOf.object("rectangle",n),M(o)?(o.longitude=n.east,o.latitude=n.north,o.height=0,o):new x(n.east,n.north)};q.southeast=function(n,o){return f.typeOf.object("rectangle",n),M(o)?(o.longitude=n.east,o.latitude=n.south,o.height=0,o):new x(n.east,n.south)};q.center=function(n,o){f.typeOf.object("rectangle",n);let c=n.east,y=n.west;c<y&&(c+=E.TWO_PI);let p=E.negativePiToPi((y+c)*.5),O=(n.south+n.north)*.5;return M(o)?(o.longitude=p,o.latitude=O,o.height=0,o):new x(p,O)};q.intersection=function(n,o,c){f.typeOf.object("rectangle",n),f.typeOf.object("otherRectangle",o);let y=n.east,p=n.west,O=o.east,e=o.west;y<p&&O>0?y+=E.TWO_PI:O<e&&y>0&&(O+=E.TWO_PI),y<p&&e<0?e+=E.TWO_PI:O<e&&p<0&&(p+=E.TWO_PI);let h=E.negativePiToPi(Math.max(p,e)),d=E.negativePiToPi(Math.min(y,O));if((n.west<n.east||o.west<o.east)&&d<=h)return;let j=Math.max(n.south,o.south),R=Math.min(n.north,o.north);if(!(j>=R))return M(c)?(c.west=h,c.south=j,c.east=d,c.north=R,c):new q(h,j,d,R)};q.simpleIntersection=function(n,o,c){f.typeOf.object("rectangle",n),f.typeOf.object("otherRectangle",o);let y=Math.max(n.west,o.west),p=Math.max(n.south,o.south),O=Math.min(n.east,o.east),e=Math.min(n.north,o.north);if(!(p>=e||y>=O))return M(c)?(c.west=y,c.south=p,c.east=O,c.north=e,c):new q(y,p,O,e)};q.union=function(n,o,c){f.typeOf.object("rectangle",n),f.typeOf.object("otherRectangle",o),M(c)||(c=new q);let y=n.east,p=n.west,O=o.east,e=o.west;y<p&&O>0?y+=E.TWO_PI:O<e&&y>0&&(O+=E.TWO_PI),y<p&&e<0?e+=E.TWO_PI:O<e&&p<0&&(p+=E.TWO_PI);let h=E.negativePiToPi(Math.min(p,e)),d=E.negativePiToPi(Math.max(y,O));return c.west=h,c.south=Math.min(n.south,o.south),c.east=d,c.north=Math.max(n.north,o.north),c};q.expand=function(n,o,c){return f.typeOf.object("rectangle",n),f.typeOf.object("cartographic",o),M(c)||(c=new q),c.west=Math.min(n.west,o.longitude),c.south=Math.min(n.south,o.latitude),c.east=Math.max(n.east,o.longitude),c.north=Math.max(n.north,o.latitude),c};q.contains=function(n,o){f.typeOf.object("rectangle",n),f.typeOf.object("cartographic",o);let c=o.longitude,y=o.latitude,p=n.west,O=n.east;return O<p&&(O+=E.TWO_PI,c<0&&(c+=E.TWO_PI)),(c>p||E.equalsEpsilon(c,p,E.EPSILON14))&&(c<O||E.equalsEpsilon(c,O,E.EPSILON14))&&y>=n.south&&y<=n.north};var Jn=new x;q.subsample=function(n,o,c,y){f.typeOf.object("rectangle",n),o=T(o,dn.WGS84),c=T(c,0),M(y)||(y=[]);let p=0,O=n.north,e=n.south,h=n.east,d=n.west,j=Jn;j.height=c,j.longitude=d,j.latitude=O,y[p]=o.cartographicToCartesian(j,y[p]),p++,j.longitude=h,y[p]=o.cartographicToCartesian(j,y[p]),p++,j.latitude=e,y[p]=o.cartographicToCartesian(j,y[p]),p++,j.longitude=d,y[p]=o.cartographicToCartesian(j,y[p]),p++,O<0?j.latitude=O:e>0?j.latitude=e:j.latitude=0;for(let R=1;R<8;++R)j.longitude=-Math.PI+R*E.PI_OVER_TWO,q.contains(n,j)&&(y[p]=o.cartographicToCartesian(j,y[p]),p++);return j.latitude===0&&(j.longitude=d,y[p]=o.cartographicToCartesian(j,y[p]),p++,j.longitude=h,y[p]=o.cartographicToCartesian(j,y[p]),p++),y.length=p,y};q.subsection=function(n,o,c,y,p,O){if(f.typeOf.object("rectangle",n),f.typeOf.number.greaterThanOrEquals("westLerp",o,0),f.typeOf.number.lessThanOrEquals("westLerp",o,1),f.typeOf.number.greaterThanOrEquals("southLerp",c,0),f.typeOf.number.lessThanOrEquals("southLerp",c,1),f.typeOf.number.greaterThanOrEquals("eastLerp",y,0),f.typeOf.number.lessThanOrEquals("eastLerp",y,1),f.typeOf.number.greaterThanOrEquals("northLerp",p,0),f.typeOf.number.lessThanOrEquals("northLerp",p,1),f.typeOf.number.lessThanOrEquals("westLerp",o,y),f.typeOf.number.lessThanOrEquals("southLerp",c,p),M(O)||(O=new q),n.west<=n.east){let h=n.east-n.west;O.west=n.west+o*h,O.east=n.west+y*h}else{let h=E.TWO_PI+n.east-n.west;O.west=E.negativePiToPi(n.west+o*h),O.east=E.negativePiToPi(n.west+y*h)}let e=n.north-n.south;return O.south=n.south+c*e,O.north=n.south+p*e,o===1&&(O.west=n.east),y===1&&(O.east=n.east),c===1&&(O.south=n.north),p===1&&(O.north=n.north),O};q.MAX_VALUE=Object.freeze(new q(-Math.PI,-E.PI_OVER_TWO,Math.PI,E.PI_OVER_TWO));var mo=q;function w(n,o){this.x=T(n,0),this.y=T(o,0)}w.fromElements=function(n,o,c){return M(c)?(c.x=n,c.y=o,c):new w(n,o)};w.clone=function(n,o){if(M(n))return M(o)?(o.x=n.x,o.y=n.y,o):new w(n.x,n.y)};w.fromCartesian3=w.clone;w.fromCartesian4=w.clone;w.packedLength=2;w.pack=function(n,o,c){return f.typeOf.object("value",n),f.defined("array",o),c=T(c,0),o[c++]=n.x,o[c]=n.y,o};w.unpack=function(n,o,c){return f.defined("array",n),o=T(o,0),M(c)||(c=new w),c.x=n[o++],c.y=n[o],c};w.packArray=function(n,o){f.defined("array",n);let c=n.length,y=c*2;if(!M(o))o=new Array(y);else{if(!Array.isArray(o)&&o.length!==y)throw new H("If result is a typed array, it must have exactly array.length * 2 elements");o.length!==y&&(o.length=y)}for(let p=0;p<c;++p)w.pack(n[p],o,p*2);return o};w.unpackArray=function(n,o){if(f.defined("array",n),f.typeOf.number.greaterThanOrEquals("array.length",n.length,2),n.length%2!==0)throw new H("array length must be a multiple of 2.");let c=n.length;M(o)?o.length=c/2:o=new Array(c/2);for(let y=0;y<c;y+=2){let p=y/2;o[p]=w.unpack(n,y,o[p])}return o};w.fromArray=w.unpack;w.maximumComponent=function(n){return f.typeOf.object("cartesian",n),Math.max(n.x,n.y)};w.minimumComponent=function(n){return f.typeOf.object("cartesian",n),Math.min(n.x,n.y)};w.minimumByComponent=function(n,o,c){return f.typeOf.object("first",n),f.typeOf.object("second",o),f.typeOf.object("result",c),c.x=Math.min(n.x,o.x),c.y=Math.min(n.y,o.y),c};w.maximumByComponent=function(n,o,c){return f.typeOf.object("first",n),f.typeOf.object("second",o),f.typeOf.object("result",c),c.x=Math.max(n.x,o.x),c.y=Math.max(n.y,o.y),c};w.clamp=function(n,o,c,y){f.typeOf.object("value",n),f.typeOf.object("min",o),f.typeOf.object("max",c),f.typeOf.object("result",y);let p=E.clamp(n.x,o.x,c.x),O=E.clamp(n.y,o.y,c.y);return y.x=p,y.y=O,y};w.magnitudeSquared=function(n){return f.typeOf.object("cartesian",n),n.x*n.x+n.y*n.y};w.magnitude=function(n){return Math.sqrt(w.magnitudeSquared(n))};var On=new w;w.distance=function(n,o){return f.typeOf.object("left",n),f.typeOf.object("right",o),w.subtract(n,o,On),w.magnitude(On)};w.distanceSquared=function(n,o){return f.typeOf.object("left",n),f.typeOf.object("right",o),w.subtract(n,o,On),w.magnitudeSquared(On)};w.normalize=function(n,o){f.typeOf.object("cartesian",n),f.typeOf.object("result",o);let c=w.magnitude(n);if(o.x=n.x/c,o.y=n.y/c,isNaN(o.x)||isNaN(o.y))throw new H("normalized result is not a number");return o};w.dot=function(n,o){return f.typeOf.object("left",n),f.typeOf.object("right",o),n.x*o.x+n.y*o.y};w.cross=function(n,o){return f.typeOf.object("left",n),f.typeOf.object("right",o),n.x*o.y-n.y*o.x};w.multiplyComponents=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c.x=n.x*o.x,c.y=n.y*o.y,c};w.divideComponents=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c.x=n.x/o.x,c.y=n.y/o.y,c};w.add=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c.x=n.x+o.x,c.y=n.y+o.y,c};w.subtract=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c.x=n.x-o.x,c.y=n.y-o.y,c};w.multiplyByScalar=function(n,o,c){return f.typeOf.object("cartesian",n),f.typeOf.number("scalar",o),f.typeOf.object("result",c),c.x=n.x*o,c.y=n.y*o,c};w.divideByScalar=function(n,o,c){return f.typeOf.object("cartesian",n),f.typeOf.number("scalar",o),f.typeOf.object("result",c),c.x=n.x/o,c.y=n.y/o,c};w.negate=function(n,o){return f.typeOf.object("cartesian",n),f.typeOf.object("result",o),o.x=-n.x,o.y=-n.y,o};w.abs=function(n,o){return f.typeOf.object("cartesian",n),f.typeOf.object("result",o),o.x=Math.abs(n.x),o.y=Math.abs(n.y),o};var An=new w;w.lerp=function(n,o,c,y){return f.typeOf.object("start",n),f.typeOf.object("end",o),f.typeOf.number("t",c),f.typeOf.object("result",y),w.multiplyByScalar(o,c,An),y=w.multiplyByScalar(n,1-c,y),w.add(An,y,y)};var Cn=new w,Sn=new w;w.angleBetween=function(n,o){return f.typeOf.object("left",n),f.typeOf.object("right",o),w.normalize(n,Cn),w.normalize(o,Sn),E.acosClamped(w.dot(Cn,Sn))};var Kn=new w;w.mostOrthogonalAxis=function(n,o){f.typeOf.object("cartesian",n),f.typeOf.object("result",o);let c=w.normalize(n,Kn);return w.abs(c,c),c.x<=c.y?o=w.clone(w.UNIT_X,o):o=w.clone(w.UNIT_Y,o),o};w.equals=function(n,o){return n===o||M(n)&&M(o)&&n.x===o.x&&n.y===o.y};w.equalsArray=function(n,o,c){return n.x===o[c]&&n.y===o[c+1]};w.equalsEpsilon=function(n,o,c,y){return n===o||M(n)&&M(o)&&E.equalsEpsilon(n.x,o.x,c,y)&&E.equalsEpsilon(n.y,o.y,c,y)};w.ZERO=Object.freeze(new w(0,0));w.ONE=Object.freeze(new w(1,1));w.UNIT_X=Object.freeze(new w(1,0));w.UNIT_Y=Object.freeze(new w(0,1));w.prototype.clone=function(n){return w.clone(this,n)};w.prototype.equals=function(n){return w.equals(this,n)};w.prototype.equalsEpsilon=function(n,o,c){return w.equalsEpsilon(this,n,o,c)};w.prototype.toString=function(){return`(${this.x}, ${this.y})`};var J=w;function z(n,o,c,y){this[0]=T(n,0),this[1]=T(c,0),this[2]=T(o,0),this[3]=T(y,0)}z.packedLength=4;z.pack=function(n,o,c){return f.typeOf.object("value",n),f.defined("array",o),c=T(c,0),o[c++]=n[0],o[c++]=n[1],o[c++]=n[2],o[c++]=n[3],o};z.unpack=function(n,o,c){return f.defined("array",n),o=T(o,0),M(c)||(c=new z),c[0]=n[o++],c[1]=n[o++],c[2]=n[o++],c[3]=n[o++],c};z.packArray=function(n,o){f.defined("array",n);let c=n.length,y=c*4;if(!M(o))o=new Array(y);else{if(!Array.isArray(o)&&o.length!==y)throw new H("If result is a typed array, it must have exactly array.length * 4 elements");o.length!==y&&(o.length=y)}for(let p=0;p<c;++p)z.pack(n[p],o,p*4);return o};z.unpackArray=function(n,o){if(f.defined("array",n),f.typeOf.number.greaterThanOrEquals("array.length",n.length,4),n.length%4!==0)throw new H("array length must be a multiple of 4.");let c=n.length;M(o)?o.length=c/4:o=new Array(c/4);for(let y=0;y<c;y+=4){let p=y/4;o[p]=z.unpack(n,y,o[p])}return o};z.clone=function(n,o){if(M(n))return M(o)?(o[0]=n[0],o[1]=n[1],o[2]=n[2],o[3]=n[3],o):new z(n[0],n[2],n[1],n[3])};z.fromArray=z.unpack;z.fromColumnMajorArray=function(n,o){return f.defined("values",n),z.clone(n,o)};z.fromRowMajorArray=function(n,o){return f.defined("values",n),M(o)?(o[0]=n[0],o[1]=n[2],o[2]=n[1],o[3]=n[3],o):new z(n[0],n[1],n[2],n[3])};z.fromScale=function(n,o){return f.typeOf.object("scale",n),M(o)?(o[0]=n.x,o[1]=0,o[2]=0,o[3]=n.y,o):new z(n.x,0,0,n.y)};z.fromUniformScale=function(n,o){return f.typeOf.number("scale",n),M(o)?(o[0]=n,o[1]=0,o[2]=0,o[3]=n,o):new z(n,0,0,n)};z.fromRotation=function(n,o){f.typeOf.number("angle",n);let c=Math.cos(n),y=Math.sin(n);return M(o)?(o[0]=c,o[1]=y,o[2]=-y,o[3]=c,o):new z(c,-y,y,c)};z.toArray=function(n,o){return f.typeOf.object("matrix",n),M(o)?(o[0]=n[0],o[1]=n[1],o[2]=n[2],o[3]=n[3],o):[n[0],n[1],n[2],n[3]]};z.getElementIndex=function(n,o){return f.typeOf.number.greaterThanOrEquals("row",o,0),f.typeOf.number.lessThanOrEquals("row",o,1),f.typeOf.number.greaterThanOrEquals("column",n,0),f.typeOf.number.lessThanOrEquals("column",n,1),n*2+o};z.getColumn=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.number.greaterThanOrEquals("index",o,0),f.typeOf.number.lessThanOrEquals("index",o,1),f.typeOf.object("result",c);let y=o*2,p=n[y],O=n[y+1];return c.x=p,c.y=O,c};z.setColumn=function(n,o,c,y){f.typeOf.object("matrix",n),f.typeOf.number.greaterThanOrEquals("index",o,0),f.typeOf.number.lessThanOrEquals("index",o,1),f.typeOf.object("cartesian",c),f.typeOf.object("result",y),y=z.clone(n,y);let p=o*2;return y[p]=c.x,y[p+1]=c.y,y};z.getRow=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.number.greaterThanOrEquals("index",o,0),f.typeOf.number.lessThanOrEquals("index",o,1),f.typeOf.object("result",c);let y=n[o],p=n[o+2];return c.x=y,c.y=p,c};z.setRow=function(n,o,c,y){return f.typeOf.object("matrix",n),f.typeOf.number.greaterThanOrEquals("index",o,0),f.typeOf.number.lessThanOrEquals("index",o,1),f.typeOf.object("cartesian",c),f.typeOf.object("result",y),y=z.clone(n,y),y[o]=c.x,y[o+2]=c.y,y};var Fn=new J;z.setScale=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("scale",o),f.typeOf.object("result",c);let y=z.getScale(n,Fn),p=o.x/y.x,O=o.y/y.y;return c[0]=n[0]*p,c[1]=n[1]*p,c[2]=n[2]*O,c[3]=n[3]*O,c};var vn=new J;z.setUniformScale=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.number("scale",o),f.typeOf.object("result",c);let y=z.getScale(n,vn),p=o/y.x,O=o/y.y;return c[0]=n[0]*p,c[1]=n[1]*p,c[2]=n[2]*O,c[3]=n[3]*O,c};var Nn=new J;z.getScale=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),o.x=J.magnitude(J.fromElements(n[0],n[1],Nn)),o.y=J.magnitude(J.fromElements(n[2],n[3],Nn)),o};var Pn=new J;z.getMaximumScale=function(n){return z.getScale(n,Pn),J.maximumComponent(Pn)};var gn=new J;z.setRotation=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("result",c);let y=z.getScale(n,gn);return c[0]=o[0]*y.x,c[1]=o[1]*y.x,c[2]=o[2]*y.y,c[3]=o[3]*y.y,c};var un=new J;z.getRotation=function(n,o){f.typeOf.object("matrix",n),f.typeOf.object("result",o);let c=z.getScale(n,un);return o[0]=n[0]/c.x,o[1]=n[1]/c.x,o[2]=n[2]/c.y,o[3]=n[3]/c.y,o};z.multiply=function(n,o,c){f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c);let y=n[0]*o[0]+n[2]*o[1],p=n[0]*o[2]+n[2]*o[3],O=n[1]*o[0]+n[3]*o[1],e=n[1]*o[2]+n[3]*o[3];return c[0]=y,c[1]=O,c[2]=p,c[3]=e,c};z.add=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c[0]=n[0]+o[0],c[1]=n[1]+o[1],c[2]=n[2]+o[2],c[3]=n[3]+o[3],c};z.subtract=function(n,o,c){return f.typeOf.object("left",n),f.typeOf.object("right",o),f.typeOf.object("result",c),c[0]=n[0]-o[0],c[1]=n[1]-o[1],c[2]=n[2]-o[2],c[3]=n[3]-o[3],c};z.multiplyByVector=function(n,o,c){f.typeOf.object("matrix",n),f.typeOf.object("cartesian",o),f.typeOf.object("result",c);let y=n[0]*o.x+n[2]*o.y,p=n[1]*o.x+n[3]*o.y;return c.x=y,c.y=p,c};z.multiplyByScalar=function(n,o,c){return f.typeOf.object("matrix",n),f.typeOf.number("scalar",o),f.typeOf.object("result",c),c[0]=n[0]*o,c[1]=n[1]*o,c[2]=n[2]*o,c[3]=n[3]*o,c};z.multiplyByScale=function(n,o,c){return f.typeOf.object("matrix",n),f.typeOf.object("scale",o),f.typeOf.object("result",c),c[0]=n[0]*o.x,c[1]=n[1]*o.x,c[2]=n[2]*o.y,c[3]=n[3]*o.y,c};z.multiplyByUniformScale=function(n,o,c){return f.typeOf.object("matrix",n),f.typeOf.number("scale",o),f.typeOf.object("result",c),c[0]=n[0]*o,c[1]=n[1]*o,c[2]=n[2]*o,c[3]=n[3]*o,c};z.negate=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),o[0]=-n[0],o[1]=-n[1],o[2]=-n[2],o[3]=-n[3],o};z.transpose=function(n,o){f.typeOf.object("matrix",n),f.typeOf.object("result",o);let c=n[0],y=n[2],p=n[1],O=n[3];return o[0]=c,o[1]=y,o[2]=p,o[3]=O,o};z.abs=function(n,o){return f.typeOf.object("matrix",n),f.typeOf.object("result",o),o[0]=Math.abs(n[0]),o[1]=Math.abs(n[1]),o[2]=Math.abs(n[2]),o[3]=Math.abs(n[3]),o};z.equals=function(n,o){return n===o||M(n)&&M(o)&&n[0]===o[0]&&n[1]===o[1]&&n[2]===o[2]&&n[3]===o[3]};z.equalsArray=function(n,o,c){return n[0]===o[c]&&n[1]===o[c+1]&&n[2]===o[c+2]&&n[3]===o[c+3]};z.equalsEpsilon=function(n,o,c){return c=T(c,0),n===o||M(n)&&M(o)&&Math.abs(n[0]-o[0])<=c&&Math.abs(n[1]-o[1])<=c&&Math.abs(n[2]-o[2])<=c&&Math.abs(n[3]-o[3])<=c};z.IDENTITY=Object.freeze(new z(1,0,0,1));z.ZERO=Object.freeze(new z(0,0,0,0));z.COLUMN0ROW0=0;z.COLUMN0ROW1=1;z.COLUMN1ROW0=2;z.COLUMN1ROW1=3;Object.defineProperties(z.prototype,{length:{get:function(){return z.packedLength}}});z.prototype.clone=function(n){return z.clone(this,n)};z.prototype.equals=function(n){return z.equals(this,n)};z.prototype.equalsEpsilon=function(n,o){return z.equalsEpsilon(this,n,o)};z.prototype.toString=function(){return`(${this[0]}, ${this[2]})
  29. (${this[1]}, ${this[3]})`};var Vo=z;export{pn as a,ho as b,mo as c,J as d,Vo as e};