Top-ring vertex displacement amount (0 = flat top edge, clamped to [0, 1]).
Per-meter tint build-up through the water body.
Densest tint reached far through the water (0..1).
Animated brightness shimmer amount (0 = off).
Gerstner choppiness applied to the displaced top-ring swells.
Point this material's wave-component uniform arrays at the surface material's tables (by reference) so the displaced wall top ring tracks the surface waves with no extra per-frame work. The surface mutates those Vector4s in place when the sea state changes, so the walls update for free.
OIT-compatible water-body (volume) material for the side walls of an ocean box. Shades the walls as a transparent, depth-tinted blue body (a fog-like tint that builds up with view distance), so the interior reads as water both when the camera is inside the box and when looking in from outside. Rendered double-sided so the walls are visible from either side. Shares the surface's deep and shallow colours so the body matches the surface.
The wall's top ring follows the same spectral wave displacement as the ocean surface (tapered to zero at the sea bed) so the rim stays sealed when vertex displacement is enabled. Share the surface's wave tables via OceanVolumeMaterial.setWaveTables so the walls move in lock-step.
Wired for the OITRenderPass via attachOitVariants (variants share this material's
uniformsby reference, so animated uniforms stay live).