define(["exports","./Transforms-99272364","./ComponentDatatype-aaeec80f","./defaultValue-81eec7ed","./Check-741c5f3c","./Matrix2-e3fb4559","./GeometryAttribute-088ad91d","./GeometryAttributes-32b29525","./GeometryPipeline-1165e4c4","./IndexDatatype-f1e3f799","./Matrix4-d34187af","./WebMercatorProjection-f5706bbf","./Cartesian3-7e9cc2ff"],(function(e,t,n,r,o,i,s,a,d,c,p,f,u){"use strict";function m(e,t,n){e=r.defaultValue(e,0),t=r.defaultValue(t,0),n=r.defaultValue(n,0),this.value=new Float32Array([e,t,n])}function l(e,t,n){let o=!n;const i=e.length;let s;if(!o&&i>1){const t=e[0].modelMatrix;for(s=1;s=0){const e=o[d];i=e.offset+e.count,a=e.index,s=n[a].indices.length}else i=0,a=0,s=n[a].indices.length;const c=e.length;for(let d=0;ds&&(i=0,s=n[++a].indices.length),o.push({index:a,offset:i,count:p}),i+=p}}function b(e,t){const n=[];return y(e,"geometry",t,n),y(e,"westHemisphereGeometry",t,n),y(e,"eastHemisphereGeometry",t,n),n}Object.defineProperties(m.prototype,{componentDatatype:{get:function(){return n.ComponentDatatype.FLOAT}},componentsPerAttribute:{get:function(){return 3}},normalize:{get:function(){return!1}}}),m.fromCartesian3=function(e){return new m(e.x,e.y,e.z)},m.toValue=function(e,t){return r.defined(t)||(t=new Float32Array([e.x,e.y,e.z])),t[0]=e.x,t[1]=e.y,t[2]=e.z,t};const x={};function P(e,t){const n=e.attributes;for(const e in n)if(n.hasOwnProperty(e)){const o=n[e];r.defined(o)&&r.defined(o.values)&&t.push(o.values.buffer)}r.defined(e.indices)&&t.push(e.indices.buffer)}function G(e,t){const n=e.length,o=new Float64Array(1+19*n);let i=0;o[i++]=n;for(let t=0;t0&&(o=function(e){const o=e.instances,i=e.projection,s=e.elementIndexUintSupported,a=e.scene3DOnly,c=e.vertexCacheOptimize,p=e.compressVertices,f=e.modelMatrix;var u=e.isfromGLP;let m,h,y=o.length;for(m=0;m0&&(i=d.GeometryPipeline.createAttributeLocations(o[0]),e.createPickOffsets&&(c=b(s,o))),r.defined(s[0].attributes)&&r.defined(s[0].attributes.offset)&&(p=new Array(a),f=!0));const u=new Array(a),m=new Array(a);var h=new Array(a);for(let e=0;e0&&(n=function(e){var t=e.instances;e.projection,e.elementIndexUintSupported;var n=e.scene3DOnly,o=e.vertexCacheOptimize;e.compressVertices;var i,s=e.modelMatrix,a=t.length;for(i=0;i0&&(o=d.GeometryPipeline.createAttributeLocations(n[0]),e.createPickOffsets&&(i=b(a,n))),r.defined(a[0].attributes)&&r.defined(a[0].attributes.offset)&&(s=new Array(c),p=!0));for(var f=new Array(c),u=new Array(c),m=new Array(c),h=0;h0&&(o.set(a.indices,d),d+=l)}return n.push(o.buffer),{stringTable:i,packedData:o}},x.unpackCreateGeometryResults=function(e){const r=e.stringTable,o=e.packedData;let i;const d=new Array(o[0]);let p=0,f=1;for(;f0){const e=G.length/S;for(k=c.IndexDatatype.createTypedArray(e,P),i=0;i