数字孪生Web 后台dt( digital twin)2.0版本 统一命名格式
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
8.2 KiB

10 months ago
define(["./when-cbf8cd21","./Check-35e1a91d","./Math-6a1814d8","./Cartesian2-c451a606","./Transforms-e4be2a30","./RuntimeError-f4c64df1","./WebGLConstants-95ceb4e9","./ComponentDatatype-7ee14e67","./AttributeCompression-bb3dc748","./IndexDatatype-354a5ea3","./IntersectionTests-8371bf29","./Plane-929e0674","./createTaskProcessorWorker","./EllipsoidTangentPlane-af8ae194","./OrientedBoundingBox-b779e812","./TerrainEncoding-0f15d8e5"],function(w,e,ce,ge,me,t,i,n,s,xe,r,h,u,o,ve,we){"use strict";var Ce={clipTriangleAtAxisAlignedThreshold:function(e,t,i,n,s,r){var h,u,o;w.defined(r)?r.length=0:r=[],o=t?(h=i<e,u=n<e,s<e):(h=e<i,u=e<n,e<s);var a,p,d,f,l,c,g=h+u+o;return 1===g?h?(a=(e-i)/(n-i),p=(e-i)/(s-i),r.push(1),r.push(2),1!==p&&(r.push(-1),r.push(0),r.push(2),r.push(p)),1!==a&&(r.push(-1),r.push(0),r.push(1),r.push(a))):u?(d=(e-n)/(s-n),f=(e-n)/(i-n),r.push(2),r.push(0),1!==f&&(r.push(-1),r.push(1),r.push(0),r.push(f)),1!==d&&(r.push(-1),r.push(1),r.push(2),r.push(d))):o&&(l=(e-s)/(i-s),c=(e-s)/(n-s),r.push(0),r.push(1),1!==c&&(r.push(-1),r.push(2),r.push(1),r.push(c)),1!==l&&(r.push(-1),r.push(2),r.push(0),r.push(l))):2===g?h||i===e?u||n===e?o||s===e||(p=(e-i)/(s-i),d=(e-n)/(s-n),r.push(2),r.push(-1),r.push(0),r.push(2),r.push(p),r.push(-1),r.push(1),r.push(2),r.push(d)):(c=(e-s)/(n-s),a=(e-i)/(n-i),r.push(1),r.push(-1),r.push(2),r.push(1),r.push(c),r.push(-1),r.push(0),r.push(1),r.push(a)):(f=(e-n)/(i-n),l=(e-s)/(i-s),r.push(0),r.push(-1),r.push(1),r.push(0),r.push(f),r.push(-1),r.push(2),r.push(0),r.push(l)):3!==g&&(r.push(0),r.push(1),r.push(2)),r},computeBarycentricCoordinates:function(e,t,i,n,s,r,h,u,o){var a=i-h,p=h-s,d=r-u,f=n-u,l=1/(d*a+p*f),c=t-u,g=e-h,m=(d*g+p*c)*l,x=(-f*g+a*c)*l,v=1-m-x;return w.defined(o)?(o.x=m,o.y=x,o.z=v,o):new ge.Cartesian3(m,x,v)},computeLineSegmentLineSegmentIntersection:function(e,t,i,n,s,r,h,u,o){var a=(u-r)*(i-e)-(h-s)*(n-t);if(0!=a){var p=((h-s)*(t-r)-(u-r)*(e-s))/a,d=((i-e)*(t-r)-(n-t)*(e-s))/a;return 0<=p&&p<=1&&0<=d&&d<=1?(w.defined(o)||(o=new ge.Cartesian2),o.x=e+p*(i-e),o.y=t+p*(n-t),o):void 0}}},ye=32767,Be=16383,Ie=[],Ae=[],be=[],Te=new ge.Cartographic,ze=new ge.Cartesian3,Me=[],Ne=[],Ve=[],Ee=[],Re=[],He=new ge.Cartesian3,Oe=new me.BoundingSphere,Se=new ve.OrientedBoundingBox,Ue=new ge.Cartesian2,Fe=new ge.Cartesian3;function Pe(){this.vertexBuffer=void 0,this.index=void 0,this.first=void 0,this.second=void 0,this.ratio=void 0}Pe.prototype.clone=function(e){return w.defined(e)||(e=new Pe),e.uBuffer=this.uBuffer,e.vBuffer=this.vBuffer,e.heightBuffer=this.heightBuffer,e.normalBuffer=this.normalBuffer,e.index=this.index,e.first=this.first,e.second=this.second,e.ratio=this.ratio,e},Pe.prototype.initializeIndexed=function(e,t,i,n,s){this.uBuffer=e,this.vBuffer=t,this.heightBuffer=i,this.normalBuffer=n,this.index=s,this.first=void 0,this.second=void 0,this.ratio=void 0},Pe.prototype.initializeFromClipResult=function(e,t,i){var n=t+1;return-1!==e[t]?i[e[t]].clone(this):(this.vertexBuffer=void 0,this.index=void 0,this.first=i[e[n]],++n,this.second=i[e[n]],++n,this.ratio=e[n],++n),n},Pe.prototype.getKey=function(){return this.isIndexed()?this.index:JSON.stringify({first:this.first.getKey(),second:this.second.getKey(),ratio:this.ratio})},Pe.prototype.isIndexed=function(){return w.defined(this.index)},Pe.prototype.getH=function(){return w.defined(this.index)?this.heightBuffer[this.index]:ce.CesiumMath.lerp(this.first.getH(),this.second.getH(),this.ratio)},Pe.prototype.getU=function(){return w.defined(this.index)?this.uBuffer[this.index]:ce.CesiumMath.lerp(this.first.getU(),this.second.getU(),this.ratio)},Pe.prototype.getV=function(){return w.defined(this.index)?this.vBuffer[this.index]:ce.CesiumMath.lerp(this.first.getV(),this.second.getV(),this.ratio)};var a=new ge.Cartesian2,p=-1,d=[new ge.Cartesian3,new ge.Cartesian3],f=[new ge.Cartesian3,new ge.Cartesian3];function l(e,t){var i=d[++p],n=f[p];return i=s.AttributeCompression.octDecode(e.first.getNormalX(),e.first.getNormalY(),i),n=s.AttributeCompression.octDecode(e.second.getNormalX(),e.second.getNormalY(),n),ze=ge.Cartesian3.lerp(i,n