Terrain and OGC 3D Tiles
Dead Eye draws terrain from two sources: streamed OGC 3D Tiles, and geospecific lidar elevation models meshed by the engine. Both are placed in one 64-bit world frame (ECEF/WGS-84 truth, with a local tangent plane for rendering), so units, rounds and sensors share the same ground.
OGC 3D Tiles streaming
The engine streams OGC 3D Tiles natively through Cesium Native, from three kinds of source. 3D Tiles streaming is part of builds made with the Cesium Native dependency enabled (the build used for terrain work); Google and Cesium ion sources also need the provider's API key or access token.
| Source | How it is loaded |
|---|---|
| Local tileset | A tileset.json on disk
(loadLocalTileset(path)) |
| Cesium ion | An ion asset by access token and asset ID
(loadCesiumIonTileset(token, assetId)) |
| Google Photorealistic 3D Tiles | By API key (loadGooglePhotorealistic3DTiles(apiKey));
from the command line with --cesium and the
GOOGLE_3D_TILES_API_KEY environment variable |
How streaming works:
- Level of detail. Each frame the engine passes the
camera view (one or more view poses) to the tileset manager. Cesium
Native selects the tiles needed for that view and loads finer levels as
the camera approaches.
setMaximumScreenSpaceError(tileset, error)sets the detail threshold. - Background loading. Tiles are fetched and decoded on a worker thread pool. GPU resources are prepared off the render path, and main-thread work is drained once per frame.
- Content. Tile content is glTF, converted by the engine's glTF loader into its own vertex and material format, so tiles render with the same lighting, shadows and ray tracing as models.
- Placement. Tilesets are positioned in the world
frame and can be offset (
setTilesetOriginOffset) and shown or hidden per tileset.setPreloading(true)loads a whole area ahead of a run.setMaximumCacheSize(bytes)bounds the in-memory tile cache. - Scene origin. For the default scene,
CESIUM_ORIGIN_LAT/CESIUM_ORIGIN_LONset the local origin. Training vignettes set it from their site.
One World Terrain. OWT is delivered as OGC 3D Tiles, so OWT tilesets load through the same local-tileset and streaming path.
Attribution. Data providers' terms (for example, Google's) require their attribution to be shown with their tiles. Applications displaying third-party tiles must show it.
Geospecific lidar terrain
For gunnery ranges, the engine builds terrain directly from lidar elevation data rather than from photogrammetry tiles. A lidar DEM is one continuous surface accurate under a vehicle's tracks; photogrammetry tiles are an approximation whose neighbouring tiles do not always meet.
Pipeline (as used for the National Training Center, Fort Irwin):
- Source data: USGS 3DEP airborne lidar (2024, 0.5 m) and NAIP aerial imagery, both public.
- Preparation: cut to the site box with GDAL and written as raw little-endian float32 heights (row-major from the north-west corner, NAVD88 metres), with a JSON header describing the UTM grid.
- Datum: ellipsoid height = NAVD88 height + geoid
height (about −32 m at Fort Irwin, supplied as
geoid_m). - Use in the engine: a fine grid (about 1 m) is sampled in 64-bit precision to place units on the ground. A coarser grid is meshed for rendering, and the imagery is draped over it. Line-of-sight queries run against the same surface.
Vignette configuration (terrain
block):
"terrain": {
"dem": "assets/terrain/ntc/ntc_dem_1m",
"dem_mesh": "assets/terrain/ntc/ntc_dem_5m",
"mesh_step_m": 5,
"image": "assets/terrain/ntc/ntc_naip_8k.jpg",
"image_box": [-116.5007, 35.3048, -116.4393, 35.3552],
"geoid_m": -32.2
}2D map tiles
The tactical moving map draws Mapbox Vector Tiles and raster imagery
tiles (XYZ URL templates). These 2D map tiles have a persistent disk
cache, and OMEN_OFFLINE=1 serves them from disk only, for
disconnected operation.