@cesium/engine 2.2.0 → 2.3.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.
Files changed (137) hide show
  1. package/Build/Workers/{AttributeCompression-8a5a065e.js → AttributeCompression-f9f6c717.js} +1 -1
  2. package/Build/Workers/{AxisAlignedBoundingBox-379015ef.js → AxisAlignedBoundingBox-31fadcf0.js} +1 -1
  3. package/Build/Workers/{BoundingRectangle-57f2b24f.js → BoundingRectangle-995f0079.js} +1 -1
  4. package/Build/Workers/{BoxGeometry-ecabfc78.js → BoxGeometry-7eb1af60.js} +1 -1
  5. package/Build/Workers/{Color-14d1a36d.js → Color-2dc49658.js} +1 -1
  6. package/Build/Workers/{CoplanarPolygonGeometryLibrary-048c3c14.js → CoplanarPolygonGeometryLibrary-d7d972d6.js} +1 -1
  7. package/Build/Workers/{CorridorGeometryLibrary-520c8619.js → CorridorGeometryLibrary-1f5ef7b3.js} +1 -1
  8. package/Build/Workers/{CylinderGeometry-119068b8.js → CylinderGeometry-23c67a6c.js} +1 -1
  9. package/Build/Workers/{CylinderGeometryLibrary-135b0858.js → CylinderGeometryLibrary-7bf291b4.js} +1 -1
  10. package/Build/Workers/{EllipseGeometry-2dfc3523.js → EllipseGeometry-37014da4.js} +1 -1
  11. package/Build/Workers/{EllipseGeometryLibrary-0a1e0170.js → EllipseGeometryLibrary-92ab6b1e.js} +1 -1
  12. package/Build/Workers/{EllipseOutlineGeometry-c5251669.js → EllipseOutlineGeometry-12b6fef5.js} +1 -1
  13. package/Build/Workers/{EllipsoidGeodesic-dcff5cbd.js → EllipsoidGeodesic-5b3623dc.js} +1 -1
  14. package/Build/Workers/{EllipsoidGeometry-d10a5221.js → EllipsoidGeometry-508da15c.js} +1 -1
  15. package/Build/Workers/{EllipsoidOutlineGeometry-7039a0ae.js → EllipsoidOutlineGeometry-40d97455.js} +1 -1
  16. package/Build/Workers/{EllipsoidRhumbLine-b672d507.js → EllipsoidRhumbLine-ef872433.js} +1 -1
  17. package/Build/Workers/{EllipsoidTangentPlane-857186be.js → EllipsoidTangentPlane-46d4d9c2.js} +1 -1
  18. package/Build/Workers/{EncodedCartesian3-e8bbca36.js → EncodedCartesian3-57415c8a.js} +1 -1
  19. package/Build/Workers/{FrustumGeometry-400fa1b7.js → FrustumGeometry-38605e69.js} +31 -3
  20. package/Build/Workers/{GeometryAttribute-7a2de5c6.js → GeometryAttribute-a466e9c7.js} +1 -1
  21. package/Build/Workers/{GeometryInstance-3fb607b7.js → GeometryInstance-34d9e21e.js} +1 -1
  22. package/Build/Workers/{GeometryPipeline-916636fa.js → GeometryPipeline-dcf79306.js} +1 -1
  23. package/Build/Workers/{IndexDatatype-b8f3e09d.js → IndexDatatype-2643aa47.js} +1 -1
  24. package/Build/Workers/{IntersectionTests-b4d02d4d.js → IntersectionTests-88c49b2e.js} +1 -1
  25. package/Build/Workers/{Math-dad82b4d.js → Math-0a2ac845.js} +12 -2
  26. package/Build/Workers/{Matrix2-1e403d0e.js → Matrix2-e1298525.js} +1 -1
  27. package/Build/Workers/{Matrix3-fa806b97.js → Matrix3-41c58dde.js} +1 -1
  28. package/Build/Workers/{OrientedBoundingBox-96fe1752.js → OrientedBoundingBox-2dd47921.js} +1 -1
  29. package/Build/Workers/{Plane-c27e1ac6.js → Plane-4c3d403b.js} +1 -1
  30. package/Build/Workers/{PolygonGeometryLibrary-931f1ec6.js → PolygonGeometryLibrary-59126025.js} +1 -1
  31. package/Build/Workers/PolygonPipeline-1fe328c0.js +1344 -0
  32. package/Build/Workers/{PolylinePipeline-6d5c63e5.js → PolylinePipeline-896735cc.js} +1 -1
  33. package/Build/Workers/{PolylineVolumeGeometryLibrary-f068c1fb.js → PolylineVolumeGeometryLibrary-9c0639f7.js} +1 -1
  34. package/Build/Workers/{PrimitivePipeline-879f996a.js → PrimitivePipeline-fc1a47ff.js} +1 -1
  35. package/Build/Workers/{RectangleGeometryLibrary-2d6f36f3.js → RectangleGeometryLibrary-a23c9ebe.js} +1 -1
  36. package/Build/Workers/{TerrainEncoding-82882059.js → TerrainEncoding-51b8b33b.js} +1 -1
  37. package/Build/Workers/Transforms-bc45e707.js +14699 -0
  38. package/Build/Workers/{WallGeometryLibrary-db7a64fb.js → WallGeometryLibrary-007e9883.js} +1 -1
  39. package/Build/Workers/{WebMercatorProjection-76a3fcc0.js → WebMercatorProjection-13ed1a6e.js} +1 -1
  40. package/Build/Workers/{arrayRemoveDuplicates-fac118a8.js → arrayRemoveDuplicates-d2061e85.js} +1 -1
  41. package/Build/Workers/cesiumWorkerBootstrapper.js +1 -1
  42. package/Build/Workers/combineGeometry.js +1 -1
  43. package/Build/Workers/createBoxGeometry.js +1 -1
  44. package/Build/Workers/createBoxOutlineGeometry.js +1 -1
  45. package/Build/Workers/createCircleGeometry.js +1 -1
  46. package/Build/Workers/createCircleOutlineGeometry.js +1 -1
  47. package/Build/Workers/createCoplanarPolygonGeometry.js +1 -1
  48. package/Build/Workers/createCoplanarPolygonOutlineGeometry.js +1 -1
  49. package/Build/Workers/createCorridorGeometry.js +1 -1
  50. package/Build/Workers/createCorridorOutlineGeometry.js +1 -1
  51. package/Build/Workers/createCylinderGeometry.js +1 -1
  52. package/Build/Workers/createCylinderOutlineGeometry.js +1 -1
  53. package/Build/Workers/createEllipseGeometry.js +1 -1
  54. package/Build/Workers/createEllipseOutlineGeometry.js +1 -1
  55. package/Build/Workers/createEllipsoidGeometry.js +1 -1
  56. package/Build/Workers/createEllipsoidOutlineGeometry.js +1 -1
  57. package/Build/Workers/createFrustumGeometry.js +1 -1
  58. package/Build/Workers/createFrustumOutlineGeometry.js +1 -1
  59. package/Build/Workers/createGeometry.js +1 -1
  60. package/Build/Workers/createGroundPolylineGeometry.js +1 -1
  61. package/Build/Workers/createPlaneGeometry.js +1 -1
  62. package/Build/Workers/createPlaneOutlineGeometry.js +1 -1
  63. package/Build/Workers/createPolygonGeometry.js +1 -1
  64. package/Build/Workers/createPolygonOutlineGeometry.js +1 -1
  65. package/Build/Workers/createPolylineGeometry.js +1 -1
  66. package/Build/Workers/createPolylineVolumeGeometry.js +1 -1
  67. package/Build/Workers/createPolylineVolumeOutlineGeometry.js +1 -1
  68. package/Build/Workers/createRectangleGeometry.js +1 -1
  69. package/Build/Workers/createRectangleOutlineGeometry.js +1 -1
  70. package/Build/Workers/createSimplePolylineGeometry.js +1 -1
  71. package/Build/Workers/createSphereGeometry.js +1 -1
  72. package/Build/Workers/createSphereOutlineGeometry.js +1 -1
  73. package/Build/Workers/createVectorTileClampedPolylines.js +1 -1
  74. package/Build/Workers/createVectorTileGeometries.js +1 -1
  75. package/Build/Workers/createVectorTilePoints.js +1 -1
  76. package/Build/Workers/createVectorTilePolygons.js +1 -1
  77. package/Build/Workers/createVectorTilePolylines.js +1 -1
  78. package/Build/Workers/createVerticesFromGoogleEarthEnterpriseBuffer.js +1 -1
  79. package/Build/Workers/createVerticesFromHeightmap.js +5 -8
  80. package/Build/Workers/createVerticesFromQuantizedTerrainMesh.js +1 -1
  81. package/Build/Workers/createWallGeometry.js +1 -1
  82. package/Build/Workers/createWallOutlineGeometry.js +1 -1
  83. package/Build/Workers/decodeDraco.js +1 -1
  84. package/Build/Workers/decodeI3S.js +1 -1
  85. package/Build/Workers/package.js +1 -1
  86. package/Build/Workers/transferTypedArrayTest.js +1 -1
  87. package/Build/Workers/upsampleQuantizedTerrainMesh.js +1 -1
  88. package/Source/Core/BingMapsGeocoderService.js +19 -1
  89. package/Source/Core/CartographicGeocoderService.js +15 -0
  90. package/Source/Core/Credit.js +1 -1
  91. package/Source/Core/FrustumGeometry.js +3 -2
  92. package/Source/Core/GeocoderService.js +32 -1
  93. package/Source/Core/Ion.js +1 -1
  94. package/Source/Core/IonGeocoderService.js +17 -2
  95. package/Source/Core/OpenCageGeocoderService.js +18 -1
  96. package/Source/Core/OrthographicFrustum.js +13 -0
  97. package/Source/Core/PeliasGeocoderService.js +14 -1
  98. package/Source/Core/PerspectiveFrustum.js +14 -0
  99. package/Source/Core/Request.js +3 -2
  100. package/Source/Core/RequestScheduler.js +9 -4
  101. package/Source/Core/Resource.js +228 -234
  102. package/Source/DataSources/DataSourceDisplay.js +2 -2
  103. package/Source/DataSources/EntityCluster.js +126 -128
  104. package/Source/DataSources/ModelVisualizer.js +5 -3
  105. package/Source/Renderer/UniformState.js +3 -2
  106. package/Source/Renderer/demodernizeShader.js +5 -5
  107. package/Source/Scene/ArcGisBaseMapType.js +12 -0
  108. package/Source/Scene/ArcGisMapServerImageryProvider.js +162 -20
  109. package/Source/Scene/ArcGisMapService.js +83 -0
  110. package/Source/Scene/Camera.js +8 -7
  111. package/Source/Scene/Cesium3DTile.js +4 -3
  112. package/Source/Scene/Cesium3DTileset.js +4 -4
  113. package/Source/Scene/CreditDisplay.js +112 -16
  114. package/Source/Scene/GlobeSurfaceTileProvider.js +4 -4
  115. package/Source/Scene/GltfJsonLoader.js +12 -0
  116. package/Source/Scene/GltfLoader.js +6 -37
  117. package/Source/Scene/IonImageryProvider.js +11 -11
  118. package/Source/Scene/Model/MaterialPipelineStage.js +12 -12
  119. package/Source/Scene/Model/Model.js +85 -44
  120. package/Source/Scene/Model/UniformType.js +1 -1
  121. package/Source/Scene/Picking.js +3 -2
  122. package/Source/Scene/QuadtreePrimitive.js +3 -2
  123. package/Source/Scene/SceneTransforms.js +3 -2
  124. package/Source/Scene/ScreenSpaceCameraController.js +1 -1
  125. package/Source/Scene/Vector3DTilePoints.js +25 -13
  126. package/Source/Shaders/AtmosphereCommon.glsl +51 -8
  127. package/Source/Shaders/AtmosphereCommon.js +51 -8
  128. package/Source/Shaders/PostProcessStages/AmbientOcclusionGenerate.glsl +1 -1
  129. package/Source/Shaders/PostProcessStages/AmbientOcclusionGenerate.js +1 -1
  130. package/Source/Shaders/PostProcessStages/AmbientOcclusionModulate.glsl +3 -3
  131. package/Source/Shaders/PostProcessStages/AmbientOcclusionModulate.js +3 -3
  132. package/Source/Widget/CesiumWidget.js +12 -0
  133. package/index.d.ts +207 -16
  134. package/index.js +286 -284
  135. package/package.json +4 -4
  136. package/Build/Workers/PolygonPipeline-32fc92cc.js +0 -1345
  137. package/Build/Workers/Transforms-9052372a.js +0 -14715
