Skip to main content

Viewing a glTF Point Cloud with XKTLoaderPlugin

· 2 min read

Introduction

In this mini-tutorial, we'll use xeokit's convert2xkt CLI tool to convert a point cloud model from LAS/LAZ into xeokit's native XKT geometry format, which we'll then view in the browser using a xeokit Viewer.

The XKT format compresses models into a compact payload from which xeokit can load large numbers of objects over the Web in seconds, at full geometric precision.

For our glTF file, we'll use a point cloud capture of an apartment in Lyon, France, which was provided by BIMData. When that's converted and loaded, it will look like the example below. This model contains 2.6 million points, and xeokit can usually load it over a good Internet connection in around ~5 seconds.

Viewing a LAS Point Cloud with XKTLoaderPlugin

· 2 min read

Introduction

In this mini-tutorial, we'll use xeokit's convert2xkt CLI tool to convert a point cloud model from LAS format into xeokit's compact XKT native model format, which we'll then view in the browser using a xeokit Viewer.

LAS is an open format for the interchange and archiving of lidar point cloud data.

The XKT format compresses models into a compact payload from which xeokit can load large numbers of objects over the Web in seconds, at full geometric precision.

For our point cloud file, we'll use an LAS point cloud capture of the Autzen Stadium in Oregon, provided by http://loaders.gl . When that's converted and loaded, it will look like the example below. This model contains 31 million points, and xeokit can usually load it over a good Internet connection in around ~15 seconds.

Viewing .BIM in a xeokit Viewer

· 5 min read

Released in: https://github.com/xeokit/xeokit-sdk/releases/tag/v2.6.13

Summary

The DotBIMLoaderPlugin class enables us to to load .bim models into a xeokit Viewer.

When loading a .bim model, the DotBIMLoader does the following:

  • Creates an Entity representing each .bim model it loads, which will have Entity#isModel set true and will be registered by Entity#id in Scene#models.
  • Creates an Entity for each object within the .bim model. Those Entities will have Entity#isObject set true and will be registered by Entity#id in Scene#objects.
  • When loading, can set the World-space position, scale and rotation of each model within World space, along with initial viewer state for all the model's Entitys.
  • Allows to mask which IFC types we want to load.
  • Allows to configure initial viewer state for specified IFC types (color, visibility, selection, highlighted, X-rayed, pickable, etc).
  • Supports viewing of geographically large or distant models using xeokit's double-precision coordinate system

Viewing an IFC Model with XKTLoaderPlugin

· 3 min read

Introduction

In this mini-tutorial, we'll use xeokit's [convert2xkt](<https://xeokit.github.io/xeokit-convert/docs/>) CLI tool to convert an IFC 4.3 model into xeokit's native XKT geometry format, which we'll then view in the browser using a xeokit Viewer.

The XKT format compresses models into a compact payload from which xeokit can load large numbers of objects over the Web in seconds, at full geometric precision.

For our IFC model, we'll use an architectural model from the Revit Sample Project Files. When that's converted and loaded into our viewer, it will look like the example below.

This model contains 5512 visible objects, with 283238 triangles, and a xeokit Viewer can usually load it over a good Internet connection in ~2 seconds.

Viewing Multiple Models

· 3 min read

Introduction

xeokit-sdk can load multiple models from a variety of file formats into the same 3D scene.

Supported formats (so far) include IFC, glTF, DAE, OBJ, STL and 3DXML. Regardless of where models were loaded from, xeokit exposes their objects via an abstract interface through which we can access them uniformly.

In this tutorial, you'll load several models from different formats into the same scene, then update rendering states on a couple of their objects.

Accurate Measurements with Snapping

· 6 min read

In xeokit v2.4, we have introduced a new feature that allows users to measure distances and angles more accurately in their models. When using the xeokit SDK's DistanceMeasurementsPlugin or AngleMeasurementsPlugin, or the measurement tools in xeokit’s bundled BIMViewer, the mouse pointer now automatically snaps to the nearest vertex or edge. This makes it easier to position the pointer accurately and obtain precise measurements.

This innovative technique was developed by one of our core xeokit SDK developers, Toni Marti. It relies almost entirely on the GPU to find the nearest vertex or edge. Compared to traditional nearest-neighbor spatial search techniques used in other graphics libraries, this technique performs much faster. Additionally, its performance scales smoothly to work with the largest models that we can view with xeokit.

BIMViewer Marquee Selection Tool

· 2 min read

We have added a new marquee selection tool to xeokit's bundled BIMViewer application. This tool enables users to interactively select objects that intersect a rectangular region created by dragging the mouse.

Compact Model Representation using Data Textures

· 5 min read

In xeokit v2.4, we have implemented a new technique for internally storing and rendering models in the xeokit Viewer, which we call data texture model representation (or DTX for short). Compared to the traditional Vertex Buffer Objects (VBOs) used in other browser graphics libraries, this technique has a much lower memory footprint. As a result, users can now view even larger models in xeokit.

Note that this feature requires a reasonably good GPU and may not work well on low-spec graphics hardware. It has been found to work well on recent-model iPhones and desktop graphics hardware, including Intel HD and NVIDIA GPUs.