Point Cloud Tiler

Tile point clouds (LAS, LAZ) into 3D Tiles.

Setup

Extract the contents of cesium-ion-point-cloud-tiler.zip.

The main executable is point-cloud-tiler and can be found under cesium-ion-point-cloud-tiler/bin.

Windows

Windows binaries require Visual C++ Redistributable for Visual Studio 2017. Download and run the installer.

Using the tiler

The following command will tile the file PointCloud.las into 3D Tiles and place the output in a new directory called Tileset.

bin/point-cloud-tiler -i PointCloud.las -o Tileset

We can also convert all LAS files in a directory and recursively in its subdirectories.

bin/point-cloud-tiler -i ../LasDirectory -o Tileset

If the input point cloud is not georeferenced, longitude, latitude, and height above the WGS84 ellipsoid may be supplied as shown below.

bin/point-cloud-tiler -i PointCloud.las -o Tileset --longitude=79.023056 --latitude=37.801944 --height=100

The tiler has built-in support for Draco compression. To enable Draco and configure precision, use the following.

bin/point-cloud-tiler -i PointCloud.las -o Tileset --compression=DRACO --draco-precision-meters=0.005

The tiler preserves per-point attributes including color, classification, and intensity. These may be discarded if desired to reduce tileset size.

bin/point-cloud-tiler -i PointCloud.las -o Tileset --discard-color --discard-classification --discard-intensity

Memory usage and concurrency may be supplied for fine-grained control of system resources. When running inside Docker, it is recommended to set these manually since containerization prevents the tiler from querying system resources.

bin/point-cloud-tiler -i PointCloud.las -o Tileset --memory=16000 --concurrency=8

Note: When working with big point clouds, ensure that there is enough space on disk for temporary files used during tiling. Typically the amount of temporary space needed is no more than the size of the input point cloud. Temporary files are deleted when the tiler finishes.

Available options

Below is a full list of command line options to configure the tiler.

Basic options

Option Description Required Default
--help, -h Display help message.    
--version, -v Display version number.    
--input, -i One or more input files or directories (recursive). Supported types: .las, .laz.  
--output, -o The path to the output directory or a .3dtiles database file. Will overwrite the existing directory if found, or otherwise create a new directory.  
--quiet Suppress output during tiling.   false
--verbose Show verbose output.   false
--show-statistics-only Show statistics for the input point cloud. Does not run the tiler.   false
--memory, -m Limits the maximum memory used by the tiler in megabytes. By default, the tiler will use the available system memory. If the input point cloud exceeds this limit, the tiler will run in out-of-core mode. When running inside Docker, it is recommended to set this manually since containerization prevents the tiler from querying system resources.   System available.
--concurrency, -x Maximum number of cores to use for CPU processing. Actual utilization depends on system resources. When running inside Docker, it is recommended to set this manually since containerization prevents the tiler from querying system resources.   System available.
--io-concurrency Maximum number of concurrent threads to use for I/O processing. Defaults to the value used for concurrency. It is recommended to set this to 1 for slower storage devices such as hard disk drives.   concurrency
--compression The type of point compression to use. Options are NONE, DRACO, and QUANTIZE.   NONE
--gzip Save tiles with gzip compression.   false

Advanced options

Option Description Required Default
--working-directory Working directory for saving temporary files during tiling. Defaults to the system’s temporary directory. Typically the amount of temporary space needed is no more than the size of the input point cloud. This directory will be deleted when the tiler finishes.    
--draco-compression-level Draco compression level between 0 and 10. In general, the highest setting, 10, will have the most compression but worst decompression speed. 0 will have the least compression but best decompression speed. Does not affect precision.   7
--draco-precision-meters Precision in meters for Draco compression. Defaults to millimeter precision. Set to 0 for lossless compression, which produces larger tileset sizes.   0.001
--quadtree Whether to build a quadtree instead of an octree. This is often suitable for flatter point clouds, such as those produced by aerial LiDAR.   false
--well-known-text A file containing the Well-Known Text (WKT) representation of the input point cloud’s coordinate system. The WKT is used only if projection information is missing from the input point cloud.    
--ignore-projection Ignore projection information contained in the input point cloud.   false
--longitude The longitude in EPSG:4326 coordinates (degrees) at which to place the tileset when the input point cloud is not georeferenced.    
--latitude The latitude in EPSG:4326 coordinates (degrees) at which to place the tileset when the input point cloud is not georeferenced.    
--height The height in meters relative to the WGS84 ellipsoid at which to place the tileset when the input point cloud is not georeferenced.    
--minimum-height The height in meters relative to the WGS84 ellipsoid below which points are removed. A simple metric for removing outliers.    
--maximum-height The height in meters relative to the WGS84 ellipsoid above which points are removed. A simple metric for removing outliers.    
--keep-outliers Bypass logic that detects and removes outliers.   false
--outlier-sigma-count For outlier detection, how many standard deviations from the mean a point has to be to be considered an outlier.   15
--outlier-sweep-count For outlier detection, caps how many iterations are performed to determine a best fit bounding volume.   2
--discard-color Discard per-point color attributes.   false
--discard-intensity Discard per-point intensity attributes.   false
--discard-classification Discard per-point classification attributes.   false
--pretty-json Write out tileset.json with human-readable formatting.   false
--tileset-version A version number or string to assign to the tileset. This is written to tileset.json and can be used as metadata to track changes.    

Next steps

Now that we’ve tiled our point clouds into 3D Tiles, the next step is to stream them into CesiumJS. All we need is a web server to host our tiles, and then we can pass a URL to our tileset as shown below.

var viewer = new Cesium.Viewer('cesiumContainer');

var tileset = viewer.scene.primitives.add(new Cesium.Cesium3DTileset({
    url : '<URL to tileset.json>'
}));

viewer.zoomTo(tileset);

The Hosting 3D Content tutorial walks you through setting up the Cesium ion Asset Server and streaming 3D content into CesiumJS.

Community Support

Cesium has an active community of developers and users. Along with members of the Cesium team, they support all kinds of technical questions.

Ask the forum