package/index.d.ts CHANGED
@@ -887,6 +887,11 @@ export class BingMapsGeocoderService {
887
887
  * The key for the Bing geocoder service
888
888
  */
889
889
  readonly key: string;
890
+ /**
891
+ * Gets the credit to display after a geocode is performed. Typically this is used to credit
892
+ * the geocoder service.
893
+ */
894
+ readonly credit: Credit | undefined;
890
895
  /**
891
896
  * @param query - The query to be sent to the geocoder service
892
897
  */
@@ -2716,6 +2721,11 @@ export class Cartographic {
2716
2721
  */
2717
2722
  export class CartographicGeocoderService {
2718
2723
  constructor();
2724
+ /**
2725
+ * Gets the credit to display after a geocode is performed. Typically this is used to credit
2726
+ * the geocoder service.
2727
+ */
2728
+ readonly credit: Credit | undefined;
2719
2729
  /**
2720
2730
  * @param query - The query to be sent to the geocoder service
2721
2731
  */
@@ -4818,7 +4828,7 @@ export class CorridorOutlineGeometry {
4818
4828
  /**
4819
4829
  * A credit contains data pertaining to how to display attributions/credits for certain content on the screen.
4820
4830
  * @example
4821
- * //Create a credit with a tooltip, image and link
4831
+ * // Create a credit with a tooltip, image and link
4822
4832
  * const credit = new Cesium.Credit('<a href="https://cesium.com/" target="_blank"><img src="/images/cesium_logo.png" title="Cesium"/></a>');
4823
4833
  * @param html - An string representing an html code snippet
4824
4834
  * @param [showOnScreen = false] - If true, the credit will be visible in the main credit container. Otherwise, it will appear in a popover
@@ -6595,6 +6605,7 @@ export namespace GeocoderService {
6595
6605
  type Result = {
6596
6606
  displayName: string;
6597
6607
  destination: Rectangle | Cartesian3;
6608
+ attributions?: object[];
6598
6609
  };
6599
6610
  }
6600
6611
 
@@ -6604,6 +6615,17 @@ export namespace GeocoderService {
6604
6615
  */
6605
6616
  export class GeocoderService {
6606
6617
  constructor();
6618
+ /**
6619
+ * Gets the credit to display after a geocode is performed. Typically this is used to credit
6620
+ * the geocoder service.
6621
+ */
6622
+ readonly credit: Credit | undefined;
6623
+ /**
6624
+ * Parses credits from the geocoder result attributions, if present.
6625
+ * @param geocoderResult - The geocoder result
6626
+ * @returns A list of credits if present in the result, otherwise undefined
6627
+ */
6628
+ static getCreditsFromResult(geocoderResult: GeocoderService.Result): Credit[] | undefined;
6607
6629
  /**
6608
6630
  * @param query - The query to be sent to the geocoder service
6609
6631
  * @param [type = GeocodeType.SEARCH] - The type of geocode to perform.
@@ -8545,6 +8567,11 @@ export class IonGeocoderService {
8545
8567
  accessToken?: string;
8546
8568
  server?: string | Resource;
8547
8569
  });
8570
+ /**
8571
+ * Gets the credit to display after a geocode is performed. Typically this is used to credit
8572
+ * the geocoder service.
8573
+ */
8574
+ readonly credit: Credit | undefined;
8548
8575
  /**
8549
8576
  * @param query - The query to be sent to the geocoder service
8550
8577
  * @param [type = GeocodeType.SEARCH] - The type of geocode to perform.
@@ -11591,6 +11618,11 @@ export class OpenCageGeocoderService {
11591
11618
  * Optional params passed to OpenCage in order to customize geocoding
11592
11619
  */
11593
11620
  readonly params: any;
11621
+ /**
11622
+ * Gets the credit to display after a geocode is performed. Typically this is used to credit
11623
+ * the geocoder service.
11624
+ */
11625
+ readonly credit: Credit | undefined;
11594
11626
  /**
11595
11627
  * @param query - The query to be sent to the geocoder service
11596
11628
  */
@@ -12113,6 +12145,11 @@ export class PeliasGeocoderService {
12113
12145
  * The Resource used to access the Pelias endpoint.
12114
12146
  */
12115
12147
  readonly url: Resource;
12148
+ /**
12149
+ * Gets the credit to display after a geocode is performed. Typically this is used to credit
12150
+ * the geocoder service.
12151
+ */
12152
+ readonly credit: Credit | undefined;
12116
12153
  /**
12117
12154
  * @param query - The query to be sent to the geocoder service
12118
12155
  * @param [type = GeocodeType.SEARCH] - The type of geocode to perform.
@@ -14398,6 +14435,7 @@ export enum ReferenceFrame {
14398
14435
  * @param [options.throttle = false] - Whether to throttle and prioritize the request. If false, the request will be sent immediately. If true, the request will be throttled and sent based on priority.
14399
14436
  * @param [options.throttleByServer = false] - Whether to throttle the request by server.
14400
14437
  * @param [options.type = RequestType.OTHER] - The type of request.
14438
+ * @param [options.serverKey] - A key used to identify the server that a request is going to.
14401
14439
  */
14402
14440
  export class Request {
14403
14441
  constructor(options?: {
@@ -14409,6 +14447,7 @@ export class Request {
14409
14447
  throttle?: boolean;
14410
14448
  throttleByServer?: boolean;
14411
14449
  type?: RequestType;
14450
+ serverKey?: string;
14412
14451
  });
14413
14452
  /**
14414
14453
  * The URL to request.
@@ -14524,11 +14563,14 @@ export namespace RequestScheduler {
14524
14563
  */
14525
14564
  var maximumRequestsPerServer: number;
14526
14565
  /**
14527
- * A per server key list of overrides to use for throttling instead of <code>maximumRequestsPerServer</code>
14566
+ * A per server key list of overrides to use for throttling instead of <code>maximumRequestsPerServer</code>.
14567
+ * Useful when streaming data from a known HTTP/2 or HTTP/3 server.
14568
+ * @example
14569
+ * RequestScheduler.requestsByServer["myserver.com:443"] = 18;
14528
14570
  * @example
14529
14571
  * RequestScheduler.requestsByServer = {
14530
- * 'api.cesium.com:443': 18,
14531
- * 'assets.cesium.com:443': 18
14572
+ * "api.cesium.com:443": 18,
14573
+ * "assets.cesium.com:443": 18,
14532
14574
  * };
14533
14575
  */
14534
14576
  var requestsByServer: any;
@@ -14601,6 +14643,7 @@ export namespace Resource {
14601
14643
  * @property [retryCallback] - The Function to call when a request for this resource fails. If it returns true, the request will be retried.
14602
14644
  * @property [retryAttempts = 0] - The number of times the retryCallback should be called before giving up.
14603
14645
  * @property [request] - A Request object that will be used. Intended for internal use only.
14646
+ * @property [parseUrl = true] - If true, parse the url for query parameters; otherwise store the url without change
14604
14647
  */
14605
14648
  type ConstructorOptions = {
14606
14649
  url: string;
@@ -14611,6 +14654,7 @@ export namespace Resource {
14611
14654
  retryCallback?: Resource.RetryCallback;
14612
14655
  retryAttempts?: number;
14613
14656
  request?: Request;
14657
+ parseUrl?: boolean;
14614
14658
  };
14615
14659
  /**
14616
14660
  * A function that returns the value of the property.
@@ -25284,6 +25328,15 @@ export class Appearance {
25284
25328
  getRenderState(): any;
25285
25329
  }
25286
25330
 
25331
+ /**
25332
+ * ArcGisBaseMapType enumerates the ArcGIS image tile layers that are supported by default.
25333
+ */
25334
+ export enum ArcGisBaseMapType {
25335
+ SATELLITE = 1,
25336
+ OCEANS = 2,
25337
+ HILLSHADE = 3
25338
+ }
25339
+
25287
25340
  export namespace ArcGisMapServerImageryProvider {
25288
25341
  /**
25289
25342
  * Initialization options for the ArcGisMapServerImageryProvider constructor
@@ -25301,8 +25354,7 @@ export namespace ArcGisMapServerImageryProvider {
25301
25354
  * that no tiles are discarded, construct and pass a {@link NeverTileDiscardPolicy} for this
25302
25355
  * parameter.
25303
25356
  * @property [usePreCachedTilesIfAvailable = true] - If true, the server's pre-cached
25304
- * tiles are used if they are available. If false, any pre-cached tiles are ignored and the
25305
- * 'export' service is used.
25357
+ * tiles are used if they are available. Exporting Tiles is only supported with deprecated APIs.
25306
25358
  * @property [layers] - A comma-separated list of the layers to show, or undefined if all layers should be shown.
25307
25359
  * @property [enablePickFeatures = true] - If true, {@link ArcGisMapServerImageryProvider#pickFeatures} will invoke
25308
25360
  * the Identify service on the MapServer and return the features included in the response. If false,
@@ -25341,15 +25393,35 @@ export namespace ArcGisMapServerImageryProvider {
25341
25393
 
25342
25394
  /**
25343
25395
  * <div class="notice">
25344
- * To construct a ArcGisMapServerImageryProvider call {@link ArcGisMapServerImageryProvider.fromUrl}. Do not call the constructor directly.
25396
+ * This object is normally not instantiated directly, use {@link ArcGisMapServerImageryProvider.fromBasemapType} or {@link ArcGisMapServerImageryProvider.fromUrl}.
25345
25397
  * </div>
25346
25398
  *
25347
25399
  * Provides tiled imagery hosted by an ArcGIS MapServer. By default, the server's pre-cached tiles are
25348
25400
  * used, if available.
25401
+ *
25402
+ * <br/>
25403
+ *
25404
+ * An {@link https://developers.arcgis.com/documentation/mapping-apis-and-services/security| ArcGIS Access Token } is required to authenticate requests to an ArcGIS Image Tile service.
25405
+ * To access secure ArcGIS resources, it's required to create an ArcGIS developer
25406
+ * account or an ArcGIS online account, then implement an authentication method to obtain an access token.
25349
25407
  * @example
25408
+ * // Set the default access token for accessing ArcGIS Image Tile service
25409
+ * Cesium.ArcGisMapService.defaultAccessToken = "<ArcGIS Access Token>";
25410
+ *
25411
+ * // Add a base layer from a default ArcGIS basemap
25412
+ * const viewer = new Cesium.Viewer("cesiumContainer", {
25413
+ * baseLayer: Cesium.ImageryLayer.fromProviderAsync(
25414
+ * Cesium.ArcGisMapServerImageryProvider.fromBasemapType(
25415
+ * Cesium.ArcGisBaseMapType.SATELLITE
25416
+ * )
25417
+ * ),
25418
+ * });
25419
+ * @example
25420
+ * // Create an imagery provider from the url directly
25350
25421
  * const esri = await Cesium.ArcGisMapServerImageryProvider.fromUrl(
25351
- * "https://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer"
25352
- * );
25422
+ * "https://ibasemaps-api.arcgis.com/arcgis/rest/services/World_Imagery/MapServer", {
25423
+ * token: "<ArcGIS Access Token>"
25424
+ * });
25353
25425
  * @param [options] - Object describing initialization options
25354
25426
  */
25355
25427
  export class ArcGisMapServerImageryProvider {
@@ -25361,6 +25433,31 @@ export class ArcGisMapServerImageryProvider {
25361
25433
  * without communicating with the server.
25362
25434
  */
25363
25435
  enablePickFeatures: boolean;
25436
+ /**
25437
+ * Creates an {@link ImageryProvider} which provides tiled imagery from an ArcGIS base map.
25438
+ * @example
25439
+ * // Set the default access token for accessing ArcGIS Image Tile service
25440
+ * Cesium.ArcGisMapService.defaultAccessToken = "<ArcGIS Access Token>";
25441
+ *
25442
+ * // Add a base layer from a default ArcGIS basemap
25443
+ * const provider = await Cesium.ArcGisMapServerImageryProvider.fromBasemapType(
25444
+ * Cesium.ArcGisBaseMapType.SATELLITE);
25445
+ * @example
25446
+ * // Add a base layer from a default ArcGIS Basemap
25447
+ * const viewer = new Cesium.Viewer("cesiumContainer", {
25448
+ * baseLayer: Cesium.ImageryLayer.fromProviderAsync(
25449
+ * Cesium.ArcGisMapServerImageryProvider.fromBasemapType(
25450
+ * Cesium.ArcGisBaseMapType.HILLSHADE, {
25451
+ * token: "<ArcGIS Access Token>"
25452
+ * }
25453
+ * )
25454
+ * ),
25455
+ * });
25456
+ * @param style - The style of the ArcGIS base map imagery. Valid options are {@link ArcGisBaseMapType.SATELLITE}, {@link ArcGisBaseMapType.OCEANS}, and {@link ArcGisBaseMapType.HILLSHADE}.
25457
+ * @param [options] - Object describing initialization options.
25458
+ * @returns A promise that resolves to the created ArcGisMapServerImageryProvider.
25459
+ */
25460
+ static fromBasemapType(style: ArcGisBaseMapType, options?: ArcGisMapServerImageryProvider.ConstructorOptions): Promise<ArcGisMapServerImageryProvider>;
25364
25461
  /**
25365
25462
  * Gets the URL of the ArcGIS MapServer.
25366
25463
  */
@@ -25531,6 +25628,34 @@ export class ArcGisMapServerImageryProvider {
25531
25628
  pickFeatures(x: number, y: number, level: number, longitude: number, latitude: number): Promise<ImageryLayerFeatureInfo[]> | undefined;
25532
25629
  }
25533
25630
 
25631
+ /**
25632
+ * Default options for accessing the ArcGIS image tile service.
25633
+ *
25634
+ * An ArcGIS access token is required to access ArcGIS image tile layers.
25635
+ * A default token is provided for evaluation purposes only.
25636
+ * To obtain an access token, go to {@link https://developers.arcgis.com} and create a free account.
25637
+ * More info can be found in the {@link https://developers.arcgis.com/documentation/mapping-apis-and-services/security/ | ArcGIS developer guide}.
25638
+ */
25639
+ export namespace ArcGisMapService {
25640
+ /**
25641
+ * Gets or sets the default ArcGIS access token.
25642
+ */
25643
+ var defaultAccessToken: string;
25644
+ /**
25645
+ * Gets or sets the URL of the ArcGIS World Imagery tile service.
25646
+ */
25647
+ var defaultWorldImageryServer: string | Resource;
25648
+ /**
25649
+ * Gets or sets the URL of the ArcGIS World Hillshade tile service.
25650
+ */
25651
+ var defaultWorldHillshadeServer: string | Resource;
25652
+ /**
25653
+ * Gets or sets the URL of the ArcGIS World Oceans tile service.
25654
+ */
25655
+ var defaultWorldOceanServer: string | Resource;
25656
+ function getDefaultTokenCredit(providedKey: string): string | undefined;
25657
+ }
25658
+
25534
25659
  /**
25535
25660
  * An enum describing the x, y, and z axes and helper conversion functions.
25536
25661
  */
@@ -28808,7 +28933,7 @@ export namespace Cesium3DTileset {
28808
28933
  * try {
28809
28934
  * const tileset = await Cesium.Cesium3DTileset.fromUrl(
28810
28935
  * "http://localhost:8002/tilesets/Seattle/tileset.json"
28811
- * });
28936
+ * );
28812
28937
  * scene.primitives.add(tileset);
28813
28938
  * } catch (error) {
28814
28939
  * console.error(`Error creating tileset: ${error}`);
@@ -29526,7 +29651,7 @@ export class Cesium3DTileset {
29526
29651
  * try {
29527
29652
  * const tileset = await Cesium.Cesium3DTileset.fromUrl(
29528
29653
  * "http://localhost:8002/tilesets/Seattle/tileset.json"
29529
- * });
29654
+ * );
29530
29655
  * scene.primitives.add(tileset);
29531
29656
  * } catch (error) {
29532
29657
  * console.error(`Error creating tileset: ${error}`);
@@ -29555,9 +29680,9 @@ export class Cesium3DTileset {
29555
29680
  * });
29556
29681
  * scene.primitives.add(tileset);
29557
29682
  * @param url - The url to a tileset JSON file.
29558
- * @param options - An object describing initialization options
29683
+ * @param [options] - An object describing initialization options
29559
29684
  */
29560
- static fromUrl(url: Resource | string, options: Cesium3DTileset.ConstructorOptions): Promise<Cesium3DTileset>;
29685
+ static fromUrl(url: Resource | string, options?: Cesium3DTileset.ConstructorOptions): Promise<Cesium3DTileset>;
29561
29686
  /**
29562
29687
  * Provides a hook to override the method used to request the tileset json
29563
29688
  * useful when fetching tilesets from remote servers
@@ -30272,7 +30397,13 @@ export class ConeEmitter {
30272
30397
  /**
30273
30398
  * The credit display is responsible for displaying credits on screen.
30274
30399
  * @example
30275
- * const creditDisplay = new Cesium.CreditDisplay(creditContainer);
30400
+ * // Add a credit with a tooltip, image and link to display onscreen
30401
+ * const credit = new Cesium.Credit(`<a href="https://cesium.com/" target="_blank"><img src="/images/cesium_logo.png" title="Cesium"/></a>`, true);
30402
+ * viewer.creditDisplay.addStaticCredit(credit);
30403
+ * @example
30404
+ * // Add a credit with a plaintext link to display in the lightbox
30405
+ * const credit = new Cesium.Credit('<a href="https://cesium.com/" target="_blank">Cesium</a>');
30406
+ * viewer.creditDisplay.addStaticCredit(credit);
30276
30407
  * @param container - The HTML element where credits will be displayed
30277
30408
  * @param [delimiter = ' • '] - The string to separate text credits
30278
30409
  * @param [viewport = document.body] - The HTML element that will contain the credits popup
@@ -30285,16 +30416,41 @@ export class CreditDisplay {
30285
30416
  container: HTMLElement;
30286
30417
  /**
30287
30418
  * Adds a credit to the list of current credits to be displayed in the credit container
30419
+ * for the next frame
30288
30420
  * @param credit - The credit to display
30289
30421
  */
30290
30422
  addCredit(credit: Credit): void;
30423
+ /**
30424
+ * Adds a {@link Credit} that will show on screen or in the lightbox until
30425
+ * the next frame. This is mostly for internal use. Use {@link CreditDisplay.addStaticCredit} to add a persistent credit to the screen.
30426
+ * @param credit - The credit to display in the next frame.
30427
+ */
30428
+ addCreditToNextFrame(credit: Credit): void;
30291
30429
  /**
30292
30430
  * Adds credits that will persist until they are removed
30293
30431
  * @param credit - The credit to added to defaults
30294
30432
  */
30295
30433
  addDefaultCredit(credit: Credit): void;
30296
30434
  /**
30297
- * Removes a default credit
30435
+ * Adds a {@link Credit} that will show on screen or in the lightbox until removed with {@link CreditDisplay.removeStaticCredit}.
30436
+ * @example
30437
+ * // Add a credit with a tooltip, image and link to display onscreen
30438
+ * const credit = new Cesium.Credit(`<a href="https://cesium.com/" target="_blank"><img src="/images/cesium_logo.png" title="Cesium"/></a>`, true);
30439
+ * viewer.creditDisplay.addStaticCredit(credit);
30440
+ * @example
30441
+ * // Add a credit with a plaintext link to display in the lightbox
30442
+ * const credit = new Cesium.Credit('<a href="https://cesium.com/" target="_blank">Cesium</a>');
30443
+ * viewer.creditDisplay.addStaticCredit(credit);
30444
+ * @param credit - The credit to added
30445
+ */
30446
+ addStaticCredit(credit: Credit): void;
30447
+ /**
30448
+ * Removes a static credit shown on screen or in the lightbox.
30449
+ * @param credit - The credit to be removed.
30450
+ */
30451
+ removeStaticCredit(credit: Credit): void;
30452
+ /**
30453
+ * Removes a default credit.
30298
30454
  * @param credit - The credit to be removed from defaults
30299
30455
  */
30300
30456
  removeDefaultCredit(credit: Credit): void;
@@ -36581,6 +36737,27 @@ export class Model {
36581
36737
  * } catch (error) {
36582
36738
  * console.log(`Failed to load model. ${error}`);
36583
36739
  * }
36740
+ * @example
36741
+ * // Load a model and play the last animation at half speed
36742
+ * let animations;
36743
+ * try {
36744
+ * const model = await Cesium.Model.fromGltfAsync({
36745
+ * url: "../../SampleData/models/CesiumMan/Cesium_Man.glb",
36746
+ * gltfCallback: gltf => {
36747
+ * animations = gltf.animations
36748
+ * }
36749
+ * });
36750
+ * viewer.scene.primitives.add(model);
36751
+ * model.readyEvent.addEventListener(() => {
36752
+ * model.activeAnimations.add({
36753
+ * index: animations.length - 1,
36754
+ * loop: Cesium.ModelAnimationLoop.REPEAT,
36755
+ * multiplier: 0.5,
36756
+ * });
36757
+ * });
36758
+ * } catch (error) {
36759
+ * console.log(`Failed to load model. ${error}`);
36760
+ * }
36584
36761
  * @param options - Object with the following properties:
36585
36762
  * @param options.url - The url to the .gltf or .glb file.
36586
36763
  * @param [options.basePath = ''] - The base path that paths in the glTF JSON are relative to.
@@ -36628,6 +36805,7 @@ export class Model {
36628
36805
  * @param [options.instanceFeatureIdLabel = "instanceFeatureId_0"] - Label of the instance feature ID set used for picking and styling. If instanceFeatureIdLabel is set to an integer N, it is converted to the string "instanceFeatureId_N" automatically. If both per-primitive and per-instance feature IDs are present, the instance feature IDs take priority.
36629
36806
  * @param [options.pointCloudShading] - Options for constructing a {@link PointCloudShading} object to control point attenuation and lighting.
36630
36807
  * @param [options.classificationType] - Determines whether terrain, 3D Tiles or both will be classified by this model. This cannot be set after the model has loaded.
36808
+ * @param [options.gltfCallback] - A function that is called with the loaded gltf object once loaded.
36631
36809
  * @returns A promise that resolves to the created model when it is ready to render.
36632
36810
  */
36633
36811
  static fromGltfAsync(options: {
@@ -36677,9 +36855,18 @@ export class Model {
36677
36855
  instanceFeatureIdLabel?: string | number;
36678
36856
  pointCloudShading?: any;
36679
36857
  classificationType?: ClassificationType;
36858
+ gltfCallback?: Model.GltfCallback;
36680
36859
  }): Promise<Model>;
36681
36860
  }
36682
36861
 
36862
+ export namespace Model {
36863
+ /**
36864
+ * Interface for the function that is called with the loaded gltf object once loaded.
36865
+ * @param gltf - The gltf object
36866
+ */
36867
+ type GltfCallback = (gltf: any) => void;
36868
+ }
36869
+
36683
36870
  /**
36684
36871
  * <div class="notice">
36685
36872
  * Create animations by calling {@link ModelAnimationCollection#add}. Do not call the constructor directly.
@@ -37230,7 +37417,7 @@ export enum UniformType {
37230
37417
  /**
37231
37418
  * A 3x3 matrix of floating point values.
37232
37419
  */
37233
- MAT3 = "mat2",
37420
+ MAT3 = "mat3",
37234
37421
  /**
37235
37422
  * A 3x3 matrix of floating point values.
37236
37423
  */
@@ -43332,6 +43519,10 @@ export class CesiumWidget {
43332
43519
  * The terrain provider providing surface geometry for the globe.
43333
43520
  */
43334
43521
  terrainProvider: TerrainProvider;
43522
+ /**
43523
+ * Manages the list of credits to display on screen and in the lightbox.
43524
+ */
43525
+ creditDisplay: CreditDisplay;
43335
43526
  /**
43336
43527
  * Gets the camera.
43337
43528
  */