define(["./defaultValue-0a909f67","./Matrix3-b6f074fa","./ArcType-ce2e50ab","./BoundingRectangle-47fd0937","./Transforms-713aa3a8","./Matrix2-163b5a1d","./ComponentDatatype-77274976","./EllipsoidGeodesic-b00a0416","./EllipsoidTangentPlane-8eee3c2f","./GeometryAttribute-0b8b7b82","./GeometryInstance-9b27c40d","./GeometryOffsetAttribute-04332ce7","./GeometryPipeline-b6eb7525","./IndexDatatype-2149f06c","./Math-e97915da","./PolygonGeometryLibrary-af483c87","./PolygonPipeline-1b86ab0c","./VertexFormat-ab2e00e6","./combine-ca22a614","./RuntimeError-06c93819","./WebGLConstants-a8cc3e8c","./AxisAlignedBoundingBox-c7183545","./IntersectionTests-87baf287","./Plane-1c5a21a3","./AttributeCompression-e18a879a","./EncodedCartesian3-de837603","./arrayRemoveDuplicates-e9673044","./EllipsoidRhumbLine-7f84cca0","./GeometryAttributes-f06a2792"],(function(e,t,o,i,r,n,a,s,l,c,u,p,y,d,m,g,h,f,b,_,P,C,x,w,T,I,A,v,E){"use strict";const G=new t.Cartographic,O=new t.Cartographic;function L(e,t,o,i){const r=i.cartesianToCartographic(e,G).height,n=i.cartesianToCartographic(t,O);n.height=r,i.cartographicToCartesian(n,t);const a=i.cartesianToCartographic(o,O);a.height=r-100,i.cartographicToCartesian(a,o)}const V=new i.BoundingRectangle,H=new t.Cartesian3,D=new t.Cartesian3,N=new t.Cartesian3,F=new t.Cartesian3,R=new t.Cartesian3,M=new t.Cartesian3;let S=new t.Cartesian3,B=new t.Cartesian3,k=new t.Cartesian3;const z=new n.Cartesian2,W=new n.Cartesian2,Y=new t.Cartesian3,U=new r.Quaternion,j=new t.Matrix3,Q=new t.Matrix3;function q(o){const i=o.vertexFormat,s=o.geometry,l=o.shadowVolume,u=s.attributes.position.values,y=e.defined(s.attributes.st)?s.attributes.st.values:void 0;let d=u.length;const g=o.wall,h=o.top||g,f=o.bottom||g;if(i.st||i.normal||i.tangent||i.bitangent||l){const p=o.boundingRectangle,b=o.tangentPlane,_=o.ellipsoid,P=o.stRotation,C=o.perPositionHeight,x=z;x.x=p.x,x.y=p.y;const w=i.st?new Float32Array(d/3*2):void 0;let T;i.normal&&(T=C&&h&&!g?s.attributes.normal.values:new Float32Array(d));const I=i.tangent?new Float32Array(d):void 0,A=i.bitangent?new Float32Array(d):void 0,v=l?new Float32Array(d):void 0;let E=0,G=0,O=D,V=N,q=F,K=!0,Z=j,J=Q;if(0!==P){let e=r.Quaternion.fromAxisAngle(b._plane.normal,P,U);Z=t.Matrix3.fromQuaternion(e,Z),e=r.Quaternion.fromAxisAngle(b._plane.normal,-P,U),J=t.Matrix3.fromQuaternion(e,J)}else Z=t.Matrix3.clone(t.Matrix3.IDENTITY,Z),J=t.Matrix3.clone(t.Matrix3.IDENTITY,J);let X=0,$=0;h&&f&&(X=d/2,$=d/3,d/=2);for(let r=0;rJ.eastOverIDL-J.westOverIDL&&(l.west=J.westOverIDL,l.east=J.eastOverIDL,l.east>m.CesiumMath.PI&&(l.east=l.east-m.CesiumMath.TWO_PI),l.west>m.CesiumMath.PI&&(l.west=l.west-m.CesiumMath.TWO_PI)),l}const ee=new t.Cartographic;function te(e,t,o,i){const r=e.surfaceDistance,n=Math.ceil(r*t),a=n>0?r/(n-1):Number.POSITIVE_INFINITY;let s=0;for(let t=0;t=0?r:r+m.CesiumMath.TWO_PI;i.westOverIDL=Math.min(i.westOverIDL,l),i.eastOverIDL=Math.max(i.eastOverIDL,l)}}const oe=[];function ie(t,o,i,r,n,a,s,c,p,y){const m={walls:[]};let f;if(s||c){const n=g.PolygonGeometryLibrary.createGeometryFromPositions(t,o,i,r,a,p,y),l=n.attributes.position.values,h=n.indices;let b,_;if(s&&c){const t=l.concat(l);b=t.length/3,_=d.IndexDatatype.createTypedArray(b,2*h.length),_.set(h);const o=h.length,r=b/2;for(f=0;f