Skip to content

API Interface WaterSample

github-actions[bot] edited this page Dec 2, 2026 · 3 revisions

Interface: WaterSample

Defined in: src/engine/render/water/WaterSurface.ts:20

The water surface at a point, in world space.

Properties

breaking

breaking: number;

Defined in: src/engine/render/water/WaterSurface.ts:30

0–1: how much the waves break there, where a baked depth map makes them shoal (ADR 0663); 0 in deep water.


height

height: number;

Defined in: src/engine/render/water/WaterSurface.ts:22

World-space height of the surface above (x, z).


normal

normal: Vector3;

Defined in: src/engine/render/water/WaterSurface.ts:24

World-space unit normal of the surface there.


velocity

velocity: Vector3;

Defined in: src/engine/render/water/WaterSurface.ts:26

World-space velocity of the water there (units per second): the waves' orbital motion (ADR 0663).


waveHeight

waveHeight: number;

Defined in: src/engine/render/water/WaterSurface.ts:28

Crest-to-trough height the waves reach there, in world units (twice their summed amplitudes, after shoaling).

Clone this wiki locally