@cesium/engine 4.0.0 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Build/Workers/{chunk-LGSGX2RH.js → chunk-2U6EBIRX.js} +10 -10
- package/Build/Workers/{chunk-FVDTKX3F.js → chunk-2ZI7FZ3Q.js} +2 -2
- package/Build/Workers/{chunk-DJUTBX6A.js → chunk-3TSHZWOZ.js} +2 -2
- package/Build/Workers/{chunk-FYHCAKU6.js → chunk-44B6FQSJ.js} +11 -11
- package/Build/Workers/{chunk-4VWUFKYW.js → chunk-4AJR66C5.js} +12 -12
- package/Build/Workers/{chunk-PWDYKCNC.js → chunk-4HN3N5SE.js} +4 -4
- package/Build/Workers/{chunk-I5MQWHBR.js → chunk-4QGPYV3W.js} +4 -4
- package/Build/Workers/{chunk-C6MRR5YL.js → chunk-4RKE4B3G.js} +7 -7
- package/Build/Workers/{chunk-P4M4QUNQ.js → chunk-5E3V7Y4R.js} +6 -6
- package/Build/Workers/{chunk-UN7AK64D.js → chunk-6EHT6GS3.js} +2 -2
- package/Build/Workers/{chunk-PGB3EFR7.js → chunk-6I22NWKQ.js} +6 -6
- package/Build/Workers/{chunk-7IMAWM6A.js → chunk-7N67FBLW.js} +229 -17
- package/Build/Workers/{chunk-LQRFWCNX.js → chunk-AQQGAFKX.js} +5 -5
- package/Build/Workers/{chunk-TF5D2H7B.js → chunk-CROU4RHL.js} +5 -5
- package/Build/Workers/{chunk-KAFF2QX3.js → chunk-CTJCECTX.js} +5 -5
- package/Build/Workers/{chunk-FKHRSGKP.js → chunk-DWJZFZ67.js} +13 -13
- package/Build/Workers/{chunk-V2LKNJGT.js → chunk-EHJQEARC.js} +5 -5
- package/Build/Workers/{chunk-VSCXSFHE.js → chunk-EVLKHUAE.js} +13 -13
- package/Build/Workers/{chunk-YLAFWVOW.js → chunk-FOOYJER7.js} +10 -10
- package/Build/Workers/{chunk-F7P2HCYZ.js → chunk-GLCRFDOB.js} +2 -2
- package/Build/Workers/{chunk-BT6YIL2N.js → chunk-GPO47TW4.js} +1 -1
- package/Build/Workers/{chunk-AXGQUPXA.js → chunk-H5Q2JKIA.js} +17 -17
- package/Build/Workers/{chunk-XJCTFTBM.js → chunk-HIDSEUWS.js} +5 -5
- package/Build/Workers/{chunk-UGZGTV5K.js → chunk-HV67ARO7.js} +8 -8
- package/Build/Workers/{chunk-H52L6U76.js → chunk-IC7G4BX2.js} +11 -11
- package/Build/Workers/{chunk-2C65EKYA.js → chunk-IQN2LMGD.js} +1 -1
- package/Build/Workers/chunk-J2FHYK2Z.js +55 -0
- package/Build/Workers/{chunk-4V6RCTVH.js → chunk-K3VEWONC.js} +10 -10
- package/Build/Workers/{chunk-RDCDRNJ7.js → chunk-KZFXE35V.js} +6 -6
- package/Build/Workers/{chunk-SGRWJKNO.js → chunk-MG2TXIO5.js} +15 -15
- package/Build/Workers/{chunk-2NLMZNJI.js → chunk-MRCFDEKH.js} +4 -4
- package/Build/Workers/{chunk-PW5CA4MJ.js → chunk-MYDS6HBL.js} +7 -7
- package/Build/Workers/{chunk-H6MBQ4W4.js → chunk-OCIX2CQ7.js} +4 -4
- package/Build/Workers/{chunk-HCZR75II.js → chunk-P32XMW4I.js} +15 -15
- package/Build/Workers/{chunk-G3MOT7BZ.js → chunk-PEVZYZBQ.js} +6 -6
- package/Build/Workers/{chunk-EQ6ZAP37.js → chunk-PMDLIBEQ.js} +7 -7
- package/Build/Workers/{chunk-RDM3BKNC.js → chunk-QDUOGCCO.js} +11 -11
- package/Build/Workers/{chunk-P7PWX5HR.js → chunk-QUCJGBCK.js} +7 -7
- package/Build/Workers/{chunk-RRUPTJ6P.js → chunk-RCI7BSOM.js} +6 -6
- package/Build/Workers/{chunk-NRETMGYL.js → chunk-SVTSC7FX.js} +13 -13
- package/Build/Workers/{chunk-QVJ6IRKV.js → chunk-TXOGSFHZ.js} +1 -1
- package/Build/Workers/{chunk-527JG4D7.js → chunk-TXYJOVQK.js} +1 -1
- package/Build/Workers/{chunk-QIS3NB7U.js → chunk-UFIT5XDI.js} +7 -7
- package/Build/Workers/{chunk-FE2XG3SS.js → chunk-ULLMQNFQ.js} +3 -3
- package/Build/Workers/{chunk-U5LKG6LX.js → chunk-UM7FIUQW.js} +2 -2
- package/Build/Workers/{chunk-A6EA6KIE.js → chunk-UMLTOPAE.js} +1 -1
- package/Build/Workers/{chunk-5U4UHRZ2.js → chunk-V5S5N2IS.js} +10 -10
- package/Build/Workers/{chunk-TVYIHH4V.js → chunk-VN2IHJKM.js} +14 -14
- package/Build/Workers/{chunk-YMJPANZZ.js → chunk-VWSD2XV5.js} +10 -34
- package/Build/Workers/{chunk-XZVQMPWG.js → chunk-X2KIWBTW.js} +5 -5
- package/Build/Workers/{chunk-7CZEWQWE.js → chunk-Y24CDOJC.js} +6 -6
- package/Build/Workers/{chunk-N5MMDSD2.js → chunk-YLMDWSXO.js} +2 -2
- package/Build/Workers/{chunk-27R2KRIK.js → chunk-YNZ4DMR7.js} +6 -6
- package/Build/Workers/{chunk-YLS3FX3U.js → chunk-Z2MP3UBE.js} +7 -7
- package/Build/Workers/combineGeometry.js +23 -23
- package/Build/Workers/createBoxGeometry.js +17 -17
- package/Build/Workers/createBoxOutlineGeometry.js +15 -15
- package/Build/Workers/createCircleGeometry.js +25 -25
- package/Build/Workers/createCircleOutlineGeometry.js +18 -18
- package/Build/Workers/createCoplanarPolygonGeometry.js +32 -32
- package/Build/Workers/createCoplanarPolygonOutlineGeometry.js +30 -30
- package/Build/Workers/createCorridorGeometry.js +29 -28
- package/Build/Workers/createCorridorOutlineGeometry.js +28 -27
- package/Build/Workers/createCylinderGeometry.js +19 -19
- package/Build/Workers/createCylinderOutlineGeometry.js +17 -17
- package/Build/Workers/createEllipseGeometry.js +25 -25
- package/Build/Workers/createEllipseOutlineGeometry.js +18 -18
- package/Build/Workers/createEllipsoidGeometry.js +18 -18
- package/Build/Workers/createEllipsoidOutlineGeometry.js +17 -17
- package/Build/Workers/createFrustumGeometry.js +17 -17
- package/Build/Workers/createFrustumOutlineGeometry.js +17 -17
- package/Build/Workers/createGeometry.js +23 -23
- package/Build/Workers/createGroundPolylineGeometry.js +21 -21
- package/Build/Workers/createPlaneGeometry.js +15 -15
- package/Build/Workers/createPlaneOutlineGeometry.js +14 -14
- package/Build/Workers/createPolygonGeometry.js +469 -60
- package/Build/Workers/createPolygonOutlineGeometry.js +29 -29
- package/Build/Workers/createPolylineGeometry.js +24 -24
- package/Build/Workers/createPolylineVolumeGeometry.js +33 -31
- package/Build/Workers/createPolylineVolumeOutlineGeometry.js +27 -26
- package/Build/Workers/createRectangleGeometry.js +26 -26
- package/Build/Workers/createRectangleOutlineGeometry.js +19 -19
- package/Build/Workers/createSimplePolylineGeometry.js +22 -22
- package/Build/Workers/createSphereGeometry.js +18 -18
- package/Build/Workers/createSphereOutlineGeometry.js +17 -17
- package/Build/Workers/createTaskProcessorWorker.js +3 -3
- package/Build/Workers/createVectorTileClampedPolylines.js +14 -14
- package/Build/Workers/createVectorTileGeometries.js +23 -23
- package/Build/Workers/createVectorTilePoints.js +12 -12
- package/Build/Workers/createVectorTilePolygons.js +21 -21
- package/Build/Workers/createVectorTilePolylines.js +14 -14
- package/Build/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +21 -21
- package/Build/Workers/createVerticesFromHeightmap.js +21 -21
- package/Build/Workers/createVerticesFromQuantizedTerrainMesh.js +18 -18
- package/Build/Workers/createWallGeometry.js +23 -23
- package/Build/Workers/createWallOutlineGeometry.js +22 -22
- package/Build/Workers/decodeDraco.js +11 -11
- package/Build/Workers/decodeGoogleEarthEnterprisePacket.js +5 -5
- package/Build/Workers/decodeI3S.js +9 -9
- package/Build/Workers/transcodeKTX2.js +7 -7
- package/Build/Workers/transferTypedArrayTest.js +1 -1
- package/Build/Workers/upsampleQuantizedTerrainMesh.js +21 -21
- package/Source/Core/Credit.js +7 -1
- package/Source/Core/GoogleMaps.js +1 -2
- package/Source/Core/Ion.js +1 -2
- package/Source/Core/PolygonGeometry.js +340 -27
- package/Source/Core/PolygonGeometryLibrary.js +302 -1
- package/Source/Core/Stereographic.js +247 -0
- package/Source/Core/TaskProcessor.js +53 -40
- package/Source/Core/buildModuleUrl.js +1 -1
- package/Source/Core/sampleTerrain.js +43 -10
- package/Source/Core/sampleTerrainMostDetailed.js +27 -3
- package/Source/Scene/ArcGisMapService.js +1 -2
- package/Source/Scene/Billboard.js +7 -0
- package/Source/Scene/Cesium3DTilePass.js +1 -1
- package/Source/Scene/Cesium3DTileset.js +38 -81
- package/Source/Scene/CreditDisplay.js +2 -2
- package/Source/Scene/LabelCollection.js +3 -1
- package/Source/Scene/Model/Model.js +16 -22
- package/Source/Scene/PostProcessStageLibrary.js +3 -3
- package/Source/Scene/PrimitiveCollection.js +39 -0
- package/Source/Scene/Scene.js +3 -0
- package/Source/Widget/CesiumWidget.js +2 -1
- package/index.d.ts +53 -28
- package/index.js +108 -107
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,55 +25,68 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
ArcType_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-IQN2LMGD.js";
|
|
29
29
|
import {
|
|
30
30
|
GeometryPipeline_default
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-P32XMW4I.js";
|
|
32
32
|
import {
|
|
33
33
|
PolygonPipeline_default,
|
|
34
34
|
WindingOrder_default
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-QDUOGCCO.js";
|
|
36
36
|
import {
|
|
37
37
|
arrayRemoveDuplicates_default
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-X2KIWBTW.js";
|
|
39
39
|
import {
|
|
40
40
|
EllipsoidRhumbLine_default
|
|
41
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-RCI7BSOM.js";
|
|
42
|
+
import {
|
|
43
|
+
IntersectionTests_default
|
|
44
|
+
} from "./chunk-UFIT5XDI.js";
|
|
45
|
+
import {
|
|
46
|
+
Plane_default
|
|
47
|
+
} from "./chunk-6I22NWKQ.js";
|
|
42
48
|
import {
|
|
43
49
|
IndexDatatype_default
|
|
44
|
-
} from "./chunk-
|
|
50
|
+
} from "./chunk-CROU4RHL.js";
|
|
45
51
|
import {
|
|
46
52
|
GeometryAttributes_default
|
|
47
|
-
} from "./chunk-
|
|
53
|
+
} from "./chunk-YLMDWSXO.js";
|
|
48
54
|
import {
|
|
49
55
|
GeometryAttribute_default,
|
|
50
56
|
Geometry_default,
|
|
51
57
|
PrimitiveType_default
|
|
52
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-HV67ARO7.js";
|
|
53
59
|
import {
|
|
54
60
|
Quaternion_default
|
|
55
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-V5S5N2IS.js";
|
|
56
62
|
import {
|
|
57
63
|
Cartesian2_default
|
|
58
|
-
} from "./chunk-
|
|
64
|
+
} from "./chunk-MYDS6HBL.js";
|
|
59
65
|
import {
|
|
60
66
|
ComponentDatatype_default
|
|
61
|
-
} from "./chunk-
|
|
67
|
+
} from "./chunk-CTJCECTX.js";
|
|
62
68
|
import {
|
|
63
69
|
Cartesian3_default,
|
|
64
70
|
Cartographic_default,
|
|
65
71
|
Ellipsoid_default,
|
|
66
72
|
Matrix3_default
|
|
67
|
-
} from "./chunk-
|
|
73
|
+
} from "./chunk-HIDSEUWS.js";
|
|
68
74
|
import {
|
|
69
75
|
Math_default
|
|
70
|
-
} from "./chunk-
|
|
76
|
+
} from "./chunk-4HN3N5SE.js";
|
|
71
77
|
import {
|
|
72
78
|
defaultValue_default
|
|
73
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-GPO47TW4.js";
|
|
74
80
|
import {
|
|
75
81
|
defined_default
|
|
76
|
-
} from "./chunk-
|
|
82
|
+
} from "./chunk-TXOGSFHZ.js";
|
|
83
|
+
|
|
84
|
+
// packages/engine/Source/Core/PolygonHierarchy.js
|
|
85
|
+
function PolygonHierarchy(positions, holes) {
|
|
86
|
+
this.positions = defined_default(positions) ? positions : [];
|
|
87
|
+
this.holes = defined_default(holes) ? holes : [];
|
|
88
|
+
}
|
|
89
|
+
var PolygonHierarchy_default = PolygonHierarchy;
|
|
77
90
|
|
|
78
91
|
// packages/engine/Source/Core/Queue.js
|
|
79
92
|
function Queue() {
|
|
@@ -427,11 +440,199 @@ PolygonGeometryLibrary.polygonOutlinesFromHierarchy = function(polygonHierarchy,
|
|
|
427
440
|
}
|
|
428
441
|
return polygons;
|
|
429
442
|
};
|
|
430
|
-
|
|
443
|
+
var scratchRhumbIntersection = new Cartographic_default();
|
|
444
|
+
function computeEquatorIntersectionRhumb(start, end, ellipsoid) {
|
|
445
|
+
const c0 = ellipsoid.cartesianToCartographic(start, scratchCartographic0);
|
|
446
|
+
const c1 = ellipsoid.cartesianToCartographic(end, scratchCartographic1);
|
|
447
|
+
if (Math.sign(c0.latitude) === Math.sign(c1.latitude)) {
|
|
448
|
+
return;
|
|
449
|
+
}
|
|
450
|
+
scratchRhumbLine.setEndPoints(c0, c1);
|
|
451
|
+
const intersection = scratchRhumbLine.findIntersectionWithLatitude(
|
|
452
|
+
0,
|
|
453
|
+
scratchRhumbIntersection
|
|
454
|
+
);
|
|
455
|
+
if (!defined_default(intersection)) {
|
|
456
|
+
return;
|
|
457
|
+
}
|
|
458
|
+
let minLongitude = Math.min(c0.longitude, c1.longitude);
|
|
459
|
+
let maxLongitude = Math.max(c0.longitude, c1.longitude);
|
|
460
|
+
if (Math.abs(maxLongitude - minLongitude) > Math_default.PI) {
|
|
461
|
+
const swap = minLongitude;
|
|
462
|
+
minLongitude = maxLongitude;
|
|
463
|
+
maxLongitude = swap;
|
|
464
|
+
}
|
|
465
|
+
if (intersection.longitude < minLongitude || intersection.longitude > maxLongitude) {
|
|
466
|
+
return;
|
|
467
|
+
}
|
|
468
|
+
return ellipsoid.cartographicToCartesian(intersection);
|
|
469
|
+
}
|
|
470
|
+
function computeEquatorIntersection(start, end, ellipsoid, arcType) {
|
|
471
|
+
if (arcType === ArcType_default.RHUMB) {
|
|
472
|
+
return computeEquatorIntersectionRhumb(start, end, ellipsoid);
|
|
473
|
+
}
|
|
474
|
+
const intersection = IntersectionTests_default.lineSegmentPlane(
|
|
475
|
+
start,
|
|
476
|
+
end,
|
|
477
|
+
Plane_default.ORIGIN_XY_PLANE
|
|
478
|
+
);
|
|
479
|
+
if (!defined_default(intersection)) {
|
|
480
|
+
return;
|
|
481
|
+
}
|
|
482
|
+
return ellipsoid.scaleToGeodeticSurface(intersection, intersection);
|
|
483
|
+
}
|
|
484
|
+
var scratchCartographic = new Cartographic_default();
|
|
485
|
+
function computeEdgesOnPlane(positions, ellipsoid, arcType) {
|
|
486
|
+
const edgesOnPlane = [];
|
|
487
|
+
let startPoint, endPoint, type, next, intersection, i = 0;
|
|
488
|
+
while (i < positions.length) {
|
|
489
|
+
startPoint = positions[i];
|
|
490
|
+
endPoint = positions[(i + 1) % positions.length];
|
|
491
|
+
type = Math_default.sign(startPoint.z);
|
|
492
|
+
next = Math_default.sign(endPoint.z);
|
|
493
|
+
const getLongitude = (position) => {
|
|
494
|
+
const cartographic = ellipsoid.cartesianToCartographic(
|
|
495
|
+
position,
|
|
496
|
+
scratchCartographic
|
|
497
|
+
);
|
|
498
|
+
return cartographic.longitude;
|
|
499
|
+
};
|
|
500
|
+
if (type === 0) {
|
|
501
|
+
edgesOnPlane.push({
|
|
502
|
+
position: i,
|
|
503
|
+
type,
|
|
504
|
+
visited: false,
|
|
505
|
+
next,
|
|
506
|
+
theta: getLongitude(startPoint)
|
|
507
|
+
});
|
|
508
|
+
} else if (next !== 0) {
|
|
509
|
+
intersection = computeEquatorIntersection(
|
|
510
|
+
startPoint,
|
|
511
|
+
endPoint,
|
|
512
|
+
ellipsoid,
|
|
513
|
+
arcType
|
|
514
|
+
);
|
|
515
|
+
++i;
|
|
516
|
+
if (!defined_default(intersection)) {
|
|
517
|
+
continue;
|
|
518
|
+
}
|
|
519
|
+
positions.splice(i, 0, intersection);
|
|
520
|
+
edgesOnPlane.push({
|
|
521
|
+
position: i,
|
|
522
|
+
type,
|
|
523
|
+
visited: false,
|
|
524
|
+
next,
|
|
525
|
+
theta: getLongitude(intersection)
|
|
526
|
+
});
|
|
527
|
+
}
|
|
528
|
+
++i;
|
|
529
|
+
}
|
|
530
|
+
return edgesOnPlane;
|
|
531
|
+
}
|
|
532
|
+
function wirePolygon(polygons, polygonIndex, positions, edgesOnPlane, toDelete, startIndex, abovePlane) {
|
|
533
|
+
const polygon = [];
|
|
534
|
+
let i = startIndex;
|
|
535
|
+
const getMatchingEdge = (i2) => (edge) => edge.position === i2;
|
|
536
|
+
const polygonsToWire = [];
|
|
537
|
+
do {
|
|
538
|
+
const position = positions[i];
|
|
539
|
+
polygon.push(position);
|
|
540
|
+
const edgeIndex = edgesOnPlane.findIndex(getMatchingEdge(i));
|
|
541
|
+
const edge = edgesOnPlane[edgeIndex];
|
|
542
|
+
if (!defined_default(edge)) {
|
|
543
|
+
++i;
|
|
544
|
+
continue;
|
|
545
|
+
}
|
|
546
|
+
const { visited: hasBeenVisited, type, next } = edge;
|
|
547
|
+
edge.visited = true;
|
|
548
|
+
if (type === 0) {
|
|
549
|
+
if (next === 0) {
|
|
550
|
+
const previousEdge = edgesOnPlane[edgeIndex - (abovePlane ? 1 : -1)];
|
|
551
|
+
if (previousEdge?.position === i + 1) {
|
|
552
|
+
previousEdge.visited = true;
|
|
553
|
+
} else {
|
|
554
|
+
++i;
|
|
555
|
+
continue;
|
|
556
|
+
}
|
|
557
|
+
}
|
|
558
|
+
if (!hasBeenVisited && abovePlane && next > 0 || startIndex === i && !abovePlane && next < 0) {
|
|
559
|
+
++i;
|
|
560
|
+
continue;
|
|
561
|
+
}
|
|
562
|
+
}
|
|
563
|
+
const followEdge = abovePlane ? type >= 0 : type <= 0;
|
|
564
|
+
if (!followEdge) {
|
|
565
|
+
++i;
|
|
566
|
+
continue;
|
|
567
|
+
}
|
|
568
|
+
if (!hasBeenVisited) {
|
|
569
|
+
polygonsToWire.push(i);
|
|
570
|
+
}
|
|
571
|
+
const nextEdgeIndex = edgeIndex + (abovePlane ? 1 : -1);
|
|
572
|
+
const nextEdge = edgesOnPlane[nextEdgeIndex];
|
|
573
|
+
if (!defined_default(nextEdge)) {
|
|
574
|
+
++i;
|
|
575
|
+
continue;
|
|
576
|
+
}
|
|
577
|
+
i = nextEdge.position;
|
|
578
|
+
} while (i < positions.length && i >= 0 && i !== startIndex && polygon.length < positions.length);
|
|
579
|
+
polygons.splice(polygonIndex, toDelete, polygon);
|
|
580
|
+
for (const index of polygonsToWire) {
|
|
581
|
+
polygonIndex = wirePolygon(
|
|
582
|
+
polygons,
|
|
583
|
+
++polygonIndex,
|
|
584
|
+
positions,
|
|
585
|
+
edgesOnPlane,
|
|
586
|
+
0,
|
|
587
|
+
index,
|
|
588
|
+
!abovePlane
|
|
589
|
+
);
|
|
590
|
+
}
|
|
591
|
+
return polygonIndex;
|
|
592
|
+
}
|
|
593
|
+
PolygonGeometryLibrary.splitPolygonsOnEquator = function(outerRings, ellipsoid, arcType, result) {
|
|
594
|
+
if (!defined_default(result)) {
|
|
595
|
+
result = [];
|
|
596
|
+
}
|
|
597
|
+
result.splice(0, 0, ...outerRings);
|
|
598
|
+
result.length = outerRings.length;
|
|
599
|
+
let currentPolygon = 0;
|
|
600
|
+
while (currentPolygon < result.length) {
|
|
601
|
+
const outerRing = result[currentPolygon];
|
|
602
|
+
const positions = outerRing.slice();
|
|
603
|
+
if (outerRing.length < 3) {
|
|
604
|
+
result[currentPolygon] = positions;
|
|
605
|
+
++currentPolygon;
|
|
606
|
+
continue;
|
|
607
|
+
}
|
|
608
|
+
const edgesOnPlane = computeEdgesOnPlane(positions, ellipsoid, arcType);
|
|
609
|
+
if (positions.length === outerRing.length || edgesOnPlane.length <= 1) {
|
|
610
|
+
result[currentPolygon] = positions;
|
|
611
|
+
++currentPolygon;
|
|
612
|
+
continue;
|
|
613
|
+
}
|
|
614
|
+
edgesOnPlane.sort((a, b) => {
|
|
615
|
+
return a.theta - b.theta;
|
|
616
|
+
});
|
|
617
|
+
const north = positions[0].z >= 0;
|
|
618
|
+
currentPolygon = wirePolygon(
|
|
619
|
+
result,
|
|
620
|
+
currentPolygon,
|
|
621
|
+
positions,
|
|
622
|
+
edgesOnPlane,
|
|
623
|
+
1,
|
|
624
|
+
0,
|
|
625
|
+
north
|
|
626
|
+
);
|
|
627
|
+
}
|
|
628
|
+
return result;
|
|
629
|
+
};
|
|
630
|
+
PolygonGeometryLibrary.polygonsFromHierarchy = function(polygonHierarchy, keepDuplicates, projectPointsTo2D, scaleToEllipsoidSurface, ellipsoid, splitPolygons) {
|
|
431
631
|
const hierarchy = [];
|
|
432
632
|
const polygons = [];
|
|
433
633
|
const queue = new Queue_default();
|
|
434
634
|
queue.enqueue(polygonHierarchy);
|
|
635
|
+
let split = defined_default(splitPolygons);
|
|
435
636
|
while (queue.length !== 0) {
|
|
436
637
|
const outerNode = queue.dequeue();
|
|
437
638
|
let outerRing = outerNode.positions;
|
|
@@ -466,6 +667,17 @@ PolygonGeometryLibrary.polygonsFromHierarchy = function(polygonHierarchy, keepDu
|
|
|
466
667
|
positions2D.reverse();
|
|
467
668
|
outerRing = outerRing.slice().reverse();
|
|
468
669
|
}
|
|
670
|
+
if (split) {
|
|
671
|
+
split = false;
|
|
672
|
+
let polygons2 = [outerRing];
|
|
673
|
+
polygons2 = splitPolygons(polygons2, polygons2);
|
|
674
|
+
if (polygons2.length > 1) {
|
|
675
|
+
for (const positions2 of polygons2) {
|
|
676
|
+
queue.enqueue(new PolygonHierarchy_default(positions2, holes));
|
|
677
|
+
}
|
|
678
|
+
continue;
|
|
679
|
+
}
|
|
680
|
+
}
|
|
469
681
|
let positions = outerRing.slice();
|
|
470
682
|
const numChildren = defined_default(holes) ? holes.length : 0;
|
|
471
683
|
const polygonHoles = [];
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,17 +25,17 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
OrientedBoundingBox_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-FOOYJER7.js";
|
|
29
29
|
import {
|
|
30
30
|
Cartesian2_default
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-MYDS6HBL.js";
|
|
32
32
|
import {
|
|
33
33
|
Cartesian3_default,
|
|
34
34
|
Matrix3_default
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-HIDSEUWS.js";
|
|
36
36
|
import {
|
|
37
37
|
Check_default
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-6EHT6GS3.js";
|
|
39
39
|
|
|
40
40
|
// packages/engine/Source/Core/CoplanarPolygonGeometryLibrary.js
|
|
41
41
|
var CoplanarPolygonGeometryLibrary = {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,16 +25,16 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
Math_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-4HN3N5SE.js";
|
|
29
29
|
import {
|
|
30
30
|
WebGLConstants_default
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-TXYJOVQK.js";
|
|
32
32
|
import {
|
|
33
33
|
DeveloperError_default
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-6EHT6GS3.js";
|
|
35
35
|
import {
|
|
36
36
|
defined_default
|
|
37
|
-
} from "./chunk-
|
|
37
|
+
} from "./chunk-TXOGSFHZ.js";
|
|
38
38
|
|
|
39
39
|
// packages/engine/Source/Core/IndexDatatype.js
|
|
40
40
|
var IndexDatatype = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,16 +25,16 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
WebGLConstants_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-TXYJOVQK.js";
|
|
29
29
|
import {
|
|
30
30
|
defaultValue_default
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-GPO47TW4.js";
|
|
32
32
|
import {
|
|
33
33
|
DeveloperError_default
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-6EHT6GS3.js";
|
|
35
35
|
import {
|
|
36
36
|
defined_default
|
|
37
|
-
} from "./chunk-
|
|
37
|
+
} from "./chunk-TXOGSFHZ.js";
|
|
38
38
|
|
|
39
39
|
// packages/engine/Source/Core/ComponentDatatype.js
|
|
40
40
|
var ComponentDatatype = {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,43 +25,43 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
WebMercatorProjection_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-KZFXE35V.js";
|
|
29
29
|
import {
|
|
30
30
|
GeometryPipeline_default
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-P32XMW4I.js";
|
|
32
32
|
import {
|
|
33
33
|
IndexDatatype_default
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-CROU4RHL.js";
|
|
35
35
|
import {
|
|
36
36
|
GeometryAttributes_default
|
|
37
|
-
} from "./chunk-
|
|
37
|
+
} from "./chunk-YLMDWSXO.js";
|
|
38
38
|
import {
|
|
39
39
|
GeometryAttribute_default,
|
|
40
40
|
Geometry_default
|
|
41
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-HV67ARO7.js";
|
|
42
42
|
import {
|
|
43
43
|
BoundingSphere_default,
|
|
44
44
|
GeographicProjection_default
|
|
45
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-V5S5N2IS.js";
|
|
46
46
|
import {
|
|
47
47
|
Matrix4_default
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-MYDS6HBL.js";
|
|
49
49
|
import {
|
|
50
50
|
ComponentDatatype_default
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-CTJCECTX.js";
|
|
52
52
|
import {
|
|
53
53
|
Ellipsoid_default
|
|
54
|
-
} from "./chunk-
|
|
54
|
+
} from "./chunk-HIDSEUWS.js";
|
|
55
55
|
import {
|
|
56
56
|
defaultValue_default
|
|
57
|
-
} from "./chunk-
|
|
57
|
+
} from "./chunk-GPO47TW4.js";
|
|
58
58
|
import {
|
|
59
59
|
Check_default,
|
|
60
60
|
DeveloperError_default
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-6EHT6GS3.js";
|
|
62
62
|
import {
|
|
63
63
|
defined_default
|
|
64
|
-
} from "./chunk-
|
|
64
|
+
} from "./chunk-TXOGSFHZ.js";
|
|
65
65
|
|
|
66
66
|
// packages/engine/Source/Core/OffsetGeometryInstanceAttribute.js
|
|
67
67
|
function OffsetGeometryInstanceAttribute(x, y, z) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,16 +25,16 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
Matrix4_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-MYDS6HBL.js";
|
|
29
29
|
import {
|
|
30
30
|
defaultValue_default
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-GPO47TW4.js";
|
|
32
32
|
import {
|
|
33
33
|
DeveloperError_default
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-6EHT6GS3.js";
|
|
35
35
|
import {
|
|
36
36
|
defined_default
|
|
37
|
-
} from "./chunk-
|
|
37
|
+
} from "./chunk-TXOGSFHZ.js";
|
|
38
38
|
|
|
39
39
|
// packages/engine/Source/Core/GeometryInstance.js
|
|
40
40
|
function GeometryInstance(options) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,47 +25,47 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
VertexFormat_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-MRCFDEKH.js";
|
|
29
29
|
import {
|
|
30
30
|
Plane_default
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-6I22NWKQ.js";
|
|
32
32
|
import {
|
|
33
33
|
GeometryAttributes_default
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-YLMDWSXO.js";
|
|
35
35
|
import {
|
|
36
36
|
GeometryAttribute_default,
|
|
37
37
|
Geometry_default,
|
|
38
38
|
PrimitiveType_default
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-HV67ARO7.js";
|
|
40
40
|
import {
|
|
41
41
|
BoundingSphere_default,
|
|
42
42
|
Intersect_default,
|
|
43
43
|
Quaternion_default
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-V5S5N2IS.js";
|
|
45
45
|
import {
|
|
46
46
|
Cartesian4_default,
|
|
47
47
|
Matrix4_default
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-MYDS6HBL.js";
|
|
49
49
|
import {
|
|
50
50
|
ComponentDatatype_default
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-CTJCECTX.js";
|
|
52
52
|
import {
|
|
53
53
|
Cartesian3_default,
|
|
54
54
|
Matrix3_default
|
|
55
|
-
} from "./chunk-
|
|
55
|
+
} from "./chunk-HIDSEUWS.js";
|
|
56
56
|
import {
|
|
57
57
|
Math_default
|
|
58
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-4HN3N5SE.js";
|
|
59
59
|
import {
|
|
60
60
|
defaultValue_default
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-GPO47TW4.js";
|
|
62
62
|
import {
|
|
63
63
|
Check_default,
|
|
64
64
|
DeveloperError_default
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-6EHT6GS3.js";
|
|
66
66
|
import {
|
|
67
67
|
defined_default
|
|
68
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-TXOGSFHZ.js";
|
|
69
69
|
|
|
70
70
|
// packages/engine/Source/Core/CullingVolume.js
|
|
71
71
|
function CullingVolume(planes) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,39 +25,39 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
EllipsoidTangentPlane_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-K3VEWONC.js";
|
|
29
29
|
import {
|
|
30
30
|
Plane_default
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-6I22NWKQ.js";
|
|
32
32
|
import {
|
|
33
33
|
BoundingSphere_default,
|
|
34
34
|
Intersect_default,
|
|
35
35
|
Interval_default
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-V5S5N2IS.js";
|
|
37
37
|
import {
|
|
38
38
|
Cartesian2_default,
|
|
39
39
|
Matrix4_default,
|
|
40
40
|
Rectangle_default
|
|
41
|
-
} from "./chunk-
|
|
41
|
+
} from "./chunk-MYDS6HBL.js";
|
|
42
42
|
import {
|
|
43
43
|
Cartesian3_default,
|
|
44
44
|
Cartographic_default,
|
|
45
45
|
Ellipsoid_default,
|
|
46
46
|
Matrix3_default
|
|
47
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-HIDSEUWS.js";
|
|
48
48
|
import {
|
|
49
49
|
Math_default
|
|
50
|
-
} from "./chunk-
|
|
50
|
+
} from "./chunk-4HN3N5SE.js";
|
|
51
51
|
import {
|
|
52
52
|
defaultValue_default
|
|
53
|
-
} from "./chunk-
|
|
53
|
+
} from "./chunk-GPO47TW4.js";
|
|
54
54
|
import {
|
|
55
55
|
Check_default,
|
|
56
56
|
DeveloperError_default
|
|
57
|
-
} from "./chunk-
|
|
57
|
+
} from "./chunk-6EHT6GS3.js";
|
|
58
58
|
import {
|
|
59
59
|
defined_default
|
|
60
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-TXOGSFHZ.js";
|
|
61
61
|
|
|
62
62
|
// packages/engine/Source/Core/OrientedBoundingBox.js
|
|
63
63
|
function OrientedBoundingBox(center, halfAxes) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* @license
|
|
3
3
|
* Cesium - https://github.com/CesiumGS/cesium
|
|
4
|
-
* Version 1.
|
|
4
|
+
* Version 1.110
|
|
5
5
|
*
|
|
6
6
|
* Copyright 2011-2022 Cesium Contributors
|
|
7
7
|
*
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
|
|
26
26
|
import {
|
|
27
27
|
Math_default
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-4HN3N5SE.js";
|
|
29
29
|
|
|
30
30
|
// packages/engine/Source/Core/CylinderGeometryLibrary.js
|
|
31
31
|
var CylinderGeometryLibrary = {};
|