@cesium/engine 9.0.0 → 9.2.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/ThirdParty/Workers/pako_deflate.min.js +108 -210
- package/Build/ThirdParty/Workers/pako_inflate.min.js +466 -568
- package/Build/ThirdParty/Workers/z-worker-pako.js +56 -105
- package/Build/Workers/{chunk-VR5RBW52.js → chunk-26NE4LRW.js} +7 -7
- package/Build/Workers/{chunk-P2YAAMT2.js → chunk-26XJDV3D.js} +15 -15
- package/Build/Workers/{chunk-L4BW3RUA.js → chunk-2TRB253J.js} +7 -7
- package/Build/Workers/{chunk-NP2GYYE5.js → chunk-3PV5HQ2R.js} +6 -6
- package/Build/Workers/{chunk-BCU2LH5T.js → chunk-3VDHTBY5.js} +10 -10
- package/Build/Workers/{chunk-WHUSTDIB.js → chunk-4RG6WOXH.js} +10 -10
- package/Build/Workers/{chunk-P4XKB3QZ.js → chunk-5OK5JFDP.js} +5 -5
- package/Build/Workers/{chunk-2ZBL3MVO.js → chunk-7HLZRYGD.js} +10 -12
- package/Build/Workers/chunk-7PFZ4Z7C.js +961 -0
- package/Build/Workers/{chunk-24YTYWNB.js → chunk-A5CSB5ZE.js} +11 -13
- package/Build/Workers/{chunk-RMOEYCZW.js → chunk-AROLUUGS.js} +2 -2
- package/Build/Workers/{chunk-3NCVAGDA.js → chunk-BBBTT36L.js} +14 -14
- package/Build/Workers/{chunk-QKBGRKKG.js → chunk-BNT2SNWU.js} +4 -4
- package/Build/Workers/{chunk-LQJ5FFFR.js → chunk-CFBGPZU6.js} +11 -13
- package/Build/Workers/{chunk-C6OI26DR.js → chunk-CVCVMOQA.js} +1 -1
- package/Build/Workers/{chunk-SS4ESNE3.js → chunk-DIVFF6DK.js} +2 -2
- package/Build/Workers/{chunk-PXB7T27O.js → chunk-EJZVBTX4.js} +6 -6
- package/Build/Workers/{chunk-TZORKRNK.js → chunk-EODIOQ35.js} +1 -1
- package/Build/Workers/{chunk-QCQUZGXI.js → chunk-ETC45PHH.js} +5 -6
- package/Build/Workers/{chunk-E6WXPSJS.js → chunk-G7IAO7CW.js} +7 -7
- package/Build/Workers/{chunk-X2F6BEPY.js → chunk-GOQEANLM.js} +16 -16
- package/Build/Workers/{chunk-7COR472O.js → chunk-GUFV24F4.js} +7197 -5096
- package/Build/Workers/{chunk-5TIV3L26.js → chunk-GX2BWBN2.js} +13 -13
- package/Build/Workers/{chunk-ADOVHYWO.js → chunk-GX5LMUGZ.js} +469 -6
- package/Build/Workers/{chunk-2632RVPI.js → chunk-I6CW7ZE5.js} +7 -7
- package/Build/Workers/{chunk-YDVSBWEO.js → chunk-IF2OX6R4.js} +3 -5
- package/Build/Workers/{chunk-RSJXEO2A.js → chunk-IXYFH7DV.js} +95 -155
- package/Build/Workers/{chunk-ZNVSKMQ2.js → chunk-K5F23SZO.js} +6 -6
- package/Build/Workers/{chunk-MWV7IZK4.js → chunk-KTZK2UDR.js} +7 -7
- package/Build/Workers/{chunk-HBQPB6IH.js → chunk-LZFFO4KB.js} +12 -12
- package/Build/Workers/{chunk-GFA4SMXV.js → chunk-OYP23VAL.js} +11 -11
- package/Build/Workers/{chunk-ZYPTP7GS.js → chunk-PHT53MCH.js} +11 -11
- package/Build/Workers/{chunk-TJBU6GML.js → chunk-PUQR43HZ.js} +6 -6
- package/Build/Workers/{chunk-CO35JNNE.js → chunk-QZIWFSRM.js} +4 -4
- package/Build/Workers/{chunk-C3XBUYBO.js → chunk-RDR4KVPA.js} +17 -17
- package/Build/Workers/{chunk-YV4H2Y7M.js → chunk-RRUO4QEK.js} +4 -4
- package/Build/Workers/{chunk-LAQP3SCC.js → chunk-RTIT7UDN.js} +2 -2
- package/Build/Workers/{chunk-Z7FQLK6N.js → chunk-SC3TBKST.js} +4 -4
- package/Build/Workers/{chunk-GXUXEOE2.js → chunk-TDIGL45B.js} +1 -1
- package/Build/Workers/{chunk-EOXYZ34O.js → chunk-TP4FFUAH.js} +2 -2
- package/Build/Workers/{chunk-N4KXMWQU.js → chunk-U2LSTOMA.js} +2 -2
- package/Build/Workers/{chunk-6WF3KIF5.js → chunk-U6MTSO6A.js} +47 -84
- package/Build/Workers/{chunk-I37B3MZ2.js → chunk-UICVDDCQ.js} +1 -1
- package/Build/Workers/{chunk-DPUSFA7S.js → chunk-UKJCFXVV.js} +6 -6
- package/Build/Workers/{chunk-EPKE7GE3.js → chunk-UYKG3UFK.js} +5 -5
- package/Build/Workers/{chunk-RV7ZOSS6.js → chunk-W4OS542B.js} +13 -13
- package/Build/Workers/{chunk-DGDUKCJJ.js → chunk-WHDEZSAL.js} +6 -6
- package/Build/Workers/{chunk-NZWNZA6S.js → chunk-WOYQB5HM.js} +5 -5
- package/Build/Workers/{chunk-M2AYBTNH.js → chunk-WP3LCUOE.js} +13 -13
- package/Build/Workers/{chunk-73FKKY52.js → chunk-YGNQJ4YI.js} +5 -5
- package/Build/Workers/{chunk-SE4PXOEA.js → chunk-YGTWKLFY.js} +19 -19
- package/Build/Workers/{chunk-5R6VWLMH.js → chunk-ZHJDE6JN.js} +6 -6
- package/Build/Workers/combineGeometry.js +22 -24
- package/Build/Workers/createBoxGeometry.js +16 -18
- package/Build/Workers/createBoxOutlineGeometry.js +14 -16
- package/Build/Workers/createCircleGeometry.js +24 -26
- package/Build/Workers/createCircleOutlineGeometry.js +17 -19
- package/Build/Workers/createCoplanarPolygonGeometry.js +33 -34
- package/Build/Workers/createCoplanarPolygonOutlineGeometry.js +29 -31
- package/Build/Workers/createCorridorGeometry.js +27 -29
- package/Build/Workers/createCorridorOutlineGeometry.js +26 -28
- package/Build/Workers/createCylinderGeometry.js +18 -20
- package/Build/Workers/createCylinderOutlineGeometry.js +16 -18
- package/Build/Workers/createEllipseGeometry.js +24 -26
- package/Build/Workers/createEllipseOutlineGeometry.js +17 -19
- package/Build/Workers/createEllipsoidGeometry.js +17 -19
- package/Build/Workers/createEllipsoidOutlineGeometry.js +16 -18
- package/Build/Workers/createFrustumGeometry.js +16 -18
- package/Build/Workers/createFrustumOutlineGeometry.js +18 -19
- package/Build/Workers/createGeometry.js +22 -24
- package/Build/Workers/createGroundPolylineGeometry.js +23 -25
- package/Build/Workers/createPlaneGeometry.js +14 -16
- package/Build/Workers/createPlaneOutlineGeometry.js +13 -15
- package/Build/Workers/createPolygonGeometry.js +32 -34
- package/Build/Workers/createPolygonOutlineGeometry.js +28 -30
- package/Build/Workers/createPolylineGeometry.js +23 -25
- package/Build/Workers/createPolylineVolumeGeometry.js +29 -31
- package/Build/Workers/createPolylineVolumeOutlineGeometry.js +25 -27
- package/Build/Workers/createRectangleGeometry.js +27 -29
- package/Build/Workers/createRectangleOutlineGeometry.js +18 -20
- package/Build/Workers/createSimplePolylineGeometry.js +21 -23
- package/Build/Workers/createSphereGeometry.js +17 -19
- package/Build/Workers/createSphereOutlineGeometry.js +16 -18
- package/Build/Workers/createTaskProcessorWorker.js +3 -3
- package/Build/Workers/createVectorTileClampedPolylines.js +14 -16
- package/Build/Workers/createVectorTileGeometries.js +22 -24
- package/Build/Workers/createVectorTilePoints.js +12 -12
- package/Build/Workers/createVectorTilePolygons.js +20 -22
- package/Build/Workers/createVectorTilePolylines.js +14 -16
- package/Build/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +23 -25
- package/Build/Workers/createVerticesFromHeightmap.js +23 -25
- package/Build/Workers/createVerticesFromQuantizedTerrainMesh.js +19 -22
- package/Build/Workers/createWallGeometry.js +22 -24
- package/Build/Workers/createWallOutlineGeometry.js +21 -23
- package/Build/Workers/decodeDraco.js +11 -11
- package/Build/Workers/decodeGoogleEarthEnterprisePacket.js +12 -19
- package/Build/Workers/decodeI3S.js +10 -11
- package/Build/Workers/transcodeKTX2.js +44 -80
- package/Build/Workers/transferTypedArrayTest.js +1 -1
- package/Build/Workers/upsampleQuantizedTerrainMesh.js +20 -22
- package/Source/Core/Ion.js +1 -1
- package/Source/Core/Math.js +0 -5
- package/Source/Core/PixelFormat.js +1 -0
- package/Source/Core/Rectangle.js +89 -0
- package/Source/Core/TaskProcessor.js +19 -3
- package/Source/Core/sampleTerrain.js +3 -3
- package/Source/DataSources/DataSourceDisplay.js +5 -0
- package/Source/Renderer/ShaderBuilder.js +6 -3
- package/Source/Scene/ArcGisMapService.js +1 -1
- package/Source/Scene/Billboard.js +7 -5
- package/Source/Scene/Cesium3DTile.js +65 -0
- package/Source/Scene/Cesium3DTileset.js +48 -1
- package/Source/Scene/ClippingPolygon.js +212 -0
- package/Source/Scene/ClippingPolygonCollection.js +968 -0
- package/Source/Scene/Globe.js +14 -0
- package/Source/Scene/GlobeSurfaceShaderSet.js +81 -15
- package/Source/Scene/GlobeSurfaceTileProvider.js +81 -1
- package/Source/Scene/GltfLoader.js +458 -435
- package/Source/Scene/GltfLoaderUtil.js +3 -12
- package/Source/Scene/GltfPipeline/forEachTextureInMaterial.js +23 -7
- package/Source/Scene/GltfStructuralMetadataLoader.js +11 -9
- package/Source/Scene/Label.js +1 -1
- package/Source/Scene/Model/AlphaPipelineStage.js +1 -1
- package/Source/Scene/Model/GeometryPipelineStage.js +15 -43
- package/Source/Scene/Model/ImageBasedLightingPipelineStage.js +7 -0
- package/Source/Scene/Model/LightingPipelineStage.js +2 -4
- package/Source/Scene/Model/MaterialPipelineStage.js +346 -29
- package/Source/Scene/Model/Model.js +91 -3
- package/Source/Scene/Model/Model3DTileContent.js +21 -0
- package/Source/Scene/Model/ModelClippingPolygonsPipelineStage.js +92 -0
- package/Source/Scene/Model/ModelSceneGraph.js +5 -0
- package/Source/Scene/Model/ModelUtility.js +3 -0
- package/Source/Scene/Model/VerticalExaggerationPipelineStage.js +4 -6
- package/Source/Scene/ModelComponents.js +169 -1
- package/Source/Scene/PickDepth.js +23 -15
- package/Source/Scene/ResourceCache.js +41 -50
- package/Source/Scene/ResourceCacheKey.js +41 -53
- package/Source/Scene/Terrain.js +2 -2
- package/Source/Shaders/Builtin/CzmBuiltins.js +6 -8
- package/Source/Shaders/Builtin/Functions/clipPolygons.glsl +37 -0
- package/Source/Shaders/Builtin/Functions/clipPolygons.js +39 -0
- package/Source/Shaders/Builtin/Functions/maximumComponent.glsl +21 -0
- package/Source/Shaders/Builtin/Functions/maximumComponent.js +23 -0
- package/Source/Shaders/Builtin/Functions/pbrLighting.glsl +108 -44
- package/Source/Shaders/Builtin/Functions/pbrLighting.js +108 -44
- package/Source/Shaders/Builtin/Functions/unpackClippingExtents.glsl +14 -0
- package/Source/Shaders/Builtin/Functions/unpackClippingExtents.js +15 -0
- package/Source/Shaders/Builtin/Structs/modelMaterial.glsl +14 -0
- package/Source/Shaders/Builtin/Structs/modelMaterial.js +14 -0
- package/Source/Shaders/GlobeFS.glsl +13 -1
- package/Source/Shaders/GlobeFS.js +13 -1
- package/Source/Shaders/GlobeVS.glsl +32 -0
- package/Source/Shaders/GlobeVS.js +32 -0
- package/Source/Shaders/Model/GeometryStageVS.glsl +1 -1
- package/Source/Shaders/Model/GeometryStageVS.js +1 -1
- package/Source/Shaders/Model/ImageBasedLightingStageFS.glsl +211 -133
- package/Source/Shaders/Model/ImageBasedLightingStageFS.js +212 -133
- package/Source/Shaders/Model/LightingStageFS.glsl +113 -48
- package/Source/Shaders/Model/LightingStageFS.js +113 -48
- package/Source/Shaders/Model/MaterialStageFS.glsl +399 -137
- package/Source/Shaders/Model/MaterialStageFS.js +399 -137
- package/Source/Shaders/Model/ModelClippingPolygonsStageFS.glsl +6 -0
- package/Source/Shaders/Model/ModelClippingPolygonsStageFS.js +8 -0
- package/Source/Shaders/Model/ModelClippingPolygonsStageVS.glsl +27 -0
- package/Source/Shaders/Model/ModelClippingPolygonsStageVS.js +29 -0
- package/Source/Shaders/Model/ModelFS.glsl +6 -0
- package/Source/Shaders/Model/ModelFS.js +7 -1
- package/Source/Shaders/Model/ModelVS.glsl +4 -0
- package/Source/Shaders/Model/ModelVS.js +4 -0
- package/Source/Shaders/PolygonSignedDistanceFS.glsl +100 -0
- package/Source/Shaders/PolygonSignedDistanceFS.js +101 -0
- package/Source/ThirdParty/Workers/z-worker-pako.js +1 -1
- package/index.d.ts +230 -4
- package/index.js +234 -229
- package/package.json +1 -1
- package/Build/Workers/chunk-2KACWKS4.js +0 -501
- package/Build/Workers/chunk-2XPLH3JY.js +0 -2977
- package/Build/Workers/chunk-X6XOMPWL.js +0 -73
- package/Source/Shaders/Builtin/Functions/defaultPbrMaterial.glsl +0 -16
- package/Source/Shaders/Builtin/Functions/defaultPbrMaterial.js +0 -18
- package/Source/Shaders/Builtin/Functions/pbrMetallicRoughnessMaterial.glsl +0 -37
- package/Source/Shaders/Builtin/Functions/pbrMetallicRoughnessMaterial.js +0 -39
- package/Source/Shaders/Builtin/Functions/pbrSpecularGlossinessMaterial.glsl +0 -30
- package/Source/Shaders/Builtin/Functions/pbrSpecularGlossinessMaterial.js +0 -32
- package/Source/Shaders/Builtin/Structs/pbrParameters.glsl +0 -16
- package/Source/Shaders/Builtin/Structs/pbrParameters.js +0 -18
package/index.d.ts
CHANGED
|
@@ -6425,7 +6425,7 @@ export class Event<Listener extends (...args: any[]) => void = (...args: any[])
|
|
|
6425
6425
|
* Raises the event by calling each registered listener with all supplied arguments.
|
|
6426
6426
|
* @param arguments - This method takes any number of parameters and passes them through to the listener functions.
|
|
6427
6427
|
*/
|
|
6428
|
-
raiseEvent(...arguments: Parameters<Listener>
|
|
6428
|
+
raiseEvent(...arguments: Parameters<Listener>): void;
|
|
6429
6429
|
}
|
|
6430
6430
|
|
|
6431
6431
|
export namespace Event {
|
|
@@ -14210,6 +14210,14 @@ export class Rectangle {
|
|
|
14210
14210
|
* @returns The modified result parameter or a new Rectangle instance if none was provided.
|
|
14211
14211
|
*/
|
|
14212
14212
|
static fromCartesianArray(cartesians: Cartesian3[], ellipsoid?: Ellipsoid, result?: Rectangle): Rectangle;
|
|
14213
|
+
/**
|
|
14214
|
+
* Create a rectangle from a bounding sphere, ignoring height.
|
|
14215
|
+
* @param boundingSphere - The bounding sphere.
|
|
14216
|
+
* @param [ellipsoid = Ellipsoid.WGS84] - The ellipsoid.
|
|
14217
|
+
* @param [result] - The object onto which to store the result, or undefined if a new instance should be created.
|
|
14218
|
+
* @returns The modified result parameter or a new Rectangle instance if none was provided.
|
|
14219
|
+
*/
|
|
14220
|
+
static fromBoundingSphere(boundingSphere: BoundingSphere, ellipsoid?: Ellipsoid, result?: Rectangle): Rectangle;
|
|
14213
14221
|
/**
|
|
14214
14222
|
* Duplicates a Rectangle.
|
|
14215
14223
|
* @param rectangle - The rectangle to clone.
|
|
@@ -18524,7 +18532,7 @@ export function queryToObject(queryString: string): any;
|
|
|
18524
18532
|
* @param terrainProvider - The terrain provider from which to query heights.
|
|
18525
18533
|
* @param level - The terrain level-of-detail from which to query terrain heights.
|
|
18526
18534
|
* @param positions - The positions to update with terrain heights.
|
|
18527
|
-
* @param [rejectOnTileFail = false] - If true, for
|
|
18535
|
+
* @param [rejectOnTileFail = false] - If true, for any failed terrain tile requests, the promise will be rejected. If false, returned heights will be undefined.
|
|
18528
18536
|
* @returns A promise that resolves to the provided list of positions when terrain the query has completed.
|
|
18529
18537
|
*/
|
|
18530
18538
|
export function sampleTerrain(terrainProvider: TerrainProvider, level: number, positions: Cartographic[], rejectOnTileFail?: boolean): Promise<Cartographic[]>;
|
|
@@ -25842,7 +25850,7 @@ export namespace Billboard {
|
|
|
25842
25850
|
*/
|
|
25843
25851
|
type ConstructorOptions = {
|
|
25844
25852
|
position: Cartesian3;
|
|
25845
|
-
id?:
|
|
25853
|
+
id?: any;
|
|
25846
25854
|
show?: boolean;
|
|
25847
25855
|
image?: string | HTMLCanvasElement;
|
|
25848
25856
|
scale?: number;
|
|
@@ -28949,6 +28957,7 @@ export namespace Cesium3DTileset {
|
|
|
28949
28957
|
* @property [immediatelyLoadDesiredLevelOfDetail = false] - When <code>skipLevelOfDetail</code> is <code>true</code>, only tiles that meet the maximum screen space error will ever be downloaded. Skipping factors are ignored and just the desired tiles are loaded.
|
|
28950
28958
|
* @property [loadSiblings = false] - When <code>skipLevelOfDetail</code> is <code>true</code>, determines whether siblings of visible tiles are always downloaded during traversal.
|
|
28951
28959
|
* @property [clippingPlanes] - The {@link ClippingPlaneCollection} used to selectively disable rendering the tileset.
|
|
28960
|
+
* @property [clippingPolygons] - The {@link ClippingPolygonCollection} used to selectively disable rendering the tileset.
|
|
28952
28961
|
* @property [classificationType] - Determines whether terrain, 3D Tiles or both will be classified by this tileset. See {@link Cesium3DTileset#classificationType} for details about restrictions and limitations.
|
|
28953
28962
|
* @property [ellipsoid = Ellipsoid.WGS84] - The ellipsoid determining the size and shape of the globe.
|
|
28954
28963
|
* @property [pointCloudShading] - Options for constructing a {@link PointCloudShading} object to control point attenuation based on geometric error and lighting.
|
|
@@ -29012,6 +29021,7 @@ export namespace Cesium3DTileset {
|
|
|
29012
29021
|
immediatelyLoadDesiredLevelOfDetail?: boolean;
|
|
29013
29022
|
loadSiblings?: boolean;
|
|
29014
29023
|
clippingPlanes?: ClippingPlaneCollection;
|
|
29024
|
+
clippingPolygons?: ClippingPolygonCollection;
|
|
29015
29025
|
classificationType?: ClassificationType;
|
|
29016
29026
|
ellipsoid?: Ellipsoid;
|
|
29017
29027
|
pointCloudShading?: any;
|
|
@@ -29531,6 +29541,10 @@ export class Cesium3DTileset {
|
|
|
29531
29541
|
* The {@link ClippingPlaneCollection} used to selectively disable rendering the tileset.
|
|
29532
29542
|
*/
|
|
29533
29543
|
clippingPlanes: ClippingPlaneCollection;
|
|
29544
|
+
/**
|
|
29545
|
+
* The {@link ClippingPolygonCollection} used to selectively disable rendering the tileset.
|
|
29546
|
+
*/
|
|
29547
|
+
clippingPolygons: ClippingPolygonCollection;
|
|
29534
29548
|
/**
|
|
29535
29549
|
* Gets the tileset's properties dictionary object, which contains metadata about per-feature properties.
|
|
29536
29550
|
* <p>
|
|
@@ -30286,6 +30300,200 @@ export class ClippingPlaneCollection {
|
|
|
30286
30300
|
destroy(): void;
|
|
30287
30301
|
}
|
|
30288
30302
|
|
|
30303
|
+
/**
|
|
30304
|
+
* A geodesic polygon to be used with {@link ClippingPlaneCollection} for selectively hiding regions in a model, a 3D tileset, or the globe.
|
|
30305
|
+
* @example
|
|
30306
|
+
* const positions = Cesium.Cartesian3.fromRadiansArray([
|
|
30307
|
+
* -1.3194369277314022,
|
|
30308
|
+
* 0.6988062530900625,
|
|
30309
|
+
* -1.31941,
|
|
30310
|
+
* 0.69879,
|
|
30311
|
+
* -1.3193955980204217,
|
|
30312
|
+
* 0.6988091578771254,
|
|
30313
|
+
* -1.3193931220959367,
|
|
30314
|
+
* 0.698743632490865,
|
|
30315
|
+
* -1.3194358224045408,
|
|
30316
|
+
* 0.6987471965556998,
|
|
30317
|
+
* ]);
|
|
30318
|
+
*
|
|
30319
|
+
* const polygon = new Cesium.ClippingPolygon({
|
|
30320
|
+
* positions: positions
|
|
30321
|
+
* });
|
|
30322
|
+
* @param options - Object with the following properties:
|
|
30323
|
+
* @param options.positions - A list of three or more Cartesian coordinates defining the outer ring of the clipping polygon.
|
|
30324
|
+
*/
|
|
30325
|
+
export class ClippingPolygon {
|
|
30326
|
+
constructor(options: {
|
|
30327
|
+
positions: Cartesian3[];
|
|
30328
|
+
ellipsoid?: Ellipsoid;
|
|
30329
|
+
});
|
|
30330
|
+
/**
|
|
30331
|
+
* Returns the total number of positions in the polygon, include any holes.
|
|
30332
|
+
*/
|
|
30333
|
+
readonly length: number;
|
|
30334
|
+
/**
|
|
30335
|
+
* Returns the outer ring of positions.
|
|
30336
|
+
*/
|
|
30337
|
+
readonly positions: Cartesian3[];
|
|
30338
|
+
/**
|
|
30339
|
+
* Returns the ellipsoid used to project the polygon onto surfaces when clipping.
|
|
30340
|
+
*/
|
|
30341
|
+
readonly ellipsoid: Ellipsoid;
|
|
30342
|
+
/**
|
|
30343
|
+
* Clones the ClippingPolygon without setting its ownership.
|
|
30344
|
+
* @param polygon - The ClippingPolygon to be cloned
|
|
30345
|
+
* @param [result] - The object on which to store the cloned parameters.
|
|
30346
|
+
* @returns a clone of the input ClippingPolygon
|
|
30347
|
+
*/
|
|
30348
|
+
static clone(polygon: ClippingPolygon, result?: ClippingPolygon): ClippingPolygon;
|
|
30349
|
+
/**
|
|
30350
|
+
* Compares the provided ClippingPolygons and returns
|
|
30351
|
+
* <code>true</code> if they are equal, <code>false</code> otherwise.
|
|
30352
|
+
* @param left - The first polygon.
|
|
30353
|
+
* @param right - The second polygon.
|
|
30354
|
+
* @returns <code>true</code> if left and right are equal, <code>false</code> otherwise.
|
|
30355
|
+
*/
|
|
30356
|
+
static equals(left: Plane, right: Plane): boolean;
|
|
30357
|
+
/**
|
|
30358
|
+
* Computes a cartographic rectangle which encloses the polygon defined by the list of positions, including cases over the international date line and the poles.
|
|
30359
|
+
* @param [result] - An object in which to store the result.
|
|
30360
|
+
* @returns The result rectangle
|
|
30361
|
+
*/
|
|
30362
|
+
computeRectangle(result?: Rectangle): Rectangle;
|
|
30363
|
+
}
|
|
30364
|
+
|
|
30365
|
+
/**
|
|
30366
|
+
* Specifies a set of clipping polygons. Clipping polygons selectively disable rendering in a region
|
|
30367
|
+
* inside or outside the specified list of {@link ClippingPolygon} objects for a single glTF model, 3D Tileset, or the globe.
|
|
30368
|
+
*
|
|
30369
|
+
* Clipping Polygons are only supported in WebGL 2 contexts.
|
|
30370
|
+
* @example
|
|
30371
|
+
* const positions = Cesium.Cartesian3.fromRadiansArray([
|
|
30372
|
+
* -1.3194369277314022,
|
|
30373
|
+
* 0.6988062530900625,
|
|
30374
|
+
* -1.31941,
|
|
30375
|
+
* 0.69879,
|
|
30376
|
+
* -1.3193955980204217,
|
|
30377
|
+
* 0.6988091578771254,
|
|
30378
|
+
* -1.3193931220959367,
|
|
30379
|
+
* 0.698743632490865,
|
|
30380
|
+
* -1.3194358224045408,
|
|
30381
|
+
* 0.6987471965556998,
|
|
30382
|
+
* ]);
|
|
30383
|
+
*
|
|
30384
|
+
* const polygon = new Cesium.ClippingPolygon({
|
|
30385
|
+
* positions: positions
|
|
30386
|
+
* });
|
|
30387
|
+
*
|
|
30388
|
+
* const polygons = new Cesium.ClippingPolygonCollection({
|
|
30389
|
+
* polygons: [ polygon ]
|
|
30390
|
+
* });
|
|
30391
|
+
* @param [options] - Object with the following properties:
|
|
30392
|
+
* @param [options.polygons = []] - An array of {@link ClippingPolygon} objects used to selectively disable rendering on the inside of each polygon.
|
|
30393
|
+
* @param [options.enabled = true] - Determines whether the clipping polygons are active.
|
|
30394
|
+
* @param [options.inverse = false] - If true, a region will be clipped if it is outside of every polygon in the collection. Otherwise, a region will only be clipped if it is on the inside of any polygon.
|
|
30395
|
+
*/
|
|
30396
|
+
export class ClippingPolygonCollection {
|
|
30397
|
+
constructor(options?: {
|
|
30398
|
+
polygons?: ClippingPolygon[];
|
|
30399
|
+
enabled?: boolean;
|
|
30400
|
+
inverse?: boolean;
|
|
30401
|
+
});
|
|
30402
|
+
/**
|
|
30403
|
+
* An event triggered when a new clipping polygon is added to the collection. Event handlers
|
|
30404
|
+
* are passed the new polygon and the index at which it was added.
|
|
30405
|
+
*/
|
|
30406
|
+
polygonAdded: Event;
|
|
30407
|
+
/**
|
|
30408
|
+
* An event triggered when a new clipping polygon is removed from the collection. Event handlers
|
|
30409
|
+
* are passed the new polygon and the index from which it was removed.
|
|
30410
|
+
*/
|
|
30411
|
+
polygonRemoved: Event;
|
|
30412
|
+
/**
|
|
30413
|
+
* Returns the number of polygons in this collection. This is commonly used with
|
|
30414
|
+
* {@link ClippingPolygonCollection#get} to iterate over all the polygons
|
|
30415
|
+
* in the collection.
|
|
30416
|
+
*/
|
|
30417
|
+
readonly length: number;
|
|
30418
|
+
/**
|
|
30419
|
+
* Adds the specified {@link ClippingPolygon} to the collection to be used to selectively disable rendering
|
|
30420
|
+
* on the inside of each polygon. Use {@link ClippingPolygonCollection#unionClippingRegions} to modify
|
|
30421
|
+
* how modify the clipping behavior of multiple polygons.
|
|
30422
|
+
* @example
|
|
30423
|
+
* const polygons = new Cesium.ClippingPolygonCollection();
|
|
30424
|
+
*
|
|
30425
|
+
* const positions = Cesium.Cartesian3.fromRadiansArray([
|
|
30426
|
+
* -1.3194369277314022,
|
|
30427
|
+
* 0.6988062530900625,
|
|
30428
|
+
* -1.31941,
|
|
30429
|
+
* 0.69879,
|
|
30430
|
+
* -1.3193955980204217,
|
|
30431
|
+
* 0.6988091578771254,
|
|
30432
|
+
* -1.3193931220959367,
|
|
30433
|
+
* 0.698743632490865,
|
|
30434
|
+
* -1.3194358224045408,
|
|
30435
|
+
* 0.6987471965556998,
|
|
30436
|
+
* ]);
|
|
30437
|
+
*
|
|
30438
|
+
* polygons.add(new Cesium.ClippingPolygon({
|
|
30439
|
+
* positions: positions
|
|
30440
|
+
* }));
|
|
30441
|
+
* @param polygon - The ClippingPolygon to add to the collection.
|
|
30442
|
+
* @returns The added ClippingPolygon.
|
|
30443
|
+
*/
|
|
30444
|
+
add(polygon: ClippingPolygon): ClippingPolygon;
|
|
30445
|
+
/**
|
|
30446
|
+
* Returns the clipping polygon in the collection at the specified index. Indices are zero-based
|
|
30447
|
+
* and increase as polygons are added. Removing a polygon polygon all polygons after
|
|
30448
|
+
* it to the left, changing their indices. This function is commonly used with
|
|
30449
|
+
* {@link ClippingPolygonCollection#length} to iterate over all the polygons
|
|
30450
|
+
* in the collection.
|
|
30451
|
+
* @param index - The zero-based index of the polygon.
|
|
30452
|
+
* @returns The ClippingPolygon at the specified index.
|
|
30453
|
+
*/
|
|
30454
|
+
get(index: number): ClippingPolygon;
|
|
30455
|
+
/**
|
|
30456
|
+
* Checks whether this collection contains a ClippingPolygon equal to the given ClippingPolygon.
|
|
30457
|
+
* @param polygon - The ClippingPolygon to check for.
|
|
30458
|
+
* @returns true if this collection contains the ClippingPolygon, false otherwise.
|
|
30459
|
+
*/
|
|
30460
|
+
contains(polygon: ClippingPolygon): boolean;
|
|
30461
|
+
/**
|
|
30462
|
+
* Removes the first occurrence of the given ClippingPolygon from the collection.
|
|
30463
|
+
* @returns <code>true</code> if the polygon was removed; <code>false</code> if the polygon was not found in the collection.
|
|
30464
|
+
*/
|
|
30465
|
+
remove(polygon: ClippingPolygon): boolean;
|
|
30466
|
+
/**
|
|
30467
|
+
* Removes all polygons from the collection.
|
|
30468
|
+
*/
|
|
30469
|
+
removeAll(): void;
|
|
30470
|
+
/**
|
|
30471
|
+
* Function for checking if the context will allow clipping polygons, which require floating point textures.
|
|
30472
|
+
* @param scene - The scene that will contain clipped objects and clipping textures.
|
|
30473
|
+
* @returns <code>true</code> if the context supports clipping polygons.
|
|
30474
|
+
*/
|
|
30475
|
+
static isSupported(scene: Scene | any): boolean;
|
|
30476
|
+
/**
|
|
30477
|
+
* Returns true if this object was destroyed; otherwise, false.
|
|
30478
|
+
* <br /><br />
|
|
30479
|
+
* If this object was destroyed, it should not be used; calling any function other than
|
|
30480
|
+
* <code>isDestroyed</code> will result in a {@link DeveloperError} exception.
|
|
30481
|
+
* @returns <code>true</code> if this object was destroyed; otherwise, <code>false</code>.
|
|
30482
|
+
*/
|
|
30483
|
+
isDestroyed(): boolean;
|
|
30484
|
+
/**
|
|
30485
|
+
* Destroys the WebGL resources held by this object. Destroying an object allows for deterministic
|
|
30486
|
+
* release of WebGL resources, instead of relying on the garbage collector to destroy this object.
|
|
30487
|
+
* <br /><br />
|
|
30488
|
+
* Once an object is destroyed, it should not be used; calling any function other than
|
|
30489
|
+
* <code>isDestroyed</code> will result in a {@link DeveloperError} exception. Therefore,
|
|
30490
|
+
* assign the return value (<code>undefined</code>) to the object as done in the example.
|
|
30491
|
+
* @example
|
|
30492
|
+
* clippingPolygons = clippingPolygons && clippingPolygons.destroy();
|
|
30493
|
+
*/
|
|
30494
|
+
destroy(): void;
|
|
30495
|
+
}
|
|
30496
|
+
|
|
30289
30497
|
/**
|
|
30290
30498
|
* A renderable collection of clouds in the 3D scene.
|
|
30291
30499
|
* <br /><br />
|
|
@@ -31695,6 +31903,10 @@ export class Globe {
|
|
|
31695
31903
|
* A property specifying a {@link ClippingPlaneCollection} used to selectively disable rendering on the outside of each plane.
|
|
31696
31904
|
*/
|
|
31697
31905
|
clippingPlanes: ClippingPlaneCollection;
|
|
31906
|
+
/**
|
|
31907
|
+
* A property specifying a {@link ClippingPolygonCollection} used to selectively disable rendering inside or outside a list of polygons.
|
|
31908
|
+
*/
|
|
31909
|
+
clippingPolygons: ClippingPolygonCollection;
|
|
31698
31910
|
/**
|
|
31699
31911
|
* A property specifying a {@link Rectangle} used to limit globe rendering to a cartographic area.
|
|
31700
31912
|
* Defaults to the maximum extent of cartographic coordinates.
|
|
@@ -34210,7 +34422,7 @@ export namespace Label {
|
|
|
34210
34422
|
*/
|
|
34211
34423
|
type ConstructorOptions = {
|
|
34212
34424
|
position: Cartesian3;
|
|
34213
|
-
id?:
|
|
34425
|
+
id?: any;
|
|
34214
34426
|
show?: boolean;
|
|
34215
34427
|
text?: string;
|
|
34216
34428
|
font?: string;
|
|
@@ -36411,6 +36623,10 @@ export class Model {
|
|
|
36411
36623
|
* The {@link ClippingPlaneCollection} used to selectively disable rendering the model.
|
|
36412
36624
|
*/
|
|
36413
36625
|
clippingPlanes: ClippingPlaneCollection;
|
|
36626
|
+
/**
|
|
36627
|
+
* The {@link ClippingPolygonCollection} used to selectively disable rendering the model.
|
|
36628
|
+
*/
|
|
36629
|
+
clippingPolygons: ClippingPolygonCollection;
|
|
36414
36630
|
/**
|
|
36415
36631
|
* The light color when shading the model. When <code>undefined</code> the scene's light color is used instead.
|
|
36416
36632
|
* <p>
|
|
@@ -36648,6 +36864,7 @@ export class Model {
|
|
|
36648
36864
|
* @param [options.showOutline = true] - Whether to display the outline for models using the {@link https://github.com/KhronosGroup/glTF/tree/master/extensions/2.0/Vendor/CESIUM_primitive_outline|CESIUM_primitive_outline} extension. When true, outlines are displayed. When false, outlines are not displayed.
|
|
36649
36865
|
* @param [options.outlineColor = Color.BLACK] - The color to use when rendering outlines.
|
|
36650
36866
|
* @param [options.clippingPlanes] - The {@link ClippingPlaneCollection} used to selectively disable rendering the model.
|
|
36867
|
+
* @param [options.clippingPolygons] - The {@link ClippingPolygonCollection} used to selectively disable rendering the model.
|
|
36651
36868
|
* @param [options.lightColor] - The light color when shading the model. When <code>undefined</code> the scene's light color is used instead.
|
|
36652
36869
|
* @param [options.imageBasedLighting] - The properties for managing image-based lighting on this model.
|
|
36653
36870
|
* @param [options.backFaceCulling = true] - Whether to cull back-facing geometry. When true, back face culling is determined by the material's doubleSided property; when false, back face culling is disabled. Back faces are not culled if the model's color is translucent.
|
|
@@ -36699,6 +36916,7 @@ export class Model {
|
|
|
36699
36916
|
showOutline?: boolean;
|
|
36700
36917
|
outlineColor?: Color;
|
|
36701
36918
|
clippingPlanes?: ClippingPlaneCollection;
|
|
36919
|
+
clippingPolygons?: ClippingPolygonCollection;
|
|
36702
36920
|
lightColor?: Cartesian3;
|
|
36703
36921
|
imageBasedLighting?: ImageBasedLighting;
|
|
36704
36922
|
backFaceCulling?: boolean;
|
|
@@ -41285,6 +41503,14 @@ export class Terrain {
|
|
|
41285
41503
|
* are passed the created instance of {@link TerrainProvider}.
|
|
41286
41504
|
*/
|
|
41287
41505
|
readonly readyEvent: Event<Terrain.ReadyEventCallback>;
|
|
41506
|
+
/**
|
|
41507
|
+
* Returns true when the terrain provider has been successfully created. Otherwise, returns false.
|
|
41508
|
+
*/
|
|
41509
|
+
readonly ready: boolean;
|
|
41510
|
+
/**
|
|
41511
|
+
* The terrain provider providing surface geometry to a globe. Do not use until {@link Terrain.readyEvent} is raised.
|
|
41512
|
+
*/
|
|
41513
|
+
readonly provider: TerrainProvider;
|
|
41288
41514
|
/**
|
|
41289
41515
|
* Creates a {@link Terrain} instance for {@link https://cesium.com/content/#cesium-world-terrain|Cesium World Terrain}.
|
|
41290
41516
|
* @example
|