VoxelProvider

new Cesium.VoxelProvider()

Provides voxel data. Intended to be used with VoxelPrimitive. This type describes an interface and is not intended to be instantiated directly.
Experimental

This feature is not final and is subject to change without Cesium's standard deprecation policy.

See:

Members

Gets the metadata component types. This should not be called before VoxelProvider#ready returns true.
Gets the number of voxels per dimension of a tile. This is the same for all tiles in the dataset. This should not be called before VoxelProvider#ready returns true.

readonly globalTransform : Matrix4|undefined

A transform from local space to global space. If undefined, the identity matrix will be used instead.

readonly maxBounds : Cartesian3|undefined

Gets the maximum bounds. If undefined, the shape's default maximum bounds will be used instead. This should not be called before VoxelProvider#ready returns true.

readonly maximumTileCount : number|undefined

The maximum number of tiles that exist for this provider. This value is used as a hint to the voxel renderer to allocate an appropriate amount of GPU memory. If this value is not known it can be undefined. This should not be called before VoxelProvider#ready returns true.

readonly maximumValues : Array.<Array.<number>>|undefined

Gets the metadata maximum values. This should not be called before VoxelProvider#ready returns true.

readonly minBounds : Cartesian3|undefined

Gets the minimum bounds. If undefined, the shape's default minimum bounds will be used instead. This should not be called before VoxelProvider#ready returns true.

readonly minimumValues : Array.<Array.<number>>|undefined

Gets the metadata minimum values. This should not be called before VoxelProvider#ready returns true.

readonly names : Array.<string>

Gets the metadata names. This should not be called before VoxelProvider#ready returns true.

readonly paddingAfter : Cartesian3|undefined

Gets the number of padding voxels after the tile. This improves rendering quality when sampling the edge of a tile, but it increases memory usage. This should not be called before VoxelProvider#ready returns true.

readonly paddingBefore : Cartesian3|undefined

Gets the number of padding voxels before the tile. This improves rendering quality when sampling the edge of a tile, but it increases memory usage. This should not be called before VoxelProvider#ready returns true.
Gets the VoxelShapeType This should not be called before VoxelProvider#ready returns true.

readonly shapeTransform : Matrix4|undefined

A transform from shape space to local space. If undefined, the identity matrix will be used instead.
Gets the metadata types. This should not be called before VoxelProvider#ready returns true.

Methods

requestData(options)Promise.<Array.<Array>>|undefined

Requests the data for a given tile. The data is a flattened 3D array ordered by X, then Y, then Z. This function should not be called before VoxelProvider#ready returns true.
Name Type Description
options object optional Object with the following properties:
Name Type Default Description
tileLevel number 0 optional The tile's level.
tileX number 0 optional The tile's X coordinate.
tileY number 0 optional The tile's Y coordinate.
tileZ number 0 optional The tile's Z coordinate.
Returns:
A promise to an array of typed arrays containing the requested voxel data or undefined if there was a problem loading the data.
Need help? The fastest way to get answers is from the community and team on the Cesium Forum.