Terrain · interface
ClipmapFrame
Everything a per-patch decision needs, computed once for a camera.
Explained in Terrain.
interface ClipmapFrameimport type { ClipmapFrame } from '@driftengine/terrain';In depth
Deliberately plain data: an Int32Array of origins and four numbers. What a compute pass would
be handed as a uniform block, and nothing a shader could not hold.
Properties
| Name | Type | Description |
|---|---|---|
levelsreadonly | number | |
patchCellsreadonly | number | |
patchesAcrossreadonly | number | |
originsreadonly | Int32Array | Two entries a level: the field-cell index of the block's first cell, x then z. |
fieldCellsXreadonly | number | Cells the field has, which is one fewer than its samples. |
fieldCellsZreadonly | number |