Skip to content

Verify choppiness parameter behavior #888

Description

@bsb808

This is a followup for the waves refactor in PRs #882 - #885 and should be verified once we have a full working version.

What to verify

WaveParameters::choppiness (Wavefield.hh#L88) is a render-side multiplier on the horizontal (trochoidal) displacement, applied in the water vertex shader as chopFactor. Two things need a visual/behavioral check once runnable:

  1. Gerstner chop sign (possible inversion). WaterVisual applies chopFactor = choppiness (default −1) to both engines, but the Gerstner engine already bakes the sign into its Field() grid (dx -= q·a·dir·sinθ). So for Gerstner the shader multiplies by −1 a second time → the horizontal displacement may be inverted (bunching toward troughs, rounding crests). Check: do Gerstner crests sharpen the right way? If inverted, gate chopFactor to +1 for Gerstner (or simply don't apply choppiness to the Gerstner path — its chop knob is steepness).

  2. Render-only + per-engine scope. choppiness affects only the visual mesh + foam, not the physics (Elevation/Normal/ParticleVelocity never read it). Gerstner's chop knob is steepness; FFT's is choppiness. Confirm they behave as the parallel pair, and document that split (plus the render-only nature) at the parameter doc.

Blocked on

A runnable scene (post #885).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions