benilla-re systems structs docs

FFT2D

function · terrain · unreached

Address
0x68b600 · 648 bytes, up to 0x68b887
Signature
void __fastcall (float *data, const uint32_t *dims, uint32_t arg3, uint32_t arg4)
Meaning
Transforms a multi-dimensional complex array in place by radix-2 FFT with a sign argument
Confidence
verified, proof one
Finding
terrain/liquid#wave-field

Finding: Wave field in terrain: liquid

The client carries a wave field it never runs. A step advances two phases, by 0.2 and by 0.92 times the frame time, clears a 64 by 64 grid of complex floats, puts eight sine and cosine terms of the phases in fixed cells, takes the inverse FFT of the grid and scales every float by 1/64. A sample rotates a point into the field's axes, returns 0 outside its half extents and otherwise blends four heights bilinearly at 1/8.3333 of a yard a cell.

The derivation is in the doc.

Callers 1

Callees 0

None by a direct call or jump.

Calls and jumps by a bare address, from tables/calls.tsv.