Skip to content

raisin::WaterSurfaceSample ​

struct · #include <rayrai/Water.hpp>

Surface of a water body at one horizontal position (sampleWaterSurface()).

Public attributes ​

inside ​

cpp
bool inside

The position lies within the body (always true for an ocean).

height ​

cpp
double height

World z of the surface above the position, metres.

normal ​

cpp
glm::vec3 normal

World surface normal.

compression ​

cpp
float compression

Horizontal area of the surface relative to its rest area; below 1 at crests, below 0 where the surface folds over.

RaiSim — physics for robotics and AI.