/** * The pit's walls: the ground's hole cut open. The hole's edge is a threshold (the signed distance * to the footprints against a radius that wanders with noise); this walks that same threshold on * a fine grid (marching squares) and stands a wall of unit height (in `PIT_WALL_ROWS` rows) on every piece of the contour, * facing into the hole. The wall's lower edge is not stored: each vertex carries a `drop` (0 at * the ground, 1 at the bottom) the shader scales by the pit's current depth, so a floor switch * moves a uniform and never rebuilds the walls. */ export type PitContourSource = { /** The grid box to walk: world XZ of its corner and its side. */ originX: number; originZ: number; span: number; /** Signed distance to the footprints, as the ground's mask reads it. */ distanceAt: (x: number, z: number) => number; /** The wandering radius of the hole's edge at full opening. */ radiusAt: (x: number, z: number) => number; /** Where the wall's top sits: the ground surface there. */ topAt: (x: number, z: number) => number; /** The radius's smallest and largest value anywhere: far from both, the contour cannot be. */ radiusMin: number; radiusMax: number; /** Grid cell in metres (default 0.12). */ cell?: number; }; export type PitWalls = { positions: Float32Array; normals: Float32Array; /** x: 0 at the top of the wall, 1 at its foot. */ drops: Float32Array; indices: Uint32Array; }; /** * Rows a wall is cut into down its drop, so the shader can push them sideways by depth: a wall of * one row would stay a straight vertical fold from grade to the floor. */ export declare const PIT_WALL_ROWS = 16; export declare function buildPitWalls(source: PitContourSource): PitWalls | null; //# sourceMappingURL=ground-pit-geometry.d.ts.map