TimeDynamicPointCloud

new Cesium.TimeDynamicPointCloud(options)

Provides playback of time-dynamic point cloud data.

Point cloud frames are prefetched in intervals determined by the average frame load time and the current clock speed. If intermediate frames cannot be loaded in time to meet playback speed, they will be skipped. If frames are sufficiently small or the clock is sufficiently slow then no frames will be skipped.

Name Type Description
options object Object with the following properties:
Name Type Default Description
clock Clock A Clock instance that is used when determining the value for the time dimension.
intervals TimeIntervalCollection A TimeIntervalCollection with its data property being an object containing a uri to a 3D Tiles Point Cloud tile and an optional transform.
show boolean true optional Determines if the point cloud will be shown.
modelMatrix Matrix4 Matrix4.IDENTITY optional A 4x4 transformation matrix that transforms the point cloud.
shadows ShadowMode ShadowMode.ENABLED optional Determines whether the point cloud casts or receives shadows from light sources.
maximumMemoryUsage number 256 optional The maximum amount of memory in MB that can be used by the point cloud.
shading object optional Options for constructing a PointCloudShading object to control point attenuation and eye dome lighting.
style Cesium3DTileStyle optional The style, defined using the 3D Tiles Styling language, applied to each point in the point cloud.
clippingPlanes ClippingPlaneCollection optional The ClippingPlaneCollection used to selectively disable rendering the point cloud.

Members

The bounding sphere of the frame being rendered. Returns undefined if no frame is being rendered.
The ClippingPlaneCollection used to selectively disable rendering the point cloud.
The event fired to indicate that a new frame was rendered.

The time dynamic point cloud TimeDynamicPointCloud is passed to the event listener.

Default Value: new Event()
Example:
pointCloud.frameChanged.addEventListener(function(timeDynamicPointCloud) {
    viewer.camera.viewBoundingSphere(timeDynamicPointCloud.boundingSphere);
});
The event fired to indicate that a frame failed to load. A frame may fail to load if the request for its uri fails or processing fails due to invalid content.

If there are no event listeners, error messages will be logged to the console.

The error object passed to the listener contains two properties:

  • uri: the uri of the failed frame.
  • message: the error message.
Default Value: new Event()
Example:
pointCloud.frameFailed.addEventListener(function(error) {
    console.log(`An error occurred loading frame: ${error.uri}`);
    console.log(`Error: ${error.message}`);
});
The maximum amount of GPU memory (in MB) that may be used to cache point cloud frames.

Frames that are not being loaded or rendered are unloaded to enforce this.

If decreasing this value results in unloading tiles, the tiles are unloaded the next frame.

Default Value: 256
See:
A 4x4 transformation matrix that transforms the point cloud.
Default Value: Matrix4.IDENTITY

readonly deprecated readyPromise : Promise.<TimeDynamicPointCloud>

Gets the promise that will be resolved when the point cloud renders a frame for the first time.

Deprecated: true

Options for controlling point size based on geometric error and eye dome lighting.
Determines whether the point cloud casts or receives shadows from light sources.

Enabling shadows has a performance impact. A point cloud that casts shadows must be rendered twice, once from the camera and again from the light's point of view.

Shadows are rendered only when Viewer#shadows is true.

Default Value: ShadowMode.ENABLED
Determines if the point cloud will be shown.
Default Value: true
The style, defined using the 3D Tiles Styling language, applied to each point in the point cloud.

Assign undefined to remove the style, which will restore the visual appearance of the point cloud to its default when no style was applied.

Example:
pointCloud.style = new Cesium.Cesium3DTileStyle({
   color : {
       conditions : [
           ['${Classification} === 0', 'color("purple", 0.5)'],
           ['${Classification} === 1', 'color("red")'],
           ['true', '${COLOR}']
       ]
   },
   show : '${Classification} !== 2'
});
See:

readonly totalMemoryUsageInBytes : number

The total amount of GPU memory in bytes used by the point cloud.
See:

Methods

Destroys the WebGL resources held by this object. Destroying an object allows for deterministic release of WebGL resources, instead of relying on the garbage collector to destroy this object.

Once an object is destroyed, it should not be used; calling any function other than isDestroyed will result in a DeveloperError exception. Therefore, assign the return value (undefined) to the object as done in the example.
Throws:
  • DeveloperError : This object was destroyed, i.e., destroy() was called.
Example:
pointCloud = pointCloud && pointCloud.destroy();
See:
Returns true if this object was destroyed; otherwise, false.

If this object was destroyed, it should not be used; calling any function other than isDestroyed will result in a DeveloperError exception.
Returns:
true if this object was destroyed; otherwise, false.
See:
Marks the point cloud's TimeDynamicPointCloud#style as dirty, which forces all points to re-evaluate the style in the next frame.
Need help? The fastest way to get answers is from the community and team on the Cesium Forum.