FFT-based Simulation WIP!
So after a lot of headaches and red bulls (sponsor me please? lol) I finally have a working FFT implementation.
Test #1.
_4UDU6K9NnE
(Don’t pay too much attention on the material look, is meant to showcase the displacement)
is simulating a 128x128 grid on the CPU at about 4ms on a separate thread.
The plan is to implement a GPU-CPU combo for maximum performance and quality.
The CPU will simulate a smaller FFT (up to 128) which will be used for height readback queries only (for buoyancy etc.) and the GPU will be able to simulate a larger grid (up to 2048) with normals, energy-based foam etc. which will be used for rendering.
The simulation above is using the classic Phillips spectrum from the tessendorf papers which produce nice sharp “choppy” waves and is meant to represent a fully developed open state, but there are other spectrum models out there (which I have partially implemented) that are more “physically correct” and can produce different style of waves.
There is still a lot of work to be done so don’t expect any of to be released anytime soon, I’m doing in my free time as you